ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 52076] New: Add delay to retry task
Date Mon, 24 Oct 2011 13:23:10 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=52076

             Bug #: 52076
           Summary: Add delay to retry task
           Product: Ant
           Version: nightly
          Platform: PC
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Core tasks
        AssignedTo: notifications@ant.apache.org
        ReportedBy: apache@avee.org
    Classification: Unclassified


Created attachment 27839
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=27839
Intial patch

I wanted the retry task to wait a bit before retrying. Since I didn't find a
clean way to do this I patched the retry task to support a 'retryDelay'
attribute. This simply sets the time to sleep between different retry attempts.
We currently use this on our build server to retry SVN updates which might fail
because multiple jobs are updating the same sandbox concurrently. So far it's
been working fine.

The attached patch has only been compiled/tested against java 1.6, but I guess
it should be fine in older versions as well.

The output, when a retryDelay is set looks like this:
updateLib:
     [echo] Start library update...
      [svn] svn: Working copy 'C:\BuildSystem\Libraries' locked; try performing
'cleanup'
      [svn] svn: Working copy 'C:\BuildSystem\Libraries' locked; try performing
'cleanup'
      [svn] <Update> failed.
    [retry] Attempt [0]: error occurred; retrying after 1000 ms...
      [svn] svn: Working copy 'C:\BuildSystem\Libraries' locked; try performing
'cleanup'
      [svn] svn: Working copy 'C:\BuildSystem\Libraries' locked; try performing
'cleanup'
      [svn] <Update> failed.
    [retry] Attempt [1]: error occurred; retrying after 1000 ms...
     [echo] Update done...

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

Mime
View raw message