[ARTMIS-1431] Adapt transport configuration in ClientProtocolManagerFactory
add the adaptTransportConfiguration() method to the ClientProtocolManagerFactory so that transport configurations used by the ClientProtocolManager have an opportunity to adapt their transport configuration. This allows the HornetQClientProtocolManagerFactory to adapt the transport configuration received by remote HornetQ broker to replace the HornetQ-based NettyConnectorFactory by the Artemis-based one. JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1431
This commit is contained in:
parent
c85575f435
commit
6febd5e314
|
@ -65,7 +65,11 @@ public class XARecoveryConfig {
|
|||
final ClientProtocolManagerFactory clientProtocolManager) {
|
||||
TransportConfiguration[] newTransportConfiguration = new TransportConfiguration[transportConfiguration.length];
|
||||
for (int i = 0; i < transportConfiguration.length; i++) {
|
||||
if (clientProtocolManager != null) {
|
||||
newTransportConfiguration[i] = clientProtocolManager.adaptTransportConfiguration(transportConfiguration[i].newTransportConfig(""));
|
||||
} else {
|
||||
newTransportConfiguration[i] = transportConfiguration[i].newTransportConfig("");
|
||||
}
|
||||
}
|
||||
|
||||
this.transportConfiguration = newTransportConfiguration;
|
||||
|
|
Loading…
Reference in New Issue