Skip to content

Commit

Permalink
Merge branch 'Issue-#26723-feat-support-tls-for-redis-datasource' of …
Browse files Browse the repository at this point in the history
…github.com:AnnaHariprasad5123/appsmith into chore/external-contribution-37106
  • Loading branch information
NilanshBansal committed Nov 19, 2024
2 parents 6c4ee8a + 6da9385 commit 5eb3b2e
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,12 @@ public static URI getURI(DatasourceConfiguration datasourceConfiguration) throws
&& datasourceConfiguration.getTlsConfiguration() != null
&& datasourceConfiguration.getTlsConfiguration().getTlsEnabled()) {
builder.append(REDIS_SSL_SCHEME);
Endpoint endpoint = datasourceConfiguration.getEndpoints().get(0);
if (endpoint.getPort() != null && endpoint.getPort() == DEFAULT_PORT) {
log.warn("Using default non-TLS port {} with TLS enabled", DEFAULT_PORT);
if (datasourceConfiguration.getEndpoints() != null
&& !datasourceConfiguration.getEndpoints().isEmpty()) {
Endpoint endpoint = datasourceConfiguration.getEndpoints().get(0);
if (endpoint.getPort() != null && endpoint.getPort() == DEFAULT_PORT) {
log.warn("Using default non-TLS port {} with TLS enabled", DEFAULT_PORT);
}
}
} else {
builder.append(REDIS_SCHEME);
Expand Down

0 comments on commit 5eb3b2e

Please sign in to comment.