maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Karl-Heinz Marbaise (JIRA)" <j...@codehaus.org>
Subject [jira] (MJAR-142) 'Negative time' when trying to create an empty jar
Date Tue, 03 Feb 2015 21:32:18 GMT

     [ https://jira.codehaus.org/browse/MJAR-142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Karl-Heinz Marbaise closed MJAR-142.
------------------------------------

    Resolution: Not A Bug
      Assignee: Karl-Heinz Marbaise

This error message belong to maven-assembly-plugin and is related to an old version.

> 'Negative time' when trying to create an empty jar
> --------------------------------------------------
>
>                 Key: MJAR-142
>                 URL: https://jira.codehaus.org/browse/MJAR-142
>             Project: Maven JAR Plugin
>          Issue Type: Bug
>    Affects Versions: 2.3
>         Environment: Windows 7
> maven 3.0.2
>            Reporter: bblasi bblasi
>            Assignee: Karl-Heinz Marbaise
>
> When I try to run 'package' on a multi-module project one of the modules fails. The only
difference on this module being it will run an ant script so no jar, or an empty one up until
now, would be generated.
> Plugin 2.2 will do the job. Plugin 2.3 fails on '-X package' with:
> {code}
> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-jar-plugin:2.3.1:jar (default-jar)
on project ETRAMPackager: Error assembling JAR: Negative time -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-jar-plugin:2.3.1:jar
(default-jar) on project ETRAMPackager: Error assembling JAR
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
> 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
> 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
> 	at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
> 	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
> 	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
> 	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
> 	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:534)
> 	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
> 	at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Error assembling JAR
> 	at org.apache.maven.plugin.jar.AbstractJarMojo.createArchive(AbstractJarMojo.java:223)
> 	at org.apache.maven.plugin.jar.AbstractJarMojo.execute(AbstractJarMojo.java:235)
> 	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107)
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
> 	... 19 more
> Caused by: java.lang.IllegalArgumentException: Negative time
> 	at java.io.File.setLastModified(File.java:1258)
> 	at org.codehaus.plexus.components.io.resources.PlexusIoFileResource.setLastModified(PlexusIoFileResource.java:148)
> 	at org.codehaus.plexus.components.io.resources.PlexusIoFileResource.setFile(PlexusIoFileResource.java:82)
> 	at org.codehaus.plexus.components.io.resources.PlexusIoFileResource.<init>(PlexusIoFileResource.java:73)
> 	at org.codehaus.plexus.components.io.resources.PlexusIoFileResourceCollection.addResources(PlexusIoFileResourceCollection.java:144)
> 	at org.codehaus.plexus.components.io.resources.PlexusIoFileResourceCollection.getResources(PlexusIoFileResourceCollection.java:181)
> 	at org.codehaus.plexus.components.io.resources.AbstractPlexusIoResourceCollection.getLastModified(AbstractPlexusIoResourceCollection.java:247)
> 	at org.codehaus.plexus.archiver.AbstractArchiver.isUptodate(AbstractArchiver.java:768)
> 	at org.codehaus.plexus.archiver.AbstractArchiver.checkForced(AbstractArchiver.java:799)
> 	at org.codehaus.plexus.archiver.zip.AbstractZipArchiver.execute(AbstractZipArchiver.java:236)
> 	at org.codehaus.plexus.archiver.AbstractArchiver.createArchive(AbstractArchiver.java:852)
> 	at org.apache.maven.archiver.MavenArchiver.createArchive(MavenArchiver.java:543)
> 	at org.apache.maven.plugin.jar.AbstractJarMojo.createArchive(AbstractJarMojo.java:216)
> 	... 22 more
> [ERROR] 
> [ERROR] 
> [ERROR] For more information about the errors and possible solutions, please read the
following articles:
> [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
> [ERROR] 
> [ERROR] After correcting the problems, you can resume the build with the command
> [ERROR]   mvn <goals> -rf :ETRAMPackager
> {code}



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)

Mime
View raw message