java.lang.IllegalArgumentException: Negative time

Jenkins JIRA | Jeremy Bowman | 3 years ago
  1. 0

    Upon upgrading the Sauce OnDemand plugin from 1.83 to 1.85, every job using Sauce Connect started failing with the following error: Starting Sauce OnDemand SSH tunnel on slave node Launching Sauce Connect on <hostname> FATAL: Negative time java.lang.IllegalArgumentException: Negative time at java.io.File.setLastModified(File.java:1349) at org.codehaus.plexus.archiver.zip.AbstractZipUnArchiver.extractFile(AbstractZipUnArchiver.java:234) at org.codehaus.plexus.archiver.tar.TarUnArchiver.execute(TarUnArchiver.java:93) at org.codehaus.plexus.archiver.AbstractUnArchiver.extract(AbstractUnArchiver.java:120) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.untarGzFile(SauceConnectFourManager.java:153) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.extractZipFile(SauceConnectFourManager.java:143) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.createProcessBuilder(SauceConnectFourManager.java:111) at com.saucelabs.ci.sauceconnect.AbstractSauceTunnelManager.openConnection(AbstractSauceTunnelManager.java:172) at hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:542) at hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:517) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:328) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:701) So basically, it blows up when trying to extract Sauce Connect 4 from the .tar.gz resource. This seems to be related to the following bugs: https://jira.codehaus.org/browse/MJAR-142 http://bugs.java.com/bugdatabase/view_bug.do?bug_id=6791812 I'm not sure why it's being triggered in this case; I didn't see any suspicious timestamps when inspecting the plugin resources, but I may well have missed something.

    Jenkins JIRA | 3 years ago | Jeremy Bowman
    java.lang.IllegalArgumentException: Negative time
  2. 0

    Upon upgrading the Sauce OnDemand plugin from 1.83 to 1.85, every job using Sauce Connect started failing with the following error: Starting Sauce OnDemand SSH tunnel on slave node Launching Sauce Connect on <hostname> FATAL: Negative time java.lang.IllegalArgumentException: Negative time at java.io.File.setLastModified(File.java:1349) at org.codehaus.plexus.archiver.zip.AbstractZipUnArchiver.extractFile(AbstractZipUnArchiver.java:234) at org.codehaus.plexus.archiver.tar.TarUnArchiver.execute(TarUnArchiver.java:93) at org.codehaus.plexus.archiver.AbstractUnArchiver.extract(AbstractUnArchiver.java:120) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.untarGzFile(SauceConnectFourManager.java:153) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.extractZipFile(SauceConnectFourManager.java:143) at com.saucelabs.ci.sauceconnect.SauceConnectFourManager.createProcessBuilder(SauceConnectFourManager.java:111) at com.saucelabs.ci.sauceconnect.AbstractSauceTunnelManager.openConnection(AbstractSauceTunnelManager.java:172) at hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:542) at hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:517) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:328) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:701) So basically, it blows up when trying to extract Sauce Connect 4 from the .tar.gz resource. This seems to be related to the following bugs: https://jira.codehaus.org/browse/MJAR-142 http://bugs.java.com/bugdatabase/view_bug.do?bug_id=6791812 I'm not sure why it's being triggered in this case; I didn't see any suspicious timestamps when inspecting the plugin resources, but I may well have missed something.

    Jenkins JIRA | 3 years ago | Jeremy Bowman
    java.lang.IllegalArgumentException: Negative time
  3. 0

    GitHub comment 12#47938754

    GitHub | 2 years ago | jimthedev
    java.lang.IllegalArgumentException: Negative time
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    sy down breaks for file created in 1965

    GitHub | 2 years ago | Kudret
    java.lang.IllegalArgumentException: Negative time
  6. 0

    Error in Fileutils.copydirectory using apache commons java

    Stack Overflow | 2 years ago | Dhinakar
    java.lang.IllegalArgumentException: Negative time

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.IllegalArgumentException

      Negative time

      at java.io.File.setLastModified()
    2. Java RT
      File.setLastModified
      1. java.io.File.setLastModified(File.java:1349)
      1 frame
    3. Plexus Archiver Component
      AbstractUnArchiver.extract
      1. org.codehaus.plexus.archiver.zip.AbstractZipUnArchiver.extractFile(AbstractZipUnArchiver.java:234)
      2. org.codehaus.plexus.archiver.tar.TarUnArchiver.execute(TarUnArchiver.java:93)
      3. org.codehaus.plexus.archiver.AbstractUnArchiver.extract(AbstractUnArchiver.java:120)
      3 frames
    4. com.saucelabs.ci
      AbstractSauceTunnelManager.openConnection
      1. com.saucelabs.ci.sauceconnect.SauceConnectFourManager.untarGzFile(SauceConnectFourManager.java:153)
      2. com.saucelabs.ci.sauceconnect.SauceConnectFourManager.extractZipFile(SauceConnectFourManager.java:143)
      3. com.saucelabs.ci.sauceconnect.SauceConnectFourManager.createProcessBuilder(SauceConnectFourManager.java:111)
      4. com.saucelabs.ci.sauceconnect.AbstractSauceTunnelManager.openConnection(AbstractSauceTunnelManager.java:172)
      4 frames
    5. hudson.plugins.sauce_ondemand
      SauceOnDemandBuildWrapper$SauceConnectStarter.call
      1. hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:542)
      2. hudson.plugins.sauce_ondemand.SauceOnDemandBuildWrapper$SauceConnectStarter.call(SauceOnDemandBuildWrapper.java:517)
      2 frames
    6. Hudson :: Remoting Layer
      InterceptingExecutorService$1.call
      1. hudson.remoting.UserRequest.perform(UserRequest.java:118)
      2. hudson.remoting.UserRequest.perform(UserRequest.java:48)
      3. hudson.remoting.Request$2.run(Request.java:328)
      4. hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      4 frames
    7. Java RT
      Thread.run
      1. java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
      2. java.util.concurrent.FutureTask.run(FutureTask.java:166)
      3. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
      4. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      5. java.lang.Thread.run(Thread.java:701)
      5 frames