Skip to content

Commit 13d5fc2

Browse files
committed
Polishing.
Consistent constant naming.
1 parent c3c21b6 commit 13d5fc2

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

spring-vault-core/src/main/java/org/springframework/vault/client/ClientHttpConnectorFactory.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,13 @@
6565
*/
6666
public class ClientHttpConnectorFactory {
6767

68-
private static final boolean REACTOR_NETTY_PRESENT = ClassUtils.isPresent("reactor.netty.http.client.HttpClient",
68+
private static final boolean reactorNettyPresent = ClassUtils.isPresent("reactor.netty.http.client.HttpClient",
6969
ClientHttpConnectorFactory.class.getClassLoader());
7070

71-
private static final boolean HTTP_COMPONENTS_PRESENT = ClassUtils.isPresent("org.apache.hc.client5.http.impl.async",
71+
private static final boolean httpComponentsPresent = ClassUtils.isPresent("org.apache.hc.client5.http.impl.async",
7272
ClientHttpConnectorFactory.class.getClassLoader());
7373

74-
private static final boolean JETTY_PRESENT = ClassUtils.isPresent("org.eclipse.jetty.client.HttpClient",
74+
private static final boolean jettyPresent = ClassUtils.isPresent("org.eclipse.jetty.client.HttpClient",
7575
ClientHttpConnectorFactory.class.getClassLoader());
7676

7777
/**
@@ -87,16 +87,16 @@ public static ClientHttpConnector create(ClientOptions options, SslConfiguration
8787
Assert.notNull(sslConfiguration, "SslConfiguration must not be null");
8888

8989
try {
90-
if (REACTOR_NETTY_PRESENT) {
90+
if (reactorNettyPresent) {
9191
return ReactorNetty.usingReactorNetty(options, sslConfiguration);
9292
}
9393

94-
if (HTTP_COMPONENTS_PRESENT) {
94+
if (httpComponentsPresent) {
9595
return HttpComponents.usingHttpComponents(options, sslConfiguration);
9696

9797
}
9898

99-
if (JETTY_PRESENT) {
99+
if (jettyPresent) {
100100
return JettyClient.usingJetty(options, sslConfiguration);
101101
}
102102

spring-vault-core/src/main/java/org/springframework/vault/client/ClientHttpRequestFactoryFactory.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,11 +89,11 @@ public class ClientHttpRequestFactoryFactory {
8989
@SuppressWarnings("FieldMayBeFinal") // allow setting via reflection.
9090
private static Log logger = LogFactory.getLog(ClientHttpRequestFactoryFactory.class);
9191

92-
private static final boolean HTTP_COMPONENTS_PRESENT = ClassUtils.isPresent(
92+
private static final boolean httpComponentsPresent = ClassUtils.isPresent(
9393
"org.apache.hc.client5.http.impl.classic.HttpClientBuilder",
9494
ClientHttpRequestFactoryFactory.class.getClassLoader());
9595

96-
private static final boolean OKHTTP3_PRESENT = ClassUtils.isPresent("okhttp3.OkHttpClient",
96+
private static final boolean okHttp3Present = ClassUtils.isPresent("okhttp3.OkHttpClient",
9797
ClientHttpRequestFactoryFactory.class.getClassLoader());
9898

9999
/**
@@ -111,11 +111,11 @@ public static ClientHttpRequestFactory create(ClientOptions options, SslConfigur
111111

112112
try {
113113

114-
if (HTTP_COMPONENTS_PRESENT) {
114+
if (httpComponentsPresent) {
115115
return HttpComponents.usingHttpComponents(options, sslConfiguration);
116116
}
117117

118-
if (OKHTTP3_PRESENT) {
118+
if (okHttp3Present) {
119119
return OkHttp3.usingOkHttp3(options, sslConfiguration);
120120
}
121121
}

0 commit comments

Comments
 (0)