/** * A Flex application can declare default channels for its services. If a * service specifies its own list of channels it overrides these defaults. * <p> * <default-channels><br/> * <channel ref="channel-id"/><br/> * <default-channels> * </p> * * @param chan the channel node */ private void defaultChannel(Node chan) { String ref = getAttributeOrChildElement(chan, REF_ATTR); if (ref.length() > 0) { ChannelSettings channel = config.getChannelSettings(ref); if (channel != null) { config.addDefaultChannel(channel.getId()); } else { // {0} not found for reference '{1}' ConfigurationException e = new ConfigurationException(); e.setMessage(REF_NOT_FOUND, new Object[]{CHANNEL_ELEMENT, ref}); throw e; } } else { //A default channel was specified without a reference for service '{0}'. ConfigurationException ex = new ConfigurationException(); ex.setMessage(INVALID_DEFAULT_CHANNEL, new Object[]{"MessageBroker"}); throw ex; } }
if (config.getDefaultChannels().size() > 0) for (Iterator chanIter = config.getDefaultChannels().iterator(); chanIter.hasNext();) ClusterSettings defaultCluster = config.getDefaultCluster(); defaultCluster = null; for (Iterator servIter = config.getAllServiceSettings().iterator(); servIter.hasNext();) ClusterSettings clusterSettings = config.getClusterSettings(clusterId); if (clusterSettings != null && clusterSettings.getURLLoadBalancing()) for (Iterator chanIter = config.getAllChannelSettings().values().iterator(); chanIter.hasNext();)
if (isValidID(id)) ServiceSettings serviceSettings = config.getServiceSettings(id); if (serviceSettings == null) serviceSettings.addProperties(map); config.addServiceSettings(serviceSettings); else if (config.getDefaultChannels().size() > 0) for (Iterator iter = config.getDefaultChannels().iterator(); iter.hasNext();) ChannelSettings channel = config.getChannelSettings(channelId); serviceSettings.addDefaultChannel(channel);
if (config.getChannelSettings(id) != null) channelSettings.setUri(uri); config.addChannelSettings(id, channelSettings);
ChannelSettings channel = config.getChannelSettings(ref); if (channel != null) if (ref.length() > 0) ChannelSettings channel = config.getChannelSettings(ref); if (channel != null)
private static List listChannelClasses(ServicesConfiguration config) { List channelList = new ArrayList(); Iterator it = config.getAllChannelSettings().values().iterator(); while (it.hasNext()) { ChannelSettings settings = (ChannelSettings)it.next(); String clientType = settings.getClientType(); channelList.add(clientType); } return channelList; }
if (isValidID(id)) ServiceSettings serviceSettings = config.getServiceSettings(id); if (serviceSettings == null) serviceSettings.addProperties(map); config.addServiceSettings(serviceSettings); else if (config.getDefaultChannels().size() > 0) for (Iterator iter = config.getDefaultChannels().iterator(); iter.hasNext();) ChannelSettings channel = config.getChannelSettings(channelId); serviceSettings.addDefaultChannel(channel);
if (config.getChannelSettings(id) != null) channelSettings.setUri(uri); config.addChannelSettings(id, channelSettings);
ChannelSettings channel = config.getChannelSettings(ref); if (channel != null) if (ref.length() > 0) ChannelSettings channel = config.getChannelSettings(ref); if (channel != null)
private static List listChannelClasses(ServicesConfiguration config) { List channelList = new ArrayList(); Iterator it = config.getAllChannelSettings().values().iterator(); while (it.hasNext()) { ChannelSettings settings = (ChannelSettings)it.next(); if (!settings.serverOnly) { String clientType = settings.getClientType(); channelList.add(clientType); } } return channelList; }
if (isValidID(id)) ServiceSettings serviceSettings = config.getServiceSettings(id); if (serviceSettings == null) serviceSettings.addProperties(map); config.addServiceSettings(serviceSettings); else if (config.getDefaultChannels().size() > 0) for (Iterator iter = config.getDefaultChannels().iterator(); iter.hasNext();) ChannelSettings channel = config.getChannelSettings(channelId); serviceSettings.addDefaultChannel(channel);
if (config.getDefaultChannels().size() > 0) for (Iterator chanIter = config.getDefaultChannels().iterator(); chanIter.hasNext();) ClusterSettings defaultCluster = config.getDefaultCluster(); defaultCluster = null; for (Iterator servIter = config.getAllServiceSettings().iterator(); servIter.hasNext();) ClusterSettings clusterSettings = config.getClusterSettings(clusterId); if (clusterSettings != null && clusterSettings.getURLLoadBalancing()) for (Iterator chanIter = config.getAllChannelSettings().values().iterator(); chanIter.hasNext();)
ChannelSettings channel = config.getChannelSettings(ref); if (channel != null) config.addDefaultChannel(channel.getId());
if (config.getChannelSettings(id) != null) channelSettings.setUri(uri); config.addChannelSettings(id, channelSettings);
ChannelSettings channel = config.getChannelSettings(ref); if (channel != null)
private static List listChannelClasses(ServicesConfiguration config) { List channelList = new ArrayList(); Iterator it = config.getAllChannelSettings().values().iterator(); while (it.hasNext()) { ChannelSettings settings = (ChannelSettings)it.next(); if (!settings.serverOnly) { String clientType = settings.getClientType(); channelList.add(clientType); } } return channelList; }
if (isValidID(id)) ServiceSettings serviceSettings = config.getServiceSettings(id); if (serviceSettings == null) config.addServiceSettings(serviceSettings); else if (config.getDefaultChannels().size() > 0) for (Iterator iter = config.getDefaultChannels().iterator(); iter.hasNext();) ChannelSettings channel = config.getChannelSettings(channelId); serviceSettings.addDefaultChannel(channel);
if (config.getDefaultChannels().size() > 0) for (Iterator chanIter = config.getDefaultChannels().iterator(); chanIter.hasNext();) ClusterSettings defaultCluster = config.getDefaultCluster(); defaultCluster = null; for (Iterator servIter = config.getAllServiceSettings().iterator(); servIter.hasNext();) ClusterSettings clusterSettings = config.getClusterSettings(clusterId); if (clusterSettings != null && clusterSettings.getURLLoadBalancing()) for (Iterator chanIter = config.getAllChannelSettings().values().iterator(); chanIter.hasNext();)
/** * A Flex application can declare default channels for its services. If a * service specifies its own list of channels it overrides these defaults. * <p> * <default-channels><br/> * <channel ref="channel-id"/><br/> * <default-channels> * </p> * * @param chan the channel node */ private void defaultChannel(Node chan) { String ref = getAttributeOrChildElement(chan, REF_ATTR); if (ref.length() > 0) { ChannelSettings channel = config.getChannelSettings(ref); if (channel != null) { config.addDefaultChannel(channel.getId()); } else { // {0} not found for reference '{1}' ConfigurationException e = new ConfigurationException(); e.setMessage(REF_NOT_FOUND, new Object[]{CHANNEL_ELEMENT, ref}); throw e; } } else { //A default channel was specified without a reference for service '{0}'. ConfigurationException ex = new ConfigurationException(); ex.setMessage(INVALID_DEFAULT_CHANNEL, new Object[]{"MessageBroker"}); throw ex; } }
if (isValidID(id)) { if (config.getChannelSettings(id) != null) { channelSettings.setUri(uri); config.addChannelSettings(id, channelSettings);