return replaceProperties(jgroupsCfg, props, TCP);
}
private static String replaceProperties(
JGroupsProtocolCfg cfg, Map<String, String> newProps, ProtocolType type) {
ProtocolConfiguration protocol = cfg.getProtocol(type);
ProtocolConfiguration newProtocol =
new ProtocolConfiguration(protocol.getProtocolName(), newProps);
cfg.replaceProtocol(type, newProtocol);
return cfg.toString();
}