hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1770506 [3/6] - in /httpcomponents/httpclient/branches/4.5.x: ./ fluent-hc/src/main/java/org/apache/http/client/fluent/ httpclient-cache/src/main/java-deprecated/org/apache/http/impl/client/cache/ httpclient-cache/src/main/java/org/apache/...
Date Sat, 19 Nov 2016 16:40:56 GMT
Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/SingleClientConnManager.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/SingleClientConnManager.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/SingleClientConnManager.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/SingleClientConnManager.java Sat Nov 19 16:40:54 2016
@@ -32,8 +32,8 @@ import java.util.concurrent.TimeUnit;
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.http.annotation.GuardedBy;
-import org.apache.http.annotation.ThreadSafe;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.conn.ClientConnectionManager;
 import org.apache.http.conn.ClientConnectionOperator;
 import org.apache.http.conn.ClientConnectionRequest;
@@ -61,7 +61,7 @@ import org.apache.http.util.Asserts;
  *
  * @deprecated (4.2)  use {@link BasicClientConnectionManager}
  */
-@ThreadSafe
+@Contract(threading = ThreadingBehavior.SAFE)
 @Deprecated
 public class SingleClientConnManager implements ClientConnectionManager {
 
@@ -82,19 +82,15 @@ public class SingleClientConnManager imp
     protected final boolean alwaysShutDown;
 
     /** The one and only entry in this pool. */
-    @GuardedBy("this")
     protected volatile PoolEntry uniquePoolEntry;
 
     /** The currently issued managed connection, if any. */
-    @GuardedBy("this")
     protected volatile ConnAdapter managedConn;
 
     /** The time of the last connection release, or -1. */
-    @GuardedBy("this")
     protected volatile long lastReleaseTime;
 
     /** The time the last released connection expires and shouldn't be reused. */
-    @GuardedBy("this")
     protected volatile long connectionExpiresTime;
 
     /** Indicates whether this connection manager is shut down. */

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/AbstractConnPool.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/AbstractConnPool.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/AbstractConnPool.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/AbstractConnPool.java Sat Nov 19 16:40:54 2016
@@ -38,7 +38,6 @@ import java.util.concurrent.locks.Reentr
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.http.annotation.GuardedBy;
 import org.apache.http.conn.ConnectionPoolTimeoutException;
 import org.apache.http.conn.OperatedClientConnection;
 import org.apache.http.conn.routing.HttpRoute;
@@ -66,12 +65,8 @@ public abstract class AbstractConnPool {
      */
     protected final Lock poolLock;
 
-    /** References to issued connections */
-    @GuardedBy("poolLock")
     protected Set<BasicPoolEntry> leasedConnections;
 
-    /** The current total number of connections. */
-    @GuardedBy("poolLock")
     protected int numConnections;
 
     /** Indicates whether this pool is shut down. */

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/BasicPoolEntryRef.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/BasicPoolEntryRef.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/BasicPoolEntryRef.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/BasicPoolEntryRef.java Sat Nov 19 16:40:54 2016
@@ -45,7 +45,7 @@ import org.apache.http.util.Args;
 public class BasicPoolEntryRef extends WeakReference<BasicPoolEntry> {
 
     /** The planned route of the entry. */
-    private final HttpRoute route; // HttpRoute is @Immutable
+    private final HttpRoute route; // HttpRoute is @Contract(threading = ThreadingBehavior.IMMUTABLE)
 
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/ThreadSafeClientConnManager.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/ThreadSafeClientConnManager.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/ThreadSafeClientConnManager.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/conn/tsccm/ThreadSafeClientConnManager.java Sat Nov 19 16:40:54 2016
@@ -31,7 +31,8 @@ import java.util.concurrent.TimeUnit;
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.http.annotation.ThreadSafe;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.conn.ClientConnectionManager;
 import org.apache.http.conn.ClientConnectionOperator;
 import org.apache.http.conn.ClientConnectionRequest;
@@ -66,14 +67,14 @@ import org.apache.http.util.Asserts;
  *
  * @deprecated (4.2)  use {@link org.apache.http.impl.conn.PoolingHttpClientConnectionManager}
  */
-@ThreadSafe
+@Contract(threading = ThreadingBehavior.SAFE_CONDITIONAL)
 @Deprecated
 public class ThreadSafeClientConnManager implements ClientConnectionManager {
 
     private final Log log;
 
     /** The schemes supported by this connection manager. */
-    protected final SchemeRegistry schemeRegistry; // @ThreadSafe
+    protected final SchemeRegistry schemeRegistry; // @Contract(threading = ThreadingBehavior.SAFE)
 
     protected final AbstractConnPool connectionPool;
 
@@ -81,7 +82,7 @@ public class ThreadSafeClientConnManager
     protected final ConnPoolByRoute pool;
 
     /** The operator for opening and updating connections. */
-    protected final ClientConnectionOperator connOperator; // DefaultClientConnectionOperator is @ThreadSafe
+    protected final ClientConnectionOperator connOperator; // DefaultClientConnectionOperator is @Contract(threading = ThreadingBehavior.SAFE)
 
     protected final ConnPerRouteBean connPerRoute;
 
@@ -206,7 +207,7 @@ public class ThreadSafeClientConnManager
     protected ClientConnectionOperator
         createConnectionOperator(final SchemeRegistry schreg) {
 
-        return new DefaultClientConnectionOperator(schreg);// @ThreadSafe
+        return new DefaultClientConnectionOperator(schreg);// @Contract(threading = ThreadingBehavior.SAFE)
     }
 
     @Override

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpec.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpec.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpec.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpec.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,8 @@
 
 package org.apache.http.impl.cookie;
 
-import org.apache.http.annotation.ThreadSafe;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 
 /**
  * 'Meta' cookie specification that picks up a cookie policy based on
@@ -37,7 +38,7 @@ import org.apache.http.annotation.Thread
  *
  * @since 4.0
  */
-@ThreadSafe
+@Contract(threading = ThreadingBehavior.SAFE)
 @Deprecated
 public class BestMatchSpec extends DefaultCookieSpec {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BestMatchSpecFactory.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 
 import java.util.Collection;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -46,7 +47,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class BestMatchSpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpec.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpec.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpec.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpec.java Sat Nov 19 16:40:54 2016
@@ -36,7 +36,8 @@ import org.apache.http.FormattedHeader;
 import org.apache.http.Header;
 import org.apache.http.HeaderElement;
 import org.apache.http.NameValuePair;
-import org.apache.http.annotation.ThreadSafe;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.utils.DateUtils;
 import org.apache.http.cookie.Cookie;
 import org.apache.http.cookie.CookieAttributeHandler;
@@ -61,7 +62,7 @@ import org.apache.http.util.CharArrayBuf
  * @since 4.0
  */
 @Deprecated
-@ThreadSafe
+@Contract(threading = ThreadingBehavior.SAFE)
 public class BrowserCompatSpec extends CookieSpecBase {
 
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatSpecFactory.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 
 import java.util.Collection;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -46,7 +47,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class BrowserCompatSpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatVersionAttributeHandler.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatVersionAttributeHandler.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatVersionAttributeHandler.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/BrowserCompatVersionAttributeHandler.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,8 @@
 
 package org.apache.http.impl.cookie;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.ClientCookie;
 import org.apache.http.cookie.CommonCookieAttributeHandler;
 import org.apache.http.cookie.MalformedCookieException;
@@ -42,7 +43,7 @@ import org.apache.http.util.Args;
  * @since 4.3
  */
 @Deprecated
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class BrowserCompatVersionAttributeHandler extends
         AbstractCookieAttributeHandler implements CommonCookieAttributeHandler {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateParseException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateParseException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateParseException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateParseException.java Sat Nov 19 16:40:54 2016
@@ -27,8 +27,6 @@
 
 package org.apache.http.impl.cookie;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * An exception to indicate an error parsing a date string.
  *
@@ -40,7 +38,6 @@ import org.apache.http.annotation.Immuta
  * @deprecated (4.3) no longer used.
  */
 @Deprecated
-@Immutable
 public class DateParseException extends Exception {
 
     private static final long serialVersionUID = 4417696455000643370L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateUtils.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateUtils.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateUtils.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/DateUtils.java Sat Nov 19 16:40:54 2016
@@ -30,8 +30,6 @@ package org.apache.http.impl.cookie;
 import java.util.Date;
 import java.util.TimeZone;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * A utility class for parsing and formatting HTTP dates as used in cookies and
  * other headers.  This class handles dates as defined by RFC 2616 section
@@ -43,7 +41,6 @@ import org.apache.http.annotation.Immuta
  * @deprecated (4.3) Use {@link org.apache.http.client.utils.DateUtils}.
  */
 @Deprecated
-@Immutable
 public final class DateUtils {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/IgnoreSpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/IgnoreSpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/IgnoreSpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/IgnoreSpecFactory.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,8 @@
 
 package org.apache.http.impl.cookie;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -41,7 +42,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.1
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class IgnoreSpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/NetscapeDraftSpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/NetscapeDraftSpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/NetscapeDraftSpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/NetscapeDraftSpecFactory.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 
 import java.util.Collection;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -46,7 +47,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class NetscapeDraftSpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/PublicSuffixListParser.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/PublicSuffixListParser.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/PublicSuffixListParser.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/PublicSuffixListParser.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 import java.io.IOException;
 import java.io.Reader;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.conn.util.PublicSuffixList;
 
 /**
@@ -40,7 +41,7 @@ import org.apache.http.conn.util.PublicS
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class PublicSuffixListParser {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2109SpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2109SpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2109SpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2109SpecFactory.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 
 import java.util.Collection;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -46,7 +47,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class RFC2109SpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2965SpecFactory.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2965SpecFactory.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2965SpecFactory.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java-deprecated/org/apache/http/impl/cookie/RFC2965SpecFactory.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.impl.cookie;
 
 import java.util.Collection;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.cookie.CookieSpec;
 import org.apache.http.cookie.CookieSpecFactory;
 import org.apache.http.cookie.CookieSpecProvider;
@@ -46,7 +47,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 @Deprecated
 public class RFC2965SpecFactory implements CookieSpecFactory, CookieSpecProvider {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AUTH.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AUTH.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AUTH.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AUTH.java Sat Nov 19 16:40:54 2016
@@ -27,15 +27,12 @@
 
 package org.apache.http.auth;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Constants and static helpers related to the HTTP authentication.
  *
  *
  * @since 4.0
  */
-@Immutable
 public final class AUTH {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthOption.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthOption.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthOption.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthOption.java Sat Nov 19 16:40:54 2016
@@ -26,13 +26,14 @@
  */
 package org.apache.http.auth;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 
 /**
  * @since 4.2
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public final class AuthOption {
 
     private final AuthScheme authScheme;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthSchemeRegistry.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthSchemeRegistry.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthSchemeRegistry.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthSchemeRegistry.java Sat Nov 19 16:40:54 2016
@@ -33,7 +33,8 @@ import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
 
 import org.apache.http.HttpRequest;
-import org.apache.http.annotation.ThreadSafe;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.config.Lookup;
 import org.apache.http.params.HttpParams;
 import org.apache.http.protocol.ExecutionContext;
@@ -48,7 +49,7 @@ import org.apache.http.util.Args;
  *
  * @deprecated (4.3) use {@link org.apache.http.config.Registry}
  */
-@ThreadSafe
+@Contract(threading = ThreadingBehavior.SAFE)
 @Deprecated
 public final class AuthSchemeRegistry implements Lookup<AuthSchemeProvider> {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthScope.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthScope.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthScope.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthScope.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.auth;
 import java.util.Locale;
 
 import org.apache.http.HttpHost;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 import org.apache.http.util.LangUtils;
 
@@ -42,7 +43,7 @@ import org.apache.http.util.LangUtils;
  * </p>
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class AuthScope {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthState.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthState.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthState.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthState.java Sat Nov 19 16:40:54 2016
@@ -28,7 +28,6 @@ package org.apache.http.auth;
 
 import java.util.Queue;
 
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.util.Args;
 
 /**
@@ -36,7 +35,6 @@ import org.apache.http.util.Args;
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class AuthState {
 
     /** Actual state of authentication protocol */

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthenticationException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthenticationException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthenticationException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/AuthenticationException.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,6 @@
 package org.apache.http.auth;
 
 import org.apache.http.ProtocolException;
-import org.apache.http.annotation.Immutable;
 
 /**
  * Signals a failure in authentication process
@@ -35,7 +34,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class AuthenticationException extends ProtocolException {
 
     private static final long serialVersionUID = -6794031905674764776L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/BasicUserPrincipal.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/BasicUserPrincipal.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/BasicUserPrincipal.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/BasicUserPrincipal.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.auth;
 import java.io.Serializable;
 import java.security.Principal;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 import org.apache.http.util.LangUtils;
 
@@ -38,7 +39,7 @@ import org.apache.http.util.LangUtils;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public final class BasicUserPrincipal implements Principal, Serializable {
 
     private static final long serialVersionUID = -2266305184969850467L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/InvalidCredentialsException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/InvalidCredentialsException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/InvalidCredentialsException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/InvalidCredentialsException.java Sat Nov 19 16:40:54 2016
@@ -26,8 +26,6 @@
  */
 package org.apache.http.auth;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Authentication credentials required to respond to a authentication
  * challenge are invalid
@@ -35,7 +33,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class InvalidCredentialsException extends AuthenticationException {
 
     private static final long serialVersionUID = -4834003835215460648L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/KerberosCredentials.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/KerberosCredentials.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/KerberosCredentials.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/KerberosCredentials.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.auth;
 import java.io.Serializable;
 import java.security.Principal;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.ietf.jgss.GSSCredential;
 
 /**
@@ -37,7 +38,7 @@ import org.ietf.jgss.GSSCredential;
  *
  * @since 4.4
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class KerberosCredentials implements Credentials, Serializable {
 
     private static final long serialVersionUID = 487421613855550713L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/MalformedChallengeException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/MalformedChallengeException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/MalformedChallengeException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/MalformedChallengeException.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,6 @@
 package org.apache.http.auth;
 
 import org.apache.http.ProtocolException;
-import org.apache.http.annotation.Immutable;
 
 /**
  * Signals that authentication challenge is in some way invalid or
@@ -36,7 +35,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class MalformedChallengeException extends ProtocolException {
 
     private static final long serialVersionUID = 814586927989932284L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTCredentials.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTCredentials.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTCredentials.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTCredentials.java Sat Nov 19 16:40:54 2016
@@ -30,7 +30,8 @@ import java.io.Serializable;
 import java.security.Principal;
 import java.util.Locale;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 import org.apache.http.util.LangUtils;
 
@@ -40,7 +41,7 @@ import org.apache.http.util.LangUtils;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class NTCredentials implements Credentials, Serializable {
 
     private static final long serialVersionUID = -7385699315228907265L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTUserPrincipal.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTUserPrincipal.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTUserPrincipal.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/NTUserPrincipal.java Sat Nov 19 16:40:54 2016
@@ -30,7 +30,8 @@ import java.io.Serializable;
 import java.security.Principal;
 import java.util.Locale;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 import org.apache.http.util.LangUtils;
 
@@ -39,7 +40,7 @@ import org.apache.http.util.LangUtils;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class NTUserPrincipal implements Principal, Serializable {
 
     private static final long serialVersionUID = -6870169797924406894L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/UsernamePasswordCredentials.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/UsernamePasswordCredentials.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/UsernamePasswordCredentials.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/auth/UsernamePasswordCredentials.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,8 @@ package org.apache.http.auth;
 import java.io.Serializable;
 import java.security.Principal;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 import org.apache.http.util.LangUtils;
 
@@ -39,7 +40,7 @@ import org.apache.http.util.LangUtils;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class UsernamePasswordCredentials implements Credentials, Serializable {
 
     private static final long serialVersionUID = 243343858802739403L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/CircularRedirectException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/CircularRedirectException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/CircularRedirectException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/CircularRedirectException.java Sat Nov 19 16:40:54 2016
@@ -26,15 +26,12 @@
  */
 package org.apache.http.client;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Signals a circular redirect
  *
  *
  * @since 4.0
  */
-@Immutable
 public class CircularRedirectException extends RedirectException {
 
     private static final long serialVersionUID = 6830063487001091803L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/ClientProtocolException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/ClientProtocolException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/ClientProtocolException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/ClientProtocolException.java Sat Nov 19 16:40:54 2016
@@ -28,14 +28,11 @@ package org.apache.http.client;
 
 import java.io.IOException;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Signals an error in the HTTP protocol.
  *
  * @since 4.0
  */
-@Immutable
 public class ClientProtocolException extends IOException {
 
     private static final long serialVersionUID = -5596590843227115865L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/HttpResponseException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/HttpResponseException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/HttpResponseException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/HttpResponseException.java Sat Nov 19 16:40:54 2016
@@ -26,14 +26,11 @@
  */
 package org.apache.http.client;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Signals a non 2xx HTTP response.
  *
  * @since 4.0
  */
-@Immutable
 public class HttpResponseException extends ClientProtocolException {
 
     private static final long serialVersionUID = -7186627969477257933L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/NonRepeatableRequestException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/NonRepeatableRequestException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/NonRepeatableRequestException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/NonRepeatableRequestException.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,6 @@
 package org.apache.http.client;
 
 import org.apache.http.ProtocolException;
-import org.apache.http.annotation.Immutable;
 
 /**
  * Signals failure to retry the request due to non-repeatable request
@@ -36,7 +35,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class NonRepeatableRequestException extends ProtocolException {
 
     private static final long serialVersionUID = 82685265288806048L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/RedirectException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/RedirectException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/RedirectException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/RedirectException.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,6 @@
 package org.apache.http.client;
 
 import org.apache.http.ProtocolException;
-import org.apache.http.annotation.Immutable;
 
 /**
  * Signals violation of HTTP specification caused by an invalid redirect
@@ -35,7 +34,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class RedirectException extends ProtocolException {
 
     private static final long serialVersionUID = 4418824536372559326L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/AuthSchemes.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/AuthSchemes.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/AuthSchemes.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/AuthSchemes.java Sat Nov 19 16:40:54 2016
@@ -27,14 +27,11 @@
 
 package org.apache.http.client.config;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Standard authentication schemes supported by HttpClient.
  *
  * @since 4.3
  */
-@Immutable
 public final class AuthSchemes {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/CookieSpecs.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/CookieSpecs.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/CookieSpecs.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/CookieSpecs.java Sat Nov 19 16:40:54 2016
@@ -27,14 +27,11 @@
 
 package org.apache.http.client.config;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Standard cookie specifications supported by HttpClient.
  *
  * @since 4.3
  */
-@Immutable
 public final class CookieSpecs {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/RequestConfig.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/RequestConfig.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/RequestConfig.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/config/RequestConfig.java Sat Nov 19 16:40:54 2016
@@ -31,14 +31,15 @@ import java.net.InetAddress;
 import java.util.Collection;
 
 import org.apache.http.HttpHost;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 
 /**
  *  Immutable class encapsulating request configuration items.
  *  The default setting for stale connection checking changed
  *  to false, and the feature was deprecated starting with version 4.4.
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestConfig implements Cloneable {
 
     public static final RequestConfig DEFAULT = new Builder().build();

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/EntityBuilder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/EntityBuilder.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/EntityBuilder.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/EntityBuilder.java Sat Nov 19 16:40:54 2016
@@ -35,7 +35,6 @@ import java.util.List;
 
 import org.apache.http.HttpEntity;
 import org.apache.http.NameValuePair;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.entity.AbstractHttpEntity;
 import org.apache.http.entity.BasicHttpEntity;
 import org.apache.http.entity.ByteArrayEntity;
@@ -63,7 +62,6 @@ import org.apache.http.entity.StringEnti
  *
  * @since 4.3
  */
-@NotThreadSafe
 public class EntityBuilder {
 
     private String text;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/LazyDecompressingInputStream.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/LazyDecompressingInputStream.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/LazyDecompressingInputStream.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/LazyDecompressingInputStream.java Sat Nov 19 16:40:54 2016
@@ -29,12 +29,9 @@ package org.apache.http.client.entity;
 import java.io.IOException;
 import java.io.InputStream;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * Lazy init InputStream wrapper.
  */
-@NotThreadSafe
 class LazyDecompressingInputStream extends InputStream {
 
     private final InputStream wrappedStream;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/UrlEncodedFormEntity.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/UrlEncodedFormEntity.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/UrlEncodedFormEntity.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/entity/UrlEncodedFormEntity.java Sat Nov 19 16:40:54 2016
@@ -31,7 +31,6 @@ import java.nio.charset.Charset;
 import java.util.List;
 
 import org.apache.http.NameValuePair;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.client.utils.URLEncodedUtils;
 import org.apache.http.entity.ContentType;
 import org.apache.http.entity.StringEntity;
@@ -43,7 +42,6 @@ import org.apache.http.protocol.HTTP;
  *
  * @since 4.0
  */
-@NotThreadSafe // AbstractHttpEntity is not thread-safe
 public class UrlEncodedFormEntity extends StringEntity {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpDelete.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpDelete.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpDelete.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpDelete.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP DELETE method
  * <p>
@@ -46,7 +44,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe // HttpRequestBase is @NotThreadSafe
 public class HttpDelete extends HttpRequestBase {
 
     public final static String METHOD_NAME = "DELETE";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpEntityEnclosingRequestBase.java Sat Nov 19 16:40:54 2016
@@ -30,7 +30,6 @@ package org.apache.http.client.methods;
 import org.apache.http.Header;
 import org.apache.http.HttpEntity;
 import org.apache.http.HttpEntityEnclosingRequest;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.client.utils.CloneUtils;
 import org.apache.http.protocol.HTTP;
 
@@ -40,7 +39,6 @@ import org.apache.http.protocol.HTTP;
  *
  * @since 4.0
  */
-@NotThreadSafe // HttpRequestBase is @NotThreadSafe
 public abstract class HttpEntityEnclosingRequestBase
     extends HttpRequestBase implements HttpEntityEnclosingRequest {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpGet.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpGet.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpGet.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpGet.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP GET method.
  * <p>
@@ -47,7 +45,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpGet extends HttpRequestBase {
 
     public final static String METHOD_NAME = "GET";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpHead.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpHead.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpHead.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpHead.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP HEAD method.
  * <p>
@@ -50,7 +48,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpHead extends HttpRequestBase {
 
     public final static String METHOD_NAME = "HEAD";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpOptions.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpOptions.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpOptions.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpOptions.java Sat Nov 19 16:40:54 2016
@@ -35,7 +35,6 @@ import org.apache.http.Header;
 import org.apache.http.HeaderElement;
 import org.apache.http.HeaderIterator;
 import org.apache.http.HttpResponse;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.util.Args;
 
 /**
@@ -55,7 +54,6 @@ import org.apache.http.util.Args;
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpOptions extends HttpRequestBase {
 
     public final static String METHOD_NAME = "OPTIONS";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPatch.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPatch.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPatch.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPatch.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP PATCH method.
  * <p>
@@ -50,7 +48,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.2
  */
-@NotThreadSafe
 public class HttpPatch extends HttpEntityEnclosingRequestBase {
 
     public final static String METHOD_NAME = "PATCH";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPost.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPost.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPost.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPost.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP POST method.
  * <p>
@@ -54,7 +52,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpPost extends HttpEntityEnclosingRequestBase {
 
     public final static String METHOD_NAME = "POST";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPut.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPut.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPut.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpPut.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP PUT method.
  * <p>
@@ -46,7 +44,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpPut extends HttpEntityEnclosingRequestBase {
 
     public final static String METHOD_NAME = "PUT";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestBase.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestBase.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestBase.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestBase.java Sat Nov 19 16:40:54 2016
@@ -31,7 +31,6 @@ import java.net.URI;
 
 import org.apache.http.ProtocolVersion;
 import org.apache.http.RequestLine;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.client.config.RequestConfig;
 import org.apache.http.message.BasicRequestLine;
 import org.apache.http.params.HttpProtocolParams;
@@ -42,7 +41,6 @@ import org.apache.http.params.HttpProtoc
  * @since 4.0
  */
 @SuppressWarnings("deprecation")
-@NotThreadSafe
 public abstract class HttpRequestBase extends AbstractExecutionAwareRequest
     implements HttpUriRequest, Configurable {
 

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestWrapper.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestWrapper.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestWrapper.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpRequestWrapper.java Sat Nov 19 16:40:54 2016
@@ -36,7 +36,6 @@ import org.apache.http.HttpHost;
 import org.apache.http.HttpRequest;
 import org.apache.http.ProtocolVersion;
 import org.apache.http.RequestLine;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.message.AbstractHttpMessage;
 import org.apache.http.message.BasicRequestLine;
 import org.apache.http.params.HttpParams;
@@ -50,7 +49,6 @@ import org.apache.http.util.Args;
  * @since 4.3
  */
 @SuppressWarnings("deprecation")
-@NotThreadSafe
 public class HttpRequestWrapper extends AbstractHttpMessage implements HttpUriRequest {
 
     private final HttpRequest original;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpTrace.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpTrace.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpTrace.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/HttpTrace.java Sat Nov 19 16:40:54 2016
@@ -29,8 +29,6 @@ package org.apache.http.client.methods;
 
 import java.net.URI;
 
-import org.apache.http.annotation.NotThreadSafe;
-
 /**
  * HTTP TRACE method.
  * <p>
@@ -49,7 +47,6 @@ import org.apache.http.annotation.NotThr
  *
  * @since 4.0
  */
-@NotThreadSafe
 public class HttpTrace extends HttpRequestBase {
 
     public final static String METHOD_NAME = "TRACE";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/RequestBuilder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/RequestBuilder.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/RequestBuilder.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/methods/RequestBuilder.java Sat Nov 19 16:40:54 2016
@@ -43,7 +43,6 @@ import org.apache.http.HttpEntityEnclosi
 import org.apache.http.HttpRequest;
 import org.apache.http.NameValuePair;
 import org.apache.http.ProtocolVersion;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.client.config.RequestConfig;
 import org.apache.http.client.entity.UrlEncodedFormEntity;
 import org.apache.http.client.utils.URIBuilder;
@@ -67,7 +66,6 @@ import org.apache.http.util.Args;
  *
  * @since 4.3
  */
-@NotThreadSafe
 public class RequestBuilder {
 
     private String method;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/HttpClientContext.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/HttpClientContext.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/HttpClientContext.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/HttpClientContext.java Sat Nov 19 16:40:54 2016
@@ -30,7 +30,6 @@ package org.apache.http.client.protocol;
 import java.net.URI;
 import java.util.List;
 
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.auth.AuthSchemeProvider;
 import org.apache.http.auth.AuthState;
 import org.apache.http.client.AuthCache;
@@ -54,7 +53,6 @@ import org.apache.http.protocol.HttpCore
  *
  * @since 4.3
  */
-@NotThreadSafe
 public class HttpClientContext extends HttpCoreContext {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAcceptEncoding.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAcceptEncoding.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAcceptEncoding.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAcceptEncoding.java Sat Nov 19 16:40:54 2016
@@ -32,7 +32,8 @@ import java.util.List;
 import org.apache.http.HttpException;
 import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.config.RequestConfig;
 import org.apache.http.protocol.HttpContext;
 
@@ -45,7 +46,7 @@ import org.apache.http.protocol.HttpCont
  *
  * @since 4.1
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestAcceptEncoding implements HttpRequestInterceptor {
 
     private final String acceptEncoding;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAddCookies.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAddCookies.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAddCookies.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAddCookies.java Sat Nov 19 16:40:54 2016
@@ -41,7 +41,8 @@ import org.apache.http.HttpException;
 import org.apache.http.HttpHost;
 import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.CookieStore;
 import org.apache.http.client.config.CookieSpecs;
 import org.apache.http.client.config.RequestConfig;
@@ -63,7 +64,7 @@ import org.apache.http.util.TextUtils;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestAddCookies implements HttpRequestInterceptor {
 
     private final Log log = LogFactory.getLog(getClass());

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAuthCache.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAuthCache.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAuthCache.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestAuthCache.java Sat Nov 19 16:40:54 2016
@@ -35,7 +35,8 @@ import org.apache.http.HttpException;
 import org.apache.http.HttpHost;
 import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.auth.AuthProtocolState;
 import org.apache.http.auth.AuthScheme;
 import org.apache.http.auth.AuthScope;
@@ -54,7 +55,7 @@ import org.apache.http.util.Args;
  *
  * @since 4.1
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestAuthCache implements HttpRequestInterceptor {
 
     private final Log log = LogFactory.getLog(getClass());

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestClientConnControl.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestClientConnControl.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestClientConnControl.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestClientConnControl.java Sat Nov 19 16:40:54 2016
@@ -34,7 +34,8 @@ import org.apache.commons.logging.LogFac
 import org.apache.http.HttpException;
 import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.conn.routing.RouteInfo;
 import org.apache.http.protocol.HTTP;
 import org.apache.http.protocol.HttpContext;
@@ -47,7 +48,7 @@ import org.apache.http.util.Args;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestClientConnControl implements HttpRequestInterceptor {
 
     private final Log log = LogFactory.getLog(getClass());

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestDefaultHeaders.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestDefaultHeaders.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestDefaultHeaders.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestDefaultHeaders.java Sat Nov 19 16:40:54 2016
@@ -34,7 +34,8 @@ import org.apache.http.Header;
 import org.apache.http.HttpException;
 import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.params.ClientPNames;
 import org.apache.http.protocol.HttpContext;
 import org.apache.http.util.Args;
@@ -45,7 +46,7 @@ import org.apache.http.util.Args;
  * @since 4.0
  */
 @SuppressWarnings("deprecation")
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE_CONDITIONAL)
 public class RequestDefaultHeaders implements HttpRequestInterceptor {
 
     private final Collection<? extends Header> defaultHeaders;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestExpectContinue.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestExpectContinue.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestExpectContinue.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/RequestExpectContinue.java Sat Nov 19 16:40:54 2016
@@ -36,7 +36,8 @@ import org.apache.http.HttpRequest;
 import org.apache.http.HttpRequestInterceptor;
 import org.apache.http.HttpVersion;
 import org.apache.http.ProtocolVersion;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.config.RequestConfig;
 import org.apache.http.protocol.HTTP;
 import org.apache.http.protocol.HttpContext;
@@ -52,7 +53,7 @@ import org.apache.http.util.Args;
  *
  * @since 4.3
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class RequestExpectContinue implements HttpRequestInterceptor {
 
     public RequestExpectContinue() {

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseContentEncoding.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseContentEncoding.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseContentEncoding.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseContentEncoding.java Sat Nov 19 16:40:54 2016
@@ -37,7 +37,8 @@ import org.apache.http.HttpEntity;
 import org.apache.http.HttpException;
 import org.apache.http.HttpResponse;
 import org.apache.http.HttpResponseInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.config.RequestConfig;
 import org.apache.http.client.entity.DecompressingEntity;
 import org.apache.http.client.entity.DeflateInputStream;
@@ -55,7 +56,7 @@ import org.apache.http.protocol.HttpCont
  * @since 4.1
  *
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE_CONDITIONAL)
 public class ResponseContentEncoding implements HttpResponseInterceptor {
 
     public static final String UNCOMPRESSED = "http.client.response.uncompressed";

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseProcessCookies.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseProcessCookies.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseProcessCookies.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/protocol/ResponseProcessCookies.java Sat Nov 19 16:40:54 2016
@@ -37,7 +37,8 @@ import org.apache.http.HeaderIterator;
 import org.apache.http.HttpException;
 import org.apache.http.HttpResponse;
 import org.apache.http.HttpResponseInterceptor;
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.client.CookieStore;
 import org.apache.http.cookie.Cookie;
 import org.apache.http.cookie.CookieOrigin;
@@ -53,7 +54,7 @@ import org.apache.http.util.Args;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class ResponseProcessCookies implements HttpResponseInterceptor {
 
     private final Log log = LogFactory.getLog(getClass());

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/CloneUtils.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/CloneUtils.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/CloneUtils.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/CloneUtils.java Sat Nov 19 16:40:54 2016
@@ -29,14 +29,11 @@ package org.apache.http.client.utils;
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * A collection of utilities to workaround limitations of Java clone framework.
  *
  * @since 4.0
  */
-@Immutable
 public class CloneUtils {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/DateUtils.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/DateUtils.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/DateUtils.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/DateUtils.java Sat Nov 19 16:40:54 2016
@@ -37,7 +37,6 @@ import java.util.Locale;
 import java.util.Map;
 import java.util.TimeZone;
 
-import org.apache.http.annotation.Immutable;
 import org.apache.http.util.Args;
 
 /**
@@ -47,7 +46,6 @@ import org.apache.http.util.Args;
  *
  * @since 4.3
  */
-@Immutable
 public final class DateUtils {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIBuilder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIBuilder.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIBuilder.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIBuilder.java Sat Nov 19 16:40:54 2016
@@ -35,7 +35,6 @@ import java.util.List;
 
 import org.apache.http.Consts;
 import org.apache.http.NameValuePair;
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.conn.util.InetAddressUtils;
 import org.apache.http.message.BasicNameValuePair;
 
@@ -44,7 +43,6 @@ import org.apache.http.message.BasicName
  *
  * @since 4.2
  */
-@NotThreadSafe
 public class URIBuilder {
 
     private String scheme;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIUtils.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIUtils.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIUtils.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URIUtils.java Sat Nov 19 16:40:54 2016
@@ -33,7 +33,6 @@ import java.util.Locale;
 import java.util.Stack;
 
 import org.apache.http.HttpHost;
-import org.apache.http.annotation.Immutable;
 import org.apache.http.conn.routing.RouteInfo;
 import org.apache.http.util.Args;
 import org.apache.http.util.TextUtils;
@@ -44,7 +43,6 @@ import org.apache.http.util.TextUtils;
  *
  * @since 4.0
  */
-@Immutable
 public class URIUtils {
 
      /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URLEncodedUtils.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URLEncodedUtils.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URLEncodedUtils.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/client/utils/URLEncodedUtils.java Sat Nov 19 16:40:54 2016
@@ -46,7 +46,6 @@ import org.apache.http.Header;
 import org.apache.http.HeaderElement;
 import org.apache.http.HttpEntity;
 import org.apache.http.NameValuePair;
-import org.apache.http.annotation.Immutable;
 import org.apache.http.entity.ContentType;
 import org.apache.http.message.BasicNameValuePair;
 import org.apache.http.message.ParserCursor;
@@ -60,7 +59,6 @@ import org.apache.http.util.CharArrayBuf
  *
  * @since 4.0
  */
-@Immutable
 public class URLEncodedUtils {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectTimeoutException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectTimeoutException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectTimeoutException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectTimeoutException.java Sat Nov 19 16:40:54 2016
@@ -33,7 +33,6 @@ import java.net.InetAddress;
 import java.util.Arrays;
 
 import org.apache.http.HttpHost;
-import org.apache.http.annotation.Immutable;
 
 /**
  * A timeout while connecting to an HTTP server or waiting for an
@@ -42,7 +41,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class ConnectTimeoutException extends InterruptedIOException {
 
     private static final long serialVersionUID = -4816682903149535989L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectionPoolTimeoutException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectionPoolTimeoutException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectionPoolTimeoutException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/ConnectionPoolTimeoutException.java Sat Nov 19 16:40:54 2016
@@ -27,8 +27,6 @@
 
 package org.apache.http.conn;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * A timeout while waiting for an available connection
  * from a connection manager.
@@ -36,7 +34,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class ConnectionPoolTimeoutException extends ConnectTimeoutException {
 
     private static final long serialVersionUID = -7898874842020245128L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/EofSensorInputStream.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/EofSensorInputStream.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/EofSensorInputStream.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/EofSensorInputStream.java Sat Nov 19 16:40:54 2016
@@ -29,7 +29,6 @@ package org.apache.http.conn;
 import java.io.IOException;
 import java.io.InputStream;
 
-import org.apache.http.annotation.NotThreadSafe;
 import org.apache.http.util.Args;
 
 /**
@@ -43,7 +42,6 @@ import org.apache.http.util.Args;
  */
 // don't use FilterInputStream as the base class, we'd have to
 // override markSupported(), mark(), and reset() to disable them
-@NotThreadSafe
 public class EofSensorInputStream extends InputStream implements ConnectionReleaseTrigger {
 
     /**

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/HttpHostConnectException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/HttpHostConnectException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/HttpHostConnectException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/HttpHostConnectException.java Sat Nov 19 16:40:54 2016
@@ -32,7 +32,6 @@ import java.net.InetAddress;
 import java.util.Arrays;
 
 import org.apache.http.HttpHost;
-import org.apache.http.annotation.Immutable;
 
 /**
  * A {@link ConnectException} that specifies the {@link HttpHost} that was
@@ -40,7 +39,6 @@ import org.apache.http.annotation.Immuta
  *
  * @since 4.0
  */
-@Immutable
 public class HttpHostConnectException extends ConnectException {
 
     private static final long serialVersionUID = -3194482710275220224L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/UnsupportedSchemeException.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/UnsupportedSchemeException.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/UnsupportedSchemeException.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/UnsupportedSchemeException.java Sat Nov 19 16:40:54 2016
@@ -29,14 +29,11 @@ package org.apache.http.conn;
 
 import java.io.IOException;
 
-import org.apache.http.annotation.Immutable;
-
 /**
  * Signals failure to establish connection using an unknown protocol scheme.
  *
  * @since 4.3
  */
-@Immutable
 public class UnsupportedSchemeException extends IOException {
 
     private static final long serialVersionUID = 3597127619218687636L;

Modified: httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java?rev=1770506&r1=1770505&r2=1770506&view=diff
==============================================================================
--- httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java (original)
+++ httpcomponents/httpclient/branches/4.5.x/httpclient/src/main/java/org/apache/http/conn/routing/BasicRouteDirector.java Sat Nov 19 16:40:54 2016
@@ -27,7 +27,8 @@
 
 package org.apache.http.conn.routing;
 
-import org.apache.http.annotation.Immutable;
+import org.apache.http.annotation.Contract;
+import org.apache.http.annotation.ThreadingBehavior;
 import org.apache.http.util.Args;
 
 /**
@@ -35,7 +36,7 @@ import org.apache.http.util.Args;
  *
  * @since 4.0
  */
-@Immutable
+@Contract(threading = ThreadingBehavior.IMMUTABLE)
 public class BasicRouteDirector implements HttpRouteDirector {
 
     /**




Mime
View raw message