[ https://jira.codehaus.org/browse/WAGON-384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=319029#comment-319029 ]
William Bernardet commented on WAGON-384: ----------------------------------------- I am currently facing this issue already during the deployment of artifact if their size is over 2GB they get truncated at 2GB as well. But I would propose a different solution to fix the issue, by deprecating all method offering a maxSize int as parameter and offer a fixed API which offer similar API as long, because rest of the API (like Resource) is using long to store the size, so it make sense to use the same type in here as well. > Maven fails to download artifacts larger than 2 GB > -------------------------------------------------- > > Key: WAGON-384 > URL: https://jira.codehaus.org/browse/WAGON-384 > Project: Maven Wagon > Issue Type: Bug > Components: wagon-provider-api > Affects Versions: 2.2 > Environment: This issue is not dependent on the operating system and > hardware. > Reporter: Robert Baker > Attachments: AbstractWagon.java, AbstractWagon.java > > > If a Maven build includes a dependency for an artifact that is larger than 2 > GB in size, the download of the artifact during the build terminates at 2 GB > and the following error is reported by Maven: > [WARNING] Checksum validation failed, expected > 5b0fafa21f2b3e9c4e3b7ef3c5306f82bcb9fc85 but is > e9ef494d39de097b9a02531993688ceebdce39e1 > Maven repeats the download a second time with the same error result, then > build fails. > The failure is caused when the transfer method in AbstractWagon.java receives > maxSize parameter, which is an integer, set to Integer.MAX_VALUE, rather than > the actual size of the artifact. This value is then decremented to zero, > which causes the download to terminate prematurely. The attached file > (AbstractWagon.java) contains changes in the transfer method that use the > value Integer.MAX_VALUE as a trigger that causes the routine to ignore the > maxSize parameter's value and download the artifact until an EOF is detected, > regardless of its size. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira