Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-46048

Improve support for Pipeline

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: s3-plugin
    • Labels:
      None
    • Similar Issues:

      Description

      • Can we improve pipeline support by introducing new steps instead of delegating to the $class
      • Lots of warning messages in latest s3-plugin combined with workflow-cps-plugin, to reproduce,
        1) Publish artifacts via step
        step([$class     : 'S3BucketPublisher', dontWaitForConcurrentBuildCompletion: true, consoleLogLevel: "INFO",
        entries    : [[bucket          : 'blah', excludedFile: '', flatten: true, selectedRegion: 'us-east-1',
                       sourceFile      : archiveAntPattern, storageClass: 'STANDARD',
                       managedArtifacts: true
                      ]],
        profileName: 'Publishing-artifacts', userMetadata: [], pluginFailureResultConstraint: "FAILURE"])
        

        2) After build completion, goto the "Pipeline Steps" on left sidebar or view URL /job/number/flowGraphTable
        3) Check jenkins logs

        Aug 07, 2017 7:41:12 AM org.jenkinsci.plugins.structs.describable.DescribableModel uninstantiate2
        WARNING: Cannot create control version of class hudson.plugins.s3.S3BucketPublisher using {consoleLogLevel=INFO, dontWaitForConcurrentBuildCompletion=true, entries=[(bucket=blah,excludedFile=,flatten=true,gzipFiles=false,keepForever=false,managedArtifacts=true,noUploadOnFailure=false,selectedRegion=us-east-1,showDirectlyInBrowser=false,sourceFile=target/*.html,target/*.log,storageClass=STANDARD,uploadFromSlave=false,useServerSideEncryption=false)], pluginFailureResultConstraint=FAILURE, profileName=Publishing-artifacts, userMetadata=[]}
        java.lang.IllegalArgumentException: Could not instantiate {consoleLogLevel=INFO, dontWaitForConcurrentBuildCompletion=true, entries=[(bucket=engineering_qa,excludedFile=,flatten=true,gzipFiles=false,keepForever=false,managedArtifacts=true,noUploadOnFailure=false,selectedRegion=us-east-1,showDirectlyInBrowser=false,sourceFile=target/*.html,target/*.log,storageClass=STANDARD,uploadFromSlave=false,useServerSideEncryption=false)], pluginFailureResultConstraint=FAILURE, profileName=Publishing-artifacts, userMetadata=[]} for S3BucketPublisher(profileName: String, entries: Entry(bucket: String, sourceFile: String, excludedFile: String, storageClass: String, selectedRegion: String, noUploadOnFailure: boolean, uploadFromSlave: boolean, managedArtifacts: boolean, useServerSideEncryption: boolean, flatten: boolean, gzipFiles: boolean, keepForever: boolean, showDirectlyInBrowser: boolean, userMetadata: MetadataPair(key: String, value: String)[])[], userMetadata: MetadataPair(key: String, value: String)[], dontWaitForConcurrentBuildCompletion: boolean, consoleLogLevel: String, pluginFailureResultConstraint: String): java.lang.ClassCastException: hudson.plugins.s3.S3BucketPublisher.consoleLogLevel expects class java.lang.String but received class java.util.logging.Level
                at org.jenkinsci.plugins.structs.describable.DescribableModel.instantiate(DescribableModel.java:264)
                at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate2(DescribableModel.java:550)
                at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate2_(DescribableModel.java:652)
                at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:196)
                at org.jenkinsci.plugins.structs.describable.DescribableParameter.inspect(DescribableParameter.java:142)
                at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate2(DescribableModel.java:533)
                at org.jenkinsci.plugins.workflow.actions.ArgumentsAction.resolve(ArgumentsAction.java:304)
                at org.jenkinsci.plugins.workflow.actions.ArgumentsAction.getResolvedArguments(ArgumentsAction.java:291)
                at org.jenkinsci.plugins.workflow.cps.nodes.StepAtomNode.getDelegateType(StepAtomNode.java:134)
                at org.jenkinsci.plugins.workflow.cps.nodes.StepAtomNode.effectiveDisplayName(StepAtomNode.java:90)
                at org.jenkinsci.plugins.workflow.cps.nodes.StepAtomNode.getTypeDisplayName(StepAtomNode.java:102)
                at org.jenkinsci.plugins.workflow.graph.FlowNode.getDisplayName(FlowNode.java:189)
                at com.cloudbees.workflow.rest.external.FlowNodeExt.addBasicNodeData(FlowNodeExt.java:194)
                at com.cloudbees.workflow.rest.external.AtomFlowNodeExt.create(AtomFlowNodeExt.java:70)
                at com.cloudbees.workflow.rest.external.ChunkVisitor.makeAtomNode(ChunkVisitor.java:68)
                at com.cloudbees.workflow.rest.external.ChunkVisitor.atomNode(ChunkVisitor.java:154)
                at org.jenkinsci.plugins.workflow.graphanalysis.ForkScanner.fireVisitChunkCallbacks(ForkScanner.java:751)
                at org.jenkinsci.plugins.workflow.graphanalysis.ForkScanner.visitSimpleChunks(ForkScanner.java:769)
                at org.jenkinsci.plugins.workflow.graphanalysis.ForkScanner.visitSimpleChunks(ForkScanner.java:633)
                at com.cloudbees.workflow.rest.external.RunExt.createNew(RunExt.java:318)
                at com.cloudbees.workflow.rest.external.RunExt.create(RunExt.java:306)
                at com.cloudbees.workflow.rest.external.JobExt.create(JobExt.java:131)
                at com.cloudbees.workflow.rest.endpoints.JobAPI.doRuns(JobAPI.java:72)
                at java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:627)
                at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:343)
                at com.cloudbees.workflow.util.ServeJson$Processor.invoke(ServeJson.java:30)
                at org.kohsuke.stapler.PreInvokeInterceptedFunction.invoke(PreInvokeInterceptedFunction.java:26)
                at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:184)
                at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:117)
        

        Attachments

          Activity

          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Ted Xiao
          Path:
          README.md
          pom.xml
          src/main/java/hudson/plugins/s3/S3BucketPublisher.java
          src/main/java/hudson/plugins/s3/S3CopyArtifact.java
          http://jenkins-ci.org/commit/s3-plugin/32a092a607509003886447015d08d71c74ff754b
          Log:
          fix JENKINS-46048 Improve support for Pipeline

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Ted Xiao Path: README.md pom.xml src/main/java/hudson/plugins/s3/S3BucketPublisher.java src/main/java/hudson/plugins/s3/S3CopyArtifact.java http://jenkins-ci.org/commit/s3-plugin/32a092a607509003886447015d08d71c74ff754b Log: fix JENKINS-46048 Improve support for Pipeline
          Hide
          14163314 Serg Pr added a comment -

          I can't find any instruction/example, how to configure pipeline for s3 uploading ((

          Now, I can't find, how to add aws access and secret keys (
          Can someone help me.

          Thanks.

          Show
          14163314 Serg Pr added a comment - I can't find any instruction/example, how to configure pipeline for s3 uploading (( Now, I can't find, how to add aws access and secret keys ( Can someone help me. Thanks.
          Hide
          kentzo Ilya Kulakov added a comment -

          Serg Pr Open the Pipeline Syntax editor, set Sample Step to "step", then Build Step to "Publish Artifacts to S3 Bucket", configure and then click Run.

          Show
          kentzo Ilya Kulakov added a comment - Serg Pr Open the Pipeline Syntax editor, set Sample Step to "step", then Build Step to "Publish Artifacts to S3 Bucket", configure and then click Run.

            People

            Assignee:
            jimilian Alexander A
            Reporter:
            fengxx Ted Xiao
            Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated: