Skip to content

Commit

Permalink
Add new error codes to the apache-httpclient5 client module.
Browse files Browse the repository at this point in the history
  • Loading branch information
iyt-trifork committed Nov 27, 2024
1 parent 394d9de commit fdf2814
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public void bufferEntity() throws IOException {
try {
myEntityBytes = IOUtils.toByteArray(respEntity);
} catch (IllegalStateException exception) {
throw new InternalErrorException(Msg.code(2447) + exception);
throw new InternalErrorException(Msg.code(2580) + exception);
}
myEntityBuffered = true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public void bufferEntity() throws IOException {
try {
this.myEntityBytes = IOUtils.toByteArray(respEntity);
} catch (IllegalStateException e) {
throw new InternalErrorException(Msg.code(1478) + e);
throw new InternalErrorException(Msg.code(2581) + e);
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public static SSLContext createSslContext(@Nonnull TlsAuthentication theTlsAuthe

return contextBuilder.build();
} catch (Exception e) {
throw new TlsAuthenticationException(Msg.code(2102) + "Failed to create SSLContext", e);
throw new TlsAuthenticationException(Msg.code(2575) + "Failed to create SSLContext", e);
}
}

Expand All @@ -98,13 +98,13 @@ public static KeyStore createKeyStore(BaseStoreInfo theStoreInfo) {
}
return keyStore;
} catch (Exception e) {
throw new TlsAuthenticationException(Msg.code(2103) + "Failed to create KeyStore", e);
throw new TlsAuthenticationException(Msg.code(2576) + "Failed to create KeyStore", e);
}
}

public static void validateKeyStoreExists(InputStream theInputStream) {
if (theInputStream == null) {
throw new TlsAuthenticationException(Msg.code(2116) + "Keystore does not exists");
throw new TlsAuthenticationException(Msg.code(2577) + "Keystore does not exists");
}
}

Expand All @@ -124,9 +124,9 @@ public static X509TrustManager createTrustManager(Optional<TrustStoreInfo> theTr
return (X509TrustManager) trustManager;
}
}
throw new TlsAuthenticationException(Msg.code(2104) + "Could not find X509TrustManager");
throw new TlsAuthenticationException(Msg.code(2578) + "Could not find X509TrustManager");
} catch (Exception e) {
throw new TlsAuthenticationException(Msg.code(2105) + "Failed to create X509TrustManager");
throw new TlsAuthenticationException(Msg.code(2579) + "Failed to create X509TrustManager");
}
}

Expand Down

0 comments on commit fdf2814

Please sign in to comment.