HTTPCLIENT-729: moved HttpRoute and friends to conn.routing
git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@613654 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
dfffbc9a3c
commit
bcc2848421
|
@ -1,6 +1,9 @@
|
|||
Changes since 4.0 Alpha 2
|
||||
-------------------
|
||||
|
||||
* [HTTPCLIENT-729] Move HttpRoute and related classes to routing package.
|
||||
Contributed by Roland Weber <rolandw at apache.org>
|
||||
|
||||
* [HTTPCLIENT-725] Use TimeUnit arguments for timeouts in connection manager.
|
||||
Contributed by Roland Weber <rolandw at apache.org>
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ import org.apache.http.HttpRequest;
|
|||
import org.apache.http.HttpResponse;
|
||||
import org.apache.http.HttpVersion;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.PlainSocketFactory;
|
||||
import org.apache.http.conn.Scheme;
|
||||
|
|
|
@ -38,7 +38,7 @@ import org.apache.http.HttpRequest;
|
|||
import org.apache.http.HttpResponse;
|
||||
import org.apache.http.HttpVersion;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.PlainSocketFactory;
|
||||
import org.apache.http.conn.Scheme;
|
||||
|
|
|
@ -36,6 +36,8 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.apache.http.params.HttpParams;
|
||||
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -40,6 +40,9 @@ import org.apache.http.HttpHost;
|
|||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* A client-side connection with advanced connection logic.
|
||||
|
|
|
@ -33,7 +33,7 @@ package org.apache.http.conn.params;
|
|||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.params.HttpParams;
|
||||
|
||||
/**
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
|
||||
|
|
@ -29,7 +29,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
import java.net.InetAddress;
|
||||
|
|
@ -29,7 +29,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
|
||||
|
|
@ -29,7 +29,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
import org.apache.http.HttpException;
|
||||
import org.apache.http.HttpHost;
|
|
@ -29,14 +29,14 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
import java.net.InetAddress;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.util.CharArrayBuffer;
|
||||
import org.apache.http.conn.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.HttpRoute.LayerType;
|
||||
import org.apache.http.conn.routing.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.routing.HttpRoute.LayerType;
|
||||
|
||||
|
||||
/**
|
|
@ -51,7 +51,7 @@ import org.apache.http.client.HttpRequestRetryHandler;
|
|||
import org.apache.http.client.RedirectHandler;
|
||||
import org.apache.http.client.methods.HttpUriRequest;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoutePlanner;
|
||||
import org.apache.http.conn.routing.HttpRoutePlanner;
|
||||
import org.apache.http.cookie.CookieSpecRegistry;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.BasicHttpProcessor;
|
||||
|
|
|
@ -69,12 +69,12 @@ import org.apache.http.client.protocol.ClientContext;
|
|||
import org.apache.http.conn.BasicManagedEntity;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.HttpRoutePlanner;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.HttpRouteDirector;
|
||||
import org.apache.http.conn.BasicRouteDirector;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoutePlanner;
|
||||
import org.apache.http.conn.routing.HttpRouteDirector;
|
||||
import org.apache.http.conn.routing.BasicRouteDirector;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.entity.BufferedHttpEntity;
|
||||
import org.apache.http.message.BasicHttpRequest;
|
||||
import org.apache.http.params.HttpConnectionParams;
|
||||
|
|
|
@ -50,7 +50,7 @@ import org.apache.http.client.protocol.RequestTargetAuthentication;
|
|||
import org.apache.http.client.protocol.ResponseProcessCookies;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ClientConnectionManagerFactory;
|
||||
import org.apache.http.conn.HttpRoutePlanner;
|
||||
import org.apache.http.conn.routing.HttpRoutePlanner;
|
||||
import org.apache.http.conn.PlainSocketFactory;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
package org.apache.http.impl.client;
|
||||
|
||||
import org.apache.http.HttpRequest;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -36,9 +36,9 @@ import java.io.IOException;
|
|||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.routing.RouteTracker;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.RouteTracker;
|
||||
import org.apache.http.conn.OperatedClientConnection;
|
||||
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ import java.io.IOException;
|
|||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
|
||||
|
|
|
@ -39,10 +39,10 @@ import org.apache.http.HttpHost;
|
|||
import org.apache.http.HttpRequest;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.HttpRoutePlanner;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoutePlanner;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
|
||||
import org.apache.http.conn.params.ConnRoutePNames;
|
||||
|
||||
|
|
|
@ -45,10 +45,10 @@ import org.apache.http.HttpHost;
|
|||
import org.apache.http.HttpRequest;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.HttpRoutePlanner;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoutePlanner;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
|
||||
import org.apache.http.conn.params.ConnRoutePNames;
|
||||
|
||||
|
|
|
@ -36,9 +36,9 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.OperatedClientConnection;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
|
|
|
@ -43,10 +43,10 @@ import java.util.concurrent.locks.ReentrantLock;
|
|||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.OperatedClientConnection;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.impl.conn.IdleConnectionHandler;
|
||||
|
|
|
@ -33,7 +33,7 @@ package org.apache.http.impl.conn.tsccm;
|
|||
|
||||
import java.lang.ref.ReferenceQueue;
|
||||
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.OperatedClientConnection;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.impl.conn.AbstractPoolEntry;
|
||||
|
|
|
@ -34,7 +34,7 @@ package org.apache.http.impl.conn.tsccm;
|
|||
import java.lang.ref.WeakReference;
|
||||
import java.lang.ref.ReferenceQueue;
|
||||
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -41,10 +41,10 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.params.HttpConnectionManagerParams;
|
||||
|
||||
|
||||
|
|
|
@ -33,7 +33,8 @@ package org.apache.http.impl.conn.tsccm;
|
|||
import java.util.Queue;
|
||||
import java.util.LinkedList;
|
||||
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
/**
|
||||
* A connection sub-pool for a specific route, used by {@link ConnPoolByRoute}.
|
||||
|
|
|
@ -35,10 +35,10 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.ClientConnectionOperator;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.OperatedClientConnection;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
|
||||
package org.apache.http.conn;
|
||||
|
||||
import org.apache.http.conn.routing.TestAllRouting;
|
||||
import org.apache.http.conn.ssl.TestAllSSL;
|
||||
import org.apache.http.conn.util.TestAllUtil;
|
||||
|
||||
|
@ -46,12 +47,10 @@ public class TestAllConn extends TestCase {
|
|||
public static Test suite() {
|
||||
TestSuite suite = new TestSuite();
|
||||
|
||||
suite.addTest(TestHttpRoute.suite());
|
||||
suite.addTest(TestRouteDirector.suite());
|
||||
suite.addTest(TestRouteTracker.suite());
|
||||
suite.addTest(TestScheme.suite());
|
||||
suite.addTest(TestParams.suite());
|
||||
suite.addTest(TestExceptions.suite());
|
||||
suite.addTest(TestAllRouting.suite());
|
||||
suite.addTest(TestAllSSL.suite());
|
||||
suite.addTest(TestAllUtil.suite());
|
||||
|
||||
|
|
|
@ -39,6 +39,7 @@ import org.apache.http.HttpHost;
|
|||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.params.BasicHttpParams;
|
||||
import org.apache.http.conn.params.HttpConnectionManagerParams;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -0,0 +1,58 @@
|
|||
/*
|
||||
* $HeadURL$
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* ====================================================================
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
* ====================================================================
|
||||
*
|
||||
* This software consists of voluntary contributions made by many
|
||||
* individuals on behalf of the Apache Software Foundation. For more
|
||||
* information on the Apache Software Foundation, please see
|
||||
* <http://www.apache.org/>.
|
||||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
import junit.framework.Test;
|
||||
import junit.framework.TestCase;
|
||||
import junit.framework.TestSuite;
|
||||
|
||||
public class TestAllRouting extends TestCase {
|
||||
|
||||
public TestAllRouting(String testName) {
|
||||
super(testName);
|
||||
}
|
||||
|
||||
public static Test suite() {
|
||||
TestSuite suite = new TestSuite();
|
||||
|
||||
suite.addTest(TestHttpRoute.suite());
|
||||
suite.addTest(TestRouteDirector.suite());
|
||||
suite.addTest(TestRouteTracker.suite());
|
||||
|
||||
return suite;
|
||||
}
|
||||
|
||||
public static void main(String args[]) {
|
||||
String[] testCaseName = { TestAllRouting.class.getName() };
|
||||
junit.textui.TestRunner.main(testCaseName);
|
||||
}
|
||||
|
||||
}
|
|
@ -28,7 +28,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
|
||||
import java.net.InetAddress;
|
||||
|
@ -41,8 +41,8 @@ import junit.framework.TestCase;
|
|||
import junit.framework.TestSuite;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.HttpRoute.LayerType;
|
||||
import org.apache.http.conn.routing.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.routing.HttpRoute.LayerType;
|
||||
|
||||
|
||||
/**
|
|
@ -28,7 +28,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
|
||||
import java.net.InetAddress;
|
||||
|
@ -38,8 +38,8 @@ import junit.framework.TestCase;
|
|||
import junit.framework.TestSuite;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.HttpRoute.LayerType;
|
||||
import org.apache.http.conn.routing.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.routing.HttpRoute.LayerType;
|
||||
|
||||
|
||||
/**
|
|
@ -28,7 +28,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
package org.apache.http.conn;
|
||||
package org.apache.http.conn.routing;
|
||||
|
||||
|
||||
import java.net.InetAddress;
|
||||
|
@ -40,8 +40,8 @@ import junit.framework.TestCase;
|
|||
import junit.framework.TestSuite;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.HttpRoute.LayerType;
|
||||
import org.apache.http.conn.routing.HttpRoute.TunnelType;
|
||||
import org.apache.http.conn.routing.HttpRoute.LayerType;
|
||||
|
||||
|
||||
/**
|
|
@ -31,7 +31,7 @@
|
|||
package org.apache.http.impl.conn;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ package org.apache.http.impl.conn;
|
|||
import org.apache.http.HttpRequest;
|
||||
import org.apache.http.HttpResponse;
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.params.HttpParams;
|
||||
import org.apache.http.protocol.HttpContext;
|
||||
import org.apache.http.protocol.ExecutionContext;
|
||||
|
|
|
@ -33,7 +33,7 @@ package org.apache.http.impl.conn;
|
|||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import org.apache.http.conn.ClientConnectionManager;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ import junit.framework.TestSuite;
|
|||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.HttpVersion;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.PlainSocketFactory;
|
||||
import org.apache.http.conn.Scheme;
|
||||
|
|
|
@ -43,7 +43,7 @@ import org.apache.http.HttpResponse;
|
|||
import org.apache.http.HttpStatus;
|
||||
import org.apache.http.HttpVersion;
|
||||
import org.apache.http.conn.ConnectionPoolTimeoutException;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.ManagedClientConnection;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
import org.apache.http.conn.params.HttpConnectionManagerParams;
|
||||
|
|
|
@ -43,7 +43,7 @@ import junit.framework.TestSuite;
|
|||
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
import org.apache.http.conn.SocketFactory;
|
||||
|
|
|
@ -39,7 +39,7 @@ import junit.framework.TestCase;
|
|||
import junit.framework.TestSuite;
|
||||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ import junit.framework.TestCase;
|
|||
|
||||
import org.apache.http.HttpHost;
|
||||
import org.apache.http.HttpVersion;
|
||||
import org.apache.http.conn.HttpRoute;
|
||||
import org.apache.http.conn.routing.HttpRoute;
|
||||
import org.apache.http.conn.PlainSocketFactory;
|
||||
import org.apache.http.conn.Scheme;
|
||||
import org.apache.http.conn.SchemeRegistry;
|
||||
|
|
Loading…
Reference in New Issue