Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-12895

SSLFactory#createSSLSocketFactory exception message is wrong

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 2.0.2-alpha
    • 2.9.0, 3.0.0-alpha1
    • None
    • None

    Description

      If in SERVER model, the following code should throw exception indicating Factory is in SERVER mode, not in CLIENT mode. Otherwise, it could be confusing.

      SSLSocketFactory.java
      public SSLSocketFactory createSSLSocketFactory()
          throws GeneralSecurityException, IOException {
          if (mode != Mode.CLIENT) {
            throw new IllegalStateException("Factory is in CLIENT mode");
          }
          return context.getSocketFactory();
        }
      

      Attachments

        1. HADOOP-12895.001.patch
          0.8 kB
          Wei-Chiu Chuang
        2. HADOOP-12895.002.patch
          1 kB
          Wei-Chiu Chuang
        3. HADOOP-12895.003.patch
          2 kB
          Wei-Chiu Chuang

        Activity

          People

            weichiu Wei-Chiu Chuang
            weichiu Wei-Chiu Chuang
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: