You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Phillip Webb (JIRA)" <ji...@codehaus.org> on 2007/02/25 19:35:15 UTC
[jira] Commented: (WAGON-73) MirroredWagon infinite loop
[ http://jira.codehaus.org/browse/WAGON-73?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_88489 ]
Phillip Webb commented on WAGON-73:
-----------------------------------
Likewise for the connect method
public void connect()
throws ConnectionException, AuthenticationException
{
try
{
// Keep trying with .nextMirror() et al.
while ( true )
{
try
{
this.impl.connect();
}
catch ( ConnectionException e )
{
logger.warn( "Unable to connect to mirror [" + this.impl.getRepository().getId() + "]" );
nextMirror();
}
catch ( AuthenticationException e )
{
logger.warn( "Unable to authenticate to mirror [" + this.impl.getRepository().getId() + "]" );
nextMirror();
}
}
}
catch ( ExhaustedMirrorsException e )
{
logger.warn( e.getMessage() );
throw new ConnectionException( e.getMessage(), e );
}
}
> MirroredWagon infinite loop
> ---------------------------
>
> Key: WAGON-73
> URL: http://jira.codehaus.org/browse/WAGON-73
> Project: wagon
> Issue Type: Bug
> Reporter: Phillip Webb
> Priority: Critical
>
> The MirroredWagon class includes a get method that runs into an infinite loop.
> I think a return is required after this.impl.get( resource, destination );
> public void get( String resource, File destination )
> throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
> {
> try
> {
> while ( true )
> {
> try
> {
> this.impl.get( resource, destination );
> }
> catch ( TransferFailedException e )
> {
> nextMirror();
> }
> }
> }
> catch ( ExhaustedMirrorsException e )
> {
> }
> }
--
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