Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump artifactory from 3.4.0 to 3.11.2 #1610

Merged

Conversation

basil
Copy link
Member

@basil basil commented May 25, 2021

Fixes #1607 and JENKINS-65687. Supersedes #1608 and #1609.
closes #1608, closes #1609

This PR isn't fully working yet; MailExtTest.shouldProperlyRoundTripTokenMacro fails with

io.jenkins.plugins.casc.ConfiguratorException: unclassified: error configuring 'unclassified' with class io.jenkins.plugins.casc.impl.configurators.GlobalConfigurationCategoryConfigurator configurator
        at io.jenkins.plugins.casc.ConfigurationAsCode.invokeWith(ConfigurationAsCode.java:719)
        at io.jenkins.plugins.casc.ConfigurationAsCode.checkWith(ConfigurationAsCode.java:777)
        at io.jenkins.plugins.casc.ConfigurationAsCode.configureWith(ConfigurationAsCode.java:762)
        at io.jenkins.plugins.casc.ConfigurationAsCode.configureWith(ConfigurationAsCode.java:638)
        at io.jenkins.plugins.casc.ConfigurationAsCode.configureWith(ConfigurationAsCode.java:632)
        at io.jenkins.plugins.casc.MailExtTest.shouldProperlyRoundTripTokenMacro(MailExtTest.java:71)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
        at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
        at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
        at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
        at org.jvnet.hudson.test.JenkinsRule$1.evaluate(JenkinsRule.java:601)
        at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:288)
        at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:282)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.lang.Thread.run(Thread.java:748)
Caused by: io.jenkins.plugins.casc.ConfiguratorException: Cannot find configurator for type class org.jfrog.hudson.ArtifactoryServer
        at io.jenkins.plugins.casc.impl.DefaultConfiguratorRegistry.lookupOrFail(DefaultConfiguratorRegistry.java:69)
        at io.jenkins.plugins.casc.ConfigurationContext.lookupOrFail(ConfigurationContext.java:112)
        at io.jenkins.plugins.casc.BaseConfigurator.configure(BaseConfigurator.java:337)
        at io.jenkins.plugins.casc.BaseConfigurator.check(BaseConfigurator.java:287)
        at io.jenkins.plugins.casc.BaseConfigurator.configure(BaseConfigurator.java:351)
        at io.jenkins.plugins.casc.BaseConfigurator.check(BaseConfigurator.java:287)
        at io.jenkins.plugins.casc.ConfigurationAsCode.lambda$checkWith$8(ConfigurationAsCode.java:777)
        at io.jenkins.plugins.casc.ConfigurationAsCode.invokeWith(ConfigurationAsCode.java:713)
        ... 18 more

I started looking into this and found that the exported config contained

unclassified:
  artifactoryBuilder:
    artifactoryServers: |-
      FAILED TO EXPORT
      org.jfrog.hudson.ArtifactoryBuilder$DescriptorImpl#artifactoryServers: No configurator found for type class org.jfrog.hudson.ArtifactoryServer
    jfrogPipelinesServer:
      bypassProxy: false
      connectionRetries: 3
      credentialsConfig:
        overridingCredentials: false
        username: "****"
      timeout: 300
    useCredentialsPlugin: false

which was then causing the test to trip up later. Not sure if this can be worked around temporarily or if this will need to be addressed in the Artifactory plugin itself.

dependabot bot and others added 9 commits May 24, 2021 05:01
…plugin:3.1.2 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.1.2 (managed) <-- org.jenkins-ci.main:maven-plugin:3.4
…-classworlds:2.5.2 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.codehaus.plexus:plexus-classworlds:2.5.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.codehaus.plexus:plexus-classworlds:2.6.0
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven3-agent:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.4.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven31-agent:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.4.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven32-agent:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.5.1
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven33-agent:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.5.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven35-agent:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.6.0
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.main.maven:maven32-interceptor:1.13
        +-org.codehaus.plexus:plexus-classworlds:2.5.1
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-core:3.5.4
        +-org.codehaus.plexus:plexus-classworlds:2.5.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-embedder:3.5.4
        +-org.codehaus.plexus:plexus-classworlds:2.5.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.eclipse.sisu:org.eclipse.sisu.plexus:0.3.3
        +-org.codehaus.plexus:plexus-classworlds:2.5.2
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.lib:lib-jenkins-maven-embedder:3.14
        +-org.codehaus.plexus:plexus-classworlds:2.6.0
