You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2024/02/10 13:18:09 UTC

(httpcomponents-client) branch master updated (2e46b62ff -> 661589e38)

This is an automated email from the ASF dual-hosted git repository.

olegk pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/httpcomponents-client.git


    from 2e46b62ff HTTPCLIENT-2151: Support for JSSE in-built endpoint identification
     new 5b411692a Correct logger name
     new 661589e38 Removed unused private fields and local variables

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../java/org/apache/hc/client5/http/cache/ResponseCacheControl.java  | 1 -
 .../java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java | 1 -
 .../hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java       | 2 --
 .../apache/hc/client5/http/impl/classic/ContentCompressionExec.java  | 5 -----
 .../apache/hc/client5/http/impl/classic/LinearBackoffManager.java    | 3 +--
 .../org/apache/hc/client5/http/protocol/RequestValidateTrace.java    | 4 ----
 6 files changed, 1 insertion(+), 15 deletions(-)


(httpcomponents-client) 02/02: Removed unused private fields and local variables

Posted by ol...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

olegk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/httpcomponents-client.git

commit 661589e386e204fbdba1fbd7dac4f90ca5222c7f
Author: Michael Lee <jk...@users.noreply.github.com>
AuthorDate: Fri Feb 9 22:39:58 2024 +0800

    Removed unused private fields and local variables
---
 .../java/org/apache/hc/client5/http/cache/ResponseCacheControl.java  | 1 -
 .../java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java | 1 -
 .../hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java       | 2 --
 .../apache/hc/client5/http/impl/classic/ContentCompressionExec.java  | 5 -----
 .../org/apache/hc/client5/http/protocol/RequestValidateTrace.java    | 4 ----
 5 files changed, 13 deletions(-)

diff --git a/httpclient5-cache/src/main/java/org/apache/hc/client5/http/cache/ResponseCacheControl.java b/httpclient5-cache/src/main/java/org/apache/hc/client5/http/cache/ResponseCacheControl.java
index 7e7f4b01f..57eafacb2 100644
--- a/httpclient5-cache/src/main/java/org/apache/hc/client5/http/cache/ResponseCacheControl.java
+++ b/httpclient5-cache/src/main/java/org/apache/hc/client5/http/cache/ResponseCacheControl.java
@@ -357,7 +357,6 @@ public final class ResponseCacheControl implements CacheControl {
         private long staleIfError = -1;
         private Set<String> noCacheFields;
         private boolean mustUnderstand;
-        private boolean noTransform;
         private boolean immutable;
 
         Builder() {
diff --git a/httpclient5-cache/src/main/java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java b/httpclient5-cache/src/main/java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java
index ffd9b261d..7dad9bcf9 100644
--- a/httpclient5-cache/src/main/java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java
+++ b/httpclient5-cache/src/main/java/org/apache/hc/client5/http/impl/cache/AsyncCachingExec.java
@@ -1265,7 +1265,6 @@ class AsyncCachingExec extends CachingExecBase implements AsyncExecChainHandler
             public AsyncDataConsumer handleResponse(
                     final HttpResponse backendResponse,
                     final EntityDetails entityDetails) throws HttpException, IOException {
-                final HttpClientContext context = scope.clientContext;
                 final Instant responseDate = getCurrentDate();
                 final AsyncExecCallback callback;
                 if (backendResponse.getCode() != HttpStatus.SC_NOT_MODIFIED) {
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java
index 42b1a3327..8ebe34f53 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/InternalH2AsyncExecRuntime.java
@@ -40,7 +40,6 @@ import org.apache.hc.client5.http.protocol.HttpClientContext;
 import org.apache.hc.core5.concurrent.Cancellable;
 import org.apache.hc.core5.concurrent.ComplexCancellable;
 import org.apache.hc.core5.concurrent.FutureCallback;
-import org.apache.hc.core5.http.HttpHost;
 import org.apache.hc.core5.http.HttpVersion;
 import org.apache.hc.core5.http.nio.AsyncClientExchangeHandler;
 import org.apache.hc.core5.http.nio.AsyncPushConsumer;
@@ -88,7 +87,6 @@ class InternalH2AsyncExecRuntime implements AsyncExecRuntime {
             final HttpClientContext context,
             final FutureCallback<AsyncExecRuntime> callback) {
         if (sessionRef.get() == null) {
-            final HttpHost target = route.getTargetHost();
             final RequestConfig requestConfig = context.getRequestConfig();
             @SuppressWarnings("deprecation")
             final Timeout connectTimeout = requestConfig.getConnectTimeout();
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ContentCompressionExec.java b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ContentCompressionExec.java
index 8bcdc3abe..0ffe820ce 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ContentCompressionExec.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ContentCompressionExec.java
@@ -78,11 +78,6 @@ public final class ContentCompressionExec implements ExecChainHandler {
     private final Lookup<InputStreamFactory> decoderRegistry;
     private final boolean ignoreUnknown;
 
-    /**
-     * An empty immutable {@code String} array.
-     */
-    private static final String[] EMPTY_STRING_ARRAY = {};
-
     public ContentCompressionExec(
             final List<String> acceptEncoding,
             final Lookup<InputStreamFactory> decoderRegistry,
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/protocol/RequestValidateTrace.java b/httpclient5/src/main/java/org/apache/hc/client5/http/protocol/RequestValidateTrace.java
index 9f7e381ea..e7dfeb1ca 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/protocol/RequestValidateTrace.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/protocol/RequestValidateTrace.java
@@ -41,8 +41,6 @@ import org.apache.hc.core5.http.Method;
 import org.apache.hc.core5.http.ProtocolException;
 import org.apache.hc.core5.http.protocol.HttpContext;
 import org.apache.hc.core5.util.Args;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 
 /**
  * <h1>RequestTraceInterceptor</h1>
@@ -102,8 +100,6 @@ import org.slf4j.LoggerFactory;
 @Contract(threading = ThreadingBehavior.STATELESS)
 public class RequestValidateTrace implements HttpRequestInterceptor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(RequestValidateTrace.class);
-
     /**
      * Singleton instance of {@link RequestValidateTrace}.
      */


(httpcomponents-client) 01/02: Correct logger name

Posted by ol...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

olegk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/httpcomponents-client.git

commit 5b411692a78796a3d5198e722728cef3c4e92bac
Author: Michael Lee <jk...@users.noreply.github.com>
AuthorDate: Fri Feb 9 22:39:01 2024 +0800

    Correct logger name
---
 .../org/apache/hc/client5/http/impl/classic/LinearBackoffManager.java  | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/LinearBackoffManager.java b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/LinearBackoffManager.java
index fa7d52711..2128a6aa3 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/LinearBackoffManager.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/LinearBackoffManager.java
@@ -68,8 +68,7 @@ import java.util.concurrent.atomic.AtomicInteger;
 @Contract(threading = ThreadingBehavior.SAFE)
 public class LinearBackoffManager extends AbstractBackoff {
 
-
-    private static final Logger LOG = LoggerFactory.getLogger(org.slf4j.LoggerFactory.class);
+    private static final Logger LOG = LoggerFactory.getLogger(LinearBackoffManager.class);
 
     /**
      * The backoff increment used when adjusting connection pool sizes.