[
http://jira.codehaus.org/browse/MWEBSTART-28?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_87732
]
Jerome Lacoste commented on MWEBSTART-28:
-----------------------------------------
Ken,
Could you give us more information ? Which SDK version ?
Could you try fiddling with the code to see why it is failing ? Any particular
thing in your setup ? Is the file on an nfs share ?
I don't remember seeing this kind of error, neither a workaround implemented
for them in general file helper libraries (e.g. commons io)
Maybe can we just retry after a while ? Could you try changing the following
code :
jarFiles[i].setLastModified( lastModified );
into something like
setLastModified ( jarFiles[i], lastModified );
then implement
setLastModified with something like:
private static boolean setLastModified( File file, long timestamp )
{
boolean result;
int nbretries = 3;
int sleep = 4000;
while ( ! (result = file.setLastModified( timestamp )) && nbretries-- > 0 )
{
log("failure to change last modified timestamp... retrying ...");
try { Thread.currentThread().sleep( sleep ); } catch
(InterruptedException ignore) {}
}
return result;
}
play with the sleep time and nbretries as you feel. Let us know how this works
out.
> result of setLastModified not checked after signing jars
> --------------------------------------------------------
>
> Key: MWEBSTART-28
> URL: http://jira.codehaus.org/browse/MWEBSTART-28
> Project: Maven 2.x Webstart Plugin
> Issue Type: Bug
> Environment: Solaris 10
> Reporter: Ken Geis
> Fix For: 1.0-alpha-2
>
>
> I get the following:
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Failure to run the plugin:
> Embedded error: the number of signed artifacts differ from the number of
> modified artifacts. Implementation error
> ---------------------
> My jars do not get signed, and it's apparently because the timestamp on them
> has not been set. The method signJars(..) calls
> jarFiles[i].setLastModified( lastModified );
> but it does not check the result of that call. I'm guessing that on Solaris
> 10, I am prevented from setting the modified date on a file.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email