mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
[ACS-5805] Split configuration for Transform and Shared File Store (#2142)
* [ACS-5805] Split configuration for Transform and Shared File Store and create common switch for MTLS. * [ACS-5805] Add explicit error logging.
This commit is contained in:
@@ -44,6 +44,7 @@ import org.apache.http.StatusLine;
|
||||
import org.apache.http.client.methods.CloseableHttpResponse;
|
||||
import org.apache.http.client.methods.HttpGet;
|
||||
import org.apache.http.client.methods.HttpPost;
|
||||
import org.apache.http.conn.ConnectTimeoutException;
|
||||
import org.apache.http.entity.ContentType;
|
||||
import org.apache.http.entity.mime.MultipartEntityBuilder;
|
||||
import org.apache.http.impl.client.CloseableHttpClient;
|
||||
@@ -198,6 +199,7 @@ public class RemoteTransformerClient
|
||||
// In the case of transform requests, unlike version checks, it is only the failure to connect that
|
||||
// forces a wait before trying again.
|
||||
connectionFailed();
|
||||
logHttpClientTimeoutException(e, logger);
|
||||
throw new AlfrescoRuntimeException(name + " failed to connect or to read the response", e);
|
||||
}
|
||||
}
|
||||
@@ -216,6 +218,14 @@ public class RemoteTransformerClient
|
||||
}
|
||||
}
|
||||
|
||||
private void logHttpClientTimeoutException(IOException e, Log logger)
|
||||
{
|
||||
if (e instanceof ConnectTimeoutException)
|
||||
{
|
||||
logger.error(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Indicates if a remote transform:
|
||||
* a) ready probe has ever indicated success {@code new Pair<>(true, <version string>)},
|
||||
|
@@ -750,8 +750,11 @@ encryption.ssl.truststore.type=JCEKS
|
||||
encryption.ssl.truststore.keyMetaData.location=
|
||||
|
||||
## HttpClient config for Transform Service
|
||||
#Transform Service and Shared File Store should have common switch for MTLS.
|
||||
httpclient.config.transformServices.mTLSEnabled=false
|
||||
|
||||
#enable mtls in HttpClientFactory for Transform Service.
|
||||
httpclient.config.transform.mTLSEnabled=false
|
||||
httpclient.config.transform.mTLSEnabled=${httpclient.config.transformServices.mTLSEnabled}
|
||||
httpclient.config.transform.maxTotalConnections=20
|
||||
httpclient.config.transform.maxHostConnections=20
|
||||
|
||||
|
Reference in New Issue
Block a user