…ifact:3.5.0 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:jira:3.0.8
    +-org.apache.maven:maven-artifact:3.5.0
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-core:3.5.4
        +-org.apache.maven:maven-artifact:3.5.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-compat:3.5.4
        +-org.apache.maven:maven-artifact:3.5.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.jenkins-ci.lib:lib-jenkins-maven-embedder:3.14
        +-org.apache.maven:maven-artifact:3.5.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-core:3.5.4
        +-org.apache.maven:maven-plugin-api:3.3.3 (managed) <-- org.apache.maven:maven-plugin-api:3.5.4
          +-org.apache.maven:maven-artifact:3.3.3
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-core:3.5.4
        +-org.apache.maven:maven-model-builder:3.5.4
          +-org.apache.maven:maven-artifact:3.5.4
…gin-api:3.3.3 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-core:3.5.4
        +-org.apache.maven:maven-plugin-api:3.3.3 (managed) <-- org.apache.maven:maven-plugin-api:3.5.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jenkins-ci.main:maven-plugin:3.4
      +-org.apache.maven:maven-embedder:3.5.4
        +-org.apache.maven:maven-plugin-api:3.3.3 (managed) <-- org.apache.maven:maven-plugin-api:3.5.4
…ker-java:3.1.1 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jfrog.buildinfo:build-info-extractor-docker:2.26.0
      +-com.github.docker-java:docker-java:3.1.1 (managed) <-- com.github.docker-java:docker-java:3.1.5
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-io.jenkins.docker:docker-plugin:1.1.2
    +-org.jenkins-ci.plugins:docker-java-api:3.0.14
      +-com.github.docker-java:docker-java:3.1.1 (managed) <-- com.github.docker-java:docker-java:3.0.14
…et:junixsocket-common:2.0.4 paths to dependency are:

+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-io.jenkins.docker:docker-plugin:1.1.2
    +-com.kohlschutter.junixsocket:junixsocket-common:2.0.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-io.jenkins.docker:docker-plugin:1.1.2
    +-com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
      +-com.kohlschutter.junixsocket:junixsocket-common:2.0.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jfrog.buildinfo:build-info-extractor-docker:2.26.0
      +-com.github.docker-java:docker-java:3.1.5
        +-com.kohlschutter.junixsocket:junixsocket-common:2.2.0

Require upper bound dependencies error for com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4 paths to dependency are:
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-io.jenkins.docker:docker-plugin:1.1.2
    +-com.kohlschutter.junixsocket:junixsocket-native-common:2.0.4
and
+-io.jenkins.configuration-as-code:integrations:1.52-SNAPSHOT
  +-org.jenkins-ci.plugins:artifactory:3.11.0
    +-org.jfrog.buildinfo:build-info-extractor-docker:2.26.0
      +-com.github.docker-java:docker-java:3.1.5
        +-com.kohlschutter.junixsocket:junixsocket-native-common:2.2.0
@timja
Copy link
Member

timja commented May 25, 2021

@eyalbe4 looks like the configuration as code integration is broken in your last release, I recommend you add an automated test to your plugin

https://github.com/jenkinsci/configuration-as-code-plugin/blob/master/docs/PLUGINS.md#how-to-test

@timja timja mentioned this pull request May 28, 2021
6 tasks
@basil
Copy link
Member Author

basil commented May 28, 2021

This PR is now downstream of jfrog/jenkins-artifactory-plugin#492, which fixes the regression introduced in jfrog/jenkins-artifactory-plugin#455.

@basil
Copy link
Member Author

basil commented May 28, 2021

The PR build failed to download my timestamped snapshot from https://repo.jenkins-ci.org/snapshots/ but it worked fine for me locally.

@basil basil marked this pull request as ready for review May 28, 2021 15:30
@basil basil requested a review from a team as a code owner May 28, 2021 15:30
@basil basil changed the title Bump artifactory from 3.4.0 to 3.11.0 Bump artifactory from 3.4.0 to 3.11.2 May 28, 2021
@codecov
Copy link

codecov bot commented May 28, 2021

Codecov Report

Merging #1610 (dd2f7ab) into master (a19ce9f) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master    #1610   +/-   ##
=========================================
  Coverage     80.51%   80.51%           
  Complexity      817      817           
=========================================
  Files            66       66           
  Lines          2402     2402           
  Branches        340      340           
=========================================
  Hits           1934     1934           
  Misses          359      359           
  Partials        109      109           

@basil
Copy link
Member Author

basil commented May 28, 2021

3.11.2 (released 2 days ago) seems to work. I think this PR is ready to merge now.

@timja timja merged commit df3d6ad into jenkinsci:master May 28, 2021
@basil basil deleted the org.jenkins-ci.plugins-artifactory-3.11.0 branch May 28, 2021 18:17
@timja timja added the dependencies A PR that updates dependencies - used by Release Drafter label Aug 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies A PR that updates dependencies - used by Release Drafter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Artifactory breaking change in version 3.11.0
2 participants