private static void updateAcceptorsAndConnectors(Configuration backupConfiguration, int portOffset, List<String> remoteConnectors, boolean fullServer) { //we only do this if we are a full server, if scale down then our acceptors wont be needed and our connectors will // be the same as the parent server if (fullServer) { Set<TransportConfiguration> acceptors = backupConfiguration.getAcceptorConfigurations(); for (TransportConfiguration acceptor : acceptors) { updatebackupParams(backupConfiguration.getName(), portOffset, acceptor.getParams()); } Map<String, TransportConfiguration> connectorConfigurations = backupConfiguration.getConnectorConfigurations(); for (Map.Entry<String, TransportConfiguration> entry : connectorConfigurations.entrySet()) { //check to make sure we aren't a remote connector as this shouldn't be changed if (!remoteConnectors.contains(entry.getValue().getName())) { updatebackupParams(backupConfiguration.getName(), portOffset, entry.getValue().getParams()); } } } else { //if we are scaling down then we wont need any acceptors but clear anyway for belts and braces backupConfiguration.getAcceptorConfigurations().clear(); } }