finally
{
container.release( wagonManager );
}
WagonProviderMapping mapping = (WagonProviderMapping) container.lookup( WagonProviderMapping.ROLE );
try
{
// set defaults
mapping.setWagonProvider( "http", "lightweight" );
mapping.setWagonProvider( "https", "lightweight" );
for ( Object k: executionProperties.keySet() )
{
String key = (String) k;
if ( key.startsWith( "maven.wagon.provider." ) )
{
String provider = executionProperties.getProperty( key );
key = key.substring( "maven.wagon.provider.".length() );
mapping.setWagonProvider( key, provider );
}
}
}
finally
{