Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(clouddriver): fix scope resolution of static method explictl…
…y calling by class name during upgrade to groovy 3.x (#4543) While upgrading groovy 3.0.10 and spockframework 2.0-groovy-3.0, encountered the following errors in orca-clouddriver module: ``` > Task :orca-clouddriver:compileGroovy startup failed: /orca/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/loadbalancer/UpsertLoadBalancerStage.groovy: 35: [Static type checking] - Cannot find matching method com.netflix.spinnaker.orca.clouddriver.pipeline.loadbalancer.UpsertLoadBalancerStage#getType(java.lang.Class <com.netflix.spinnaker.orca.clouddriver.pipeline.loadbalancer.UpsertLoadBalancerStage>). Please check if the declared type is correct and if the method exists. @ line 35, column 39. final String PIPELINE_CONFIG_TYPE = getType(UpsertLoadBalancerStage) ^ 1 error > Task :orca-clouddriver:compileGroovy FAILED ``` ``` > Task :orca-clouddriver:compileGroovy startup failed: /orca/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/providers/aws/ModifyAwsScalingProcessStage.groovy: 41: [Static type checking] - Cannot find matching method com.netflix.spinnaker.orca.clouddriver.pipeline.providers.aws.ModifyAwsScalingProcessStage#getType(java.lang.Class <com.netflix.spinnaker.orca.clouddriver.pipeline.providers.aws.ModifyAwsScalingProcessStage>). Please check if the declared type is correct and if the method exists. @ line 41, column 37. public static final String TYPE = getType(ModifyAwsScalingProcessStage) ^ 1 error > Task :orca-clouddriver:compileGroovy FAILED ``` ``` startup failed: /orca/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/support/DetermineTargetServerGroupStage.groovy: 32: [Static type checking] - Cannot find matching method com.netflix.spinnaker.orca.clouddriver.pipeline.servergroup.support.DetermineTargetServerGroupStage#getType(java.lang.Class <com.netflix.spinnaker.orca.clouddriver.pipeline.servergroup.support.DetermineTargetServerGroupStage>). Please check if the declared type is correct and if the method exists. @ line 32, column 39. final String PIPELINE_CONFIG_TYPE = getType(DetermineTargetServerGroupStage) ^ 1 error > Task :orca-clouddriver:compileGroovy FAILED ``` ``` startup failed: /orca/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/kato/pipeline/DetermineTargetReferenceStage.groovy: 33: [Static type checking] - Cannot find matching method com.netflix.spinnaker.orca.kato.pipeline.DetermineTargetReferenceStage#getType(java.lang.Class <com.netflix.spinnaker.orca.kato.pipeline.DetermineTargetReferenceStage>). Please check if the declared type is correct and if the method exists. @ line 33, column 39. final String PIPELINE_CONFIG_TYPE = getType(DetermineTargetReferenceStage) ^ 1 error > Task :orca-clouddriver:compileGroovy FAILED ``` To fix this issue explicitly called the static function with class name.
- Loading branch information