You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by GitBox <gi...@apache.org> on 2020/03/06 07:56:53 UTC

[GitHub] [hadoop] aajisaka commented on a change in pull request #1880: HADOOP-16661. Support TLS 1.3

aajisaka commented on a change in pull request #1880: HADOOP-16661. Support TLS 1.3
URL: https://github.com/apache/hadoop/pull/1880#discussion_r388757429
 
 

 ##########
 File path: hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/http/TestSSLHttpServer.java
 ##########
 @@ -291,13 +294,30 @@ public void testExcludedCiphers() throws Exception {
   @Test
   public void testIncludedProtocols() throws Exception {
     URL url = new URL(baseUrl, SERVLET_PATH_ECHO + "?a=b&c=d");
+
+    String includedProtocols;
+    String version = System.getProperty("java.version");
+    if (version.startsWith("1.")) { // JDK 8
+      includedProtocols = INCLUDED_PROTOCOLS;
+    } else { // JDK 11 and above
+      includedProtocols = INCLUDED_PROTOCOLS_JDK11;
+    }
 
 Review comment:
   We can use the utility method and don't have to parse the java.version string. This change can avoid test failure in Java 9 and 10 (corner case).
   ```suggestion
       if (Shell.isJavaVersionAtLeast(11) {
         includedProtocols = INCLUDED_PROTOCOLS_JDK11;
       } else {
         includedProtocols = INCLUDED_PROTOCOLS;
       }
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org