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

File overwrite option

XMLWordPrintable

      I would like the plugin to optionally overwrite existing files.

      We already have the Clean remote option but this removes the existing Dropbox sharing links to the removed files which is something I do not want. When I run a build without the Clean remote option, the build results as unstable with following exception stack trace in the Jenkins log:

      Srp 03, 2017 7:18:43 ODP. jenkins.plugins.publish_over.BPCallablePublisher invoke
      WARNING: Exception when publishing, exception message [Could not write file. Server message: Storing failed]
      jenkins.plugins.publish_over.BapPublisherException: Could not write file. Server message: Storing failed
      at org.jenkinsci.plugins.publishoverdropbox.domain.DropboxClient.transferFile(DropboxClient.java:103)
      at org.jenkinsci.plugins.publishoverdropbox.domain.DropboxClient.transferFile(DropboxClient.java:40)
      at jenkins.plugins.publish_over.BPTransfer.transferFile(BPTransfer.java:171)
      at jenkins.plugins.publish_over.BPTransfer.transfer(BPTransfer.java:155)
      at jenkins.plugins.publish_over.BPTransfer.transfer(BPTransfer.java:142)
      at jenkins.plugins.publish_over.BapPublisher$Performer.transfer(BapPublisher.java:276)
      at jenkins.plugins.publish_over.BapPublisher$Performer.perform(BapPublisher.java:232)
      at jenkins.plugins.publish_over.BapPublisher$Performer.access$000(BapPublisher.java:205)
      at jenkins.plugins.publish_over.BapPublisher.perform(BapPublisher.java:158)
      at jenkins.plugins.publish_over.BPCallablePublisher.invoke(BPCallablePublisher.java:64)
      at jenkins.plugins.publish_over.BPCallablePublisher.invoke(BPCallablePublisher.java:37)
      at hudson.FilePath.act(FilePath.java:998)
      at hudson.FilePath.act(FilePath.java:976)
      at jenkins.plugins.publish_over.BPInstanceConfig.perform(BPInstanceConfig.java:138)
      at jenkins.plugins.publish_over.BPPlugin.perform(BPPlugin.java:111)
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:735)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:676)
      at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1072)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:621)
      at hudson.model.Run.execute(Run.java:1760)
      at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:542)
      at hudson.model.ResourceController.execute(ResourceController.java:97)
      at hudson.model.Executor.run(Executor.java:405)
      Caused by: org.jenkinsci.plugins.publishoverdropbox.domain.model.RestException: Failed to open connection to server
      at org.jenkinsci.plugins.publishoverdropbox.domain.JsonObjectRequest.execute(JsonObjectRequest.java:189)
      at org.jenkinsci.plugins.publishoverdropbox.domain.DropboxV2.chunkedStore(DropboxV2.java:357)
      at org.jenkinsci.plugins.publishoverdropbox.domain.DropboxV2.storeFile(DropboxV2.java:304)
      at org.jenkinsci.plugins.publishoverdropbox.domain.DropboxClient.transferFile(DropboxClient.java:101)
      ... 23 more
      Caused by: org.jenkinsci.plugins.publishoverdropbox.domain.model.RestException: caused by {error = path, errorSummary = 'path/conflict/file/..'}
      at org.jenkinsci.plugins.publishoverdropbox.domain.JsonObjectRequest.execute(JsonObjectRequest.java:179)
      ... 26 more
      Caused by: java.io.IOException: HTTP 409 error path/conflict/file/..
      ... 27 more

      Reading path/conflict/file I presume the problem is an existing file from previous build. Can you please confirm this first? With the Clean remote option set, the build passes successfully.

       

      My builds started to fail recently. Everything was working before a certain ammount of time - the files were always replaced and the sharing still worked. The thing I want primarily is to preserve the sharing links (e.g. make them always share the most recent version of a project). Is this possible? Does it make sense?

            rcgroot René de Groot
            jansvajcr Jan Švajcr
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: