Open sylvainlaurent opened 6 years ago
Hi,
1.9.8 and 1.9.9 were both releases that targeted the Bamboo plug-in only. No changes were necessary for the DSL part, so we didn't publish a new library for them. But I think we will do this anyway in the future to be always in sync between the plug-in and DSL versions.
Could you please show me the deprecations you got with 1.9.8 compared to 1.9.7 in IntelliJ? That would help me much. Thanks
I have warnings in bamboo like these:
simple 01-Feb-2018 09:54:04 Plan DSL: warning: (build_plans.groovy:137): scheduled is deprecated
simple 01-Feb-2018 09:54:04 Plan DSL: warning: (build_plans.groovy:168): watchers is deprecated
but when I look at the source code of ch.mibex.bamboo.plandsl.dsl.triggers.Triggers#scheduled(groovy.lang.Closure) (see https://github.com/mibexsoftware/bamboo-plan-dsl-plugin/blob/e382b82eef14ad08d82466d208778d0d0b2b2867/src/main/groovy/ch/mibex/bamboo/plandsl/dsl/triggers/Triggers.groovy#L62 ) it's not marked as deprecated...
it would be nice if both warnings were aligned because it's much easier to do it in the IDE!
Hi @sylvainlaurent
Both methods are deprecated if they are used with a description (scheduled
) or an event (watchers
). Here's an example:
triggers {
scheduled("test") {
}
}
Intellij marks this as deprecated. Which method overload of scheduled
and watchers
are you using?
Hello @mrueegg , the trigger is declared like this:
triggers {
bitbucketServerRepositoryTriggered {}
scheduled() {
description('every week')
cronExpression('0 0 23 ? * WED')
}
}
@sylvainlaurent Thanks a lot for the example. I was able to reproduce it. Will now try to solve this and get back to you.
when I run the DSL with plugin 1.9.8 I see some deprecation warnings in the logs of the bamboo job.
But I don't see them in IntelliJ if I set the dependency to version 1.9.7. I tried to upgrade to 1.9.8 but the artefacts are not on maven central...