[ https://jira.codehaus.org/browse/MDEPLOY-195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=365886#comment-365886 ]
Peter Janes commented on MDEPLOY-195: ------------------------------------- Since they're both hosted here, can you move the issue to the appropriate project, since it's not this one? (It's worth noting that the if( file != null && file.isFile() ) code is basically a repeat application of code that already exists in the plugin, i.e. someone has already "solved" another issue this way.) > deploy:deploy will try to deploy a nonexistent attached file (and succeed, > depending on the repository) > ------------------------------------------------------------------------------------------------------- > > Key: MDEPLOY-195 > URL: https://jira.codehaus.org/browse/MDEPLOY-195 > Project: Maven Deploy Plugin > Issue Type: Bug > Components: deploy:deploy > Affects Versions: 2.8.2 > Reporter: Peter Janes > Assignee: Robert Scholte > Attachments: mdeploy-nonexistent-attached-file.patch > > > If a nonexistent file is attached to a project using > build-helper-maven-plugin, deploy:deploy will attempt to deploy it (and, > depending on the repository manager, possibly create a zero-length artifact > in the process). > Detail: We have a legacy build process that generates RPMs using .spec files > and command-line tools, then attaches the artifacts to the build using > build-helper-maven-plugin. Occasionally the .spec file version gets out of > date; the RPM is still generated successfully, so build-helper-maven-plugin > attaches what it thinks will be the path to the generated file (but isn't, > because the version is wrong). When maven-deploy-plugin:deploy runs, it tries > to upload the nonexistent file to Nexus, which creates a zero-length > artifact. (This eventually causes Nexus's yum plugin to fail, as the > underlying createrepo process can't handle the zero-length RPM file is > invalid.) > The patch will no longer deploy the nonexistent file, printing a warning when > this happens instead. -- This message was sent by Atlassian JIRA (v6.1.6#6162)