You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by gg...@apache.org on 2023/01/11 16:26:34 UTC

[httpcomponents-client] branch master updated: Camel case names

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

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


The following commit(s) were added to refs/heads/master by this push:
     new 938a5d3fa Camel case names
     new 4fcb3b4ef Merge branch 'master' of https://gitbox.apache.org/repos/asf/httpcomponents-client.git
938a5d3fa is described below

commit 938a5d3fa3c59c08121908173912ca6336ad6615
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Wed Jan 11 11:26:08 2023 -0500

    Camel case names
---
 .../org/apache/hc/client5/testing/sync/TestSSLSocketFactory.java  | 8 ++++----
 .../apache/hc/client5/http/ssl/ConscryptClientTlsStrategy.java    | 8 ++++----
 .../org/apache/hc/client5/http/ssl/DefaultClientTlsStrategy.java  | 8 ++++----
 .../org/apache/hc/client5/http/examples/AsyncClientCustomSSL.java | 4 ++--
 .../org/apache/hc/client5/http/examples/ClientConfiguration.java  | 4 ++--
 .../java/org/apache/hc/client5/http/examples/ClientCustomSSL.java | 4 ++--
 6 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/httpclient5-testing/src/test/java/org/apache/hc/client5/testing/sync/TestSSLSocketFactory.java b/httpclient5-testing/src/test/java/org/apache/hc/client5/testing/sync/TestSSLSocketFactory.java
