BUG 2245 - Fixed Constant Name 50/12250/2
authorMarian Adamjak <marian.adamjak@pantheon.sk>
Mon, 27 Oct 2014 09:33:24 +0000 (10:33 +0100)
committerMarian Adamjak <marian.adamjak@pantheon.sk>
Mon, 27 Oct 2014 13:23:57 +0000 (14:23 +0100)
Change-Id: I2401601e84f1255212cad3b09f4eaba65df430e9
Signed-off-by: Marian Adamjak <marian.adamjak@pantheon.sk>
openflow-protocol-impl/src/main/java/org/opendaylight/openflowjava/protocol/impl/core/SslTrustManagerFactory.java
simple-client/src/main/java/org/opendaylight/openflowjava/protocol/impl/clients/ClientSslKeyStore.java
simple-client/src/main/java/org/opendaylight/openflowjava/protocol/impl/clients/ClientSslTrustStore.java

index 69f2db68d4c57b94a1c6a49ec50a35862da35070..6890234cd49055219077b2836c8b27697dfdb9ce 100644 (file)
@@ -28,7 +28,7 @@ public class SslTrustManagerFactory extends TrustManagerFactorySpi {
     /**
      * Logger for SslTrustManagerFactory
      */
-    public static final Logger logger = LoggerFactory.getLogger(SslTrustManagerFactory.class);
+    public static final Logger LOGGER = LoggerFactory.getLogger(SslTrustManagerFactory.class);
     private static final TrustManager DUMMY_TRUST_MANAGER = new X509TrustManager() {
         @Override
         public X509Certificate[] getAcceptedIssuers() {
@@ -37,12 +37,12 @@ public class SslTrustManagerFactory extends TrustManagerFactorySpi {
 
         @Override
         public void checkClientTrusted(X509Certificate[] chain, String authType) {
-            logger.error("UNKNOWN CLIENT CERTIFICATE: " + chain[0].getSubjectDN());
+            LOGGER.error("UNKNOWN CLIENT CERTIFICATE: " + chain[0].getSubjectDN());
         }
 
         @Override
         public void checkServerTrusted(X509Certificate[] chain, String authType) {
-            logger.error("UNKNOWN SERVER CERTIFICATE: " + chain[0].getSubjectDN());
+            LOGGER.error("UNKNOWN SERVER CERTIFICATE: " + chain[0].getSubjectDN());
         }
     };
 
index 233b1c1148c7750848dd366dde1ec4d36fa11265..e3e6069770523291cce6f027b33de2b1cba8e634 100644 (file)
@@ -17,7 +17,7 @@ import java.io.InputStream;
  */
 public final class ClientSslKeyStore {
 
-    private static final String filename = "/selfSignedSwitch";
+    private static final String KEY_STORE_FILENAME = "/selfSignedSwitch";
 
     private ClientSslKeyStore() {
         throw new UnsupportedOperationException("Utility class shouldn't be instantiated");
@@ -29,9 +29,9 @@ public final class ClientSslKeyStore {
      * @return key as InputStream
      */
     public static InputStream asInputStream() {
-        InputStream in = ClientSslKeyStore.class.getResourceAsStream(filename);
+        InputStream in = ClientSslKeyStore.class.getResourceAsStream(KEY_STORE_FILENAME);
         if (in == null) {
-            throw new IllegalStateException("KeyStore file not found: " + filename);
+            throw new IllegalStateException("KeyStore file not found: " + KEY_STORE_FILENAME);
         }
         return in;
     }
index c346ba1e1df9f04f232819f0c9f1b02d389205b5..5f7929f686366a4c19d366e972f21abe4127d373 100644 (file)
@@ -17,7 +17,7 @@ import java.io.InputStream;
  */
 public final class ClientSslTrustStore {
 
-    private static final String filename = "/selfSignedController";
+    private static final String KEY_STORE_FILENAME = "/selfSignedController";
 
     private ClientSslTrustStore() {
         throw new UnsupportedOperationException("Utility class shouldn't be instantiated");
@@ -29,9 +29,9 @@ public final class ClientSslTrustStore {
      * @return key as InputStream
      */
     public static InputStream asInputStream() {
-        InputStream in = ClientSslTrustStore.class.getResourceAsStream(filename);
+        InputStream in = ClientSslTrustStore.class.getResourceAsStream(KEY_STORE_FILENAME);
         if (in == null) {
-            throw new IllegalStateException("KeyStore file not found: " + filename);
+            throw new IllegalStateException("KeyStore file not found: " + KEY_STORE_FILENAME);
         }
         return in;
     }