@Override public Wagon getWagon( WagonFactoryRequest wagonFactoryRequest ) throws WagonFactoryException { try { String protocol = StringUtils.startsWith( wagonFactoryRequest.getProtocol(), "wagon#" ) ? wagonFactoryRequest.getProtocol() : "wagon#" + wagonFactoryRequest.getProtocol(); // if it's a ntlm proxy we have to lookup the wagon light which support thats // wagon http client doesn't support that if ( wagonFactoryRequest.getNetworkProxy() != null && wagonFactoryRequest.getNetworkProxy().isUseNtlm() ) { protocol = protocol + "-ntlm"; } Wagon wagon = applicationContext.getBean( protocol, Wagon.class ); wagon.addTransferListener( debugTransferListener ); configureUserAgent( wagon, wagonFactoryRequest ); return wagon; } catch ( BeansException e ) { throw new WagonFactoryException( e.getMessage(), e ); } }
headers.put( "User-Agent", wagonFactoryRequest.getUserAgent() ); if ( !wagonFactoryRequest.getHeaders().isEmpty() ) for ( Map.Entry<String, String> entry : wagonFactoryRequest.getHeaders().entrySet() )
WagonFactoryRequest wagonFactoryRequest = new WagonFactoryRequest( "wagon#" + protocol, remoteRepository.getRepository().getExtraHeaders() ).networkProxy( networkProxy ); wagon = wagonFactory.getWagon( wagonFactoryRequest ); if ( wagon == null ) throw new ProxyException( e.getMessage(), e );
final NetworkProxy networkProxy = this.networkProxyMap.get( remoteRepository.getId() ); wagon = wagonFactory.getWagon( new WagonFactoryRequest( "wagon#" + protocol, remoteRepository.getExtraHeaders() ).networkProxy( networkProxy ) );
final NetworkProxy networkProxy = this.networkProxyMap.get( remoteRepository.getId() ); wagon = wagonFactory.getWagon( new WagonFactoryRequest( "wagon#" + protocol, remoteRepository.getExtraHeaders() ).networkProxy( networkProxy ) );
WagonFactoryRequest wagonFactoryRequest = new WagonFactoryRequest( "wagon#" + protocol, remoteRepository.getRepository().getExtraHeaders() ).networkProxy( networkProxy ); wagon = wagonFactory.getWagon( wagonFactoryRequest ); if ( wagon == null ) throw new ProxyException( e.getMessage(), e );
@Override public Wagon getWagon( WagonFactoryRequest wagonFactoryRequest ) throws WagonFactoryException { try { String protocol = StringUtils.startsWith( wagonFactoryRequest.getProtocol(), "wagon#" ) ? wagonFactoryRequest.getProtocol() : "wagon#" + wagonFactoryRequest.getProtocol(); // if it's a ntlm proxy we have to lookup the wagon light which support thats // wagon http client doesn't support that if ( wagonFactoryRequest.getNetworkProxy() != null && wagonFactoryRequest.getNetworkProxy().isUseNtlm() ) { protocol = protocol + "-ntlm"; } Wagon wagon = applicationContext.getBean( protocol, Wagon.class ); wagon.addTransferListener( debugTransferListener ); configureUserAgent( wagon, wagonFactoryRequest ); return wagon; } catch ( BeansException e ) { throw new WagonFactoryException( e.getMessage(), e ); } }
headers.put( "User-Agent", wagonFactoryRequest.getUserAgent() ); if ( !wagonFactoryRequest.getHeaders().isEmpty() ) for ( Map.Entry<String, String> entry : wagonFactoryRequest.getHeaders().entrySet() )
wagonFactory.getWagon(new WagonFactoryRequest(wagonProtocol, remoteRepository.getExtraHeaders()) // .networkProxy(networkProxy));
final StreamWagon wagon = (StreamWagon) wagonFactory.getWagon( new WagonFactoryRequest( wagonProtocol, remoteRepository.getExtraHeaders( ) ).networkProxy( networkProxy ) ); log.error( "Wagon for remote index download of {} could not be created: {}", remoteRepository.getId( ), e.getMessage( ), e ); throw new IndexUpdateFailedException( "Error while updating the remote index of " + remoteRepository.getId( ), e );
wagonFactory.getWagon(new WagonFactoryRequest(wagonProtocol, remoteRepository.getExtraHeaders()) // .networkProxy(networkProxy));
final StreamWagon wagon = (StreamWagon) wagonFactory.getWagon( new WagonFactoryRequest( wagonProtocol, this.remoteRepository.getExtraHeaders() ).networkProxy( this.networkProxy ) );