index 21954af3f..d0c0a3f13 100644
--- a/httpclient5-testing/src/test/java/org/apache/hc/client5/testing/sync/TestSSLSocketFactory.java
+++ b/httpclient5-testing/src/test/java/org/apache/hc/client5/testing/sync/TestSSLSocketFactory.java
@@ -229,9 +229,9 @@ public class TestSSLSocketFactory {
 
         final HttpContext context = new BasicHttpContext();
         // Use default SSL context
-        final SSLContext defaultsslcontext = SSLContexts.createDefault();
+        final SSLContext defaultSslContext = SSLContexts.createDefault();
 
-        final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(defaultsslcontext,
+        final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(defaultSslContext,
                 NoopHostnameVerifier.INSTANCE);
 
         try (final Socket socket = socketFactory.createSocket(context)) {
@@ -274,11 +274,11 @@ public class TestSSLSocketFactory {
         final HttpContext context = new BasicHttpContext();
 
         // @formatter:off
-        final SSLContext sslcontext = SSLContexts.custom()
+        final SSLContext sslContext = SSLContexts.custom()
             .loadTrustMaterial(null, trustStrategy)
             .build();
         // @formatter:on
-        final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(sslcontext,
+        final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(sslContext,
                 NoopHostnameVerifier.INSTANCE);
 
         try (final Socket socket = socketFactory.createSocket(context)) {
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/ConscryptClientTlsStrategy.java b/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/ConscryptClientTlsStrategy.java
index d3799d559..465a8f258 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/ConscryptClientTlsStrategy.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/ConscryptClientTlsStrategy.java
@@ -76,13 +76,13 @@ public class ConscryptClientTlsStrategy extends AbstractClientTlsStrategy {
     }
 
     public ConscryptClientTlsStrategy(
-            final SSLContext sslcontext,
+            final SSLContext sslContext,
             final HostnameVerifier hostnameVerifier) {
-        this(sslcontext, null, null, SSLBufferMode.STATIC, hostnameVerifier);
+        this(sslContext, null, null, SSLBufferMode.STATIC, hostnameVerifier);
     }
 
-    public ConscryptClientTlsStrategy(final SSLContext sslcontext) {
-        this(sslcontext, HttpsSupport.getDefaultHostnameVerifier());
+    public ConscryptClientTlsStrategy(final SSLContext sslContext) {
+        this(sslContext, HttpsSupport.getDefaultHostnameVerifier());
     }
 
     @Override
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/DefaultClientTlsStrategy.java b/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/DefaultClientTlsStrategy.java
index bad25e4ed..1267071a8 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/DefaultClientTlsStrategy.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/ssl/DefaultClientTlsStrategy.java
@@ -94,13 +94,13 @@ public class DefaultClientTlsStrategy extends AbstractClientTlsStrategy {
     }
 
     public DefaultClientTlsStrategy(
-            final SSLContext sslcontext,
+            final SSLContext sslContext,
             final HostnameVerifier hostnameVerifier) {
-        this(sslcontext, null, null, SSLBufferMode.STATIC, hostnameVerifier);
+        this(sslContext, null, null, SSLBufferMode.STATIC, hostnameVerifier);
     }
 
-    public DefaultClientTlsStrategy(final SSLContext sslcontext) {
-        this(sslcontext, HttpsSupport.getDefaultHostnameVerifier());
+    public DefaultClientTlsStrategy(final SSLContext sslContext) {
+        this(sslContext, HttpsSupport.getDefaultHostnameVerifier());
     }
 
     @Override
diff --git a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/AsyncClientCustomSSL.java b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/AsyncClientCustomSSL.java
index 12e28eb52..39cf958b4 100644
--- a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/AsyncClientCustomSSL.java
+++ b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/AsyncClientCustomSSL.java
@@ -58,14 +58,14 @@ public class AsyncClientCustomSSL {
 
     public static void main(final String[] args) throws Exception {
         // Trust standard CA and those trusted by our custom strategy
-        final SSLContext sslcontext = SSLContexts.custom()
+        final SSLContext sslContext = SSLContexts.custom()
                 .loadTrustMaterial((chain, authType) -> {
                     final X509Certificate cert = chain[0];
                     return "CN=httpbin.org".equalsIgnoreCase(cert.getSubjectDN().getName());
                 })
                 .build();
         final TlsStrategy tlsStrategy = ClientTlsStrategyBuilder.create()
-                .setSslContext(sslcontext)
+                .setSslContext(sslContext)
                 .build();
 
         final PoolingAsyncClientConnectionManager cm = PoolingAsyncClientConnectionManagerBuilder.create()
diff --git a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientConfiguration.java b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientConfiguration.java
index e0671f442..fd49162de 100644
--- a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientConfiguration.java
+++ b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientConfiguration.java
@@ -148,13 +148,13 @@ public class ClientConfiguration {
 
         // SSL context for secure connections can be created either based on
         // system or application specific properties.
-        final SSLContext sslcontext = SSLContexts.createSystemDefault();
+        final SSLContext sslContext = SSLContexts.createSystemDefault();
 
         // Create a registry of custom connection socket factories for supported
         // protocol schemes.
         final Registry<ConnectionSocketFactory> socketFactoryRegistry = RegistryBuilder.<ConnectionSocketFactory>create()
             .register("http", PlainConnectionSocketFactory.INSTANCE)
-            .register("https", new SSLConnectionSocketFactory(sslcontext))
+            .register("https", new SSLConnectionSocketFactory(sslContext))
             .build();
 
         // Use custom DNS resolver to override the system DNS resolution.
diff --git a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientCustomSSL.java b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientCustomSSL.java
index 18f6568e0..2e71a339b 100644
--- a/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientCustomSSL.java
+++ b/httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientCustomSSL.java
@@ -54,14 +54,14 @@ public class ClientCustomSSL {
 
     public final static void main(final String[] args) throws Exception {
         // Trust standard CA and those trusted by our custom strategy
-        final SSLContext sslcontext = SSLContexts.custom()
+        final SSLContext sslContext = SSLContexts.custom()
                 .loadTrustMaterial((chain, authType) -> {
                     final X509Certificate cert = chain[0];
                     return "CN=httpbin.org".equalsIgnoreCase(cert.getSubjectDN().getName());
                 })
                 .build();
         final SSLConnectionSocketFactory sslSocketFactory = SSLConnectionSocketFactoryBuilder.create()
-                .setSslContext(sslcontext)
+                .setSslContext(sslContext)
                 .build();
         // Allow TLSv1.3 protocol only
         final HttpClientConnectionManager cm = PoolingHttpClientConnectionManagerBuilder.create()