Java Code Examples for org.wildfly.swarm.topology.Topology#asMap()
The following examples show how to use
org.wildfly.swarm.topology.Topology#asMap() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TopologyProxyService.java From thorntail with Apache License 2.0 | 5 votes |
@Override public void onChange(Topology topology) { Map<String, List<Topology.Entry>> topologyMap = topology.asMap(); for (String serviceName : serviceNames) { if (topologyMap.containsKey(serviceName)) { updateProxyHosts(serviceName, topologyMap.get(serviceName)); } else { // All instances of this service went away updateProxyHosts(serviceName, Collections.emptyList()); } } }
Example 2
Source File: App.java From drools-workshop with Apache License 2.0 | 4 votes |
public static void printTopology(Topology lookup) { Map<String, List<Topology.Entry>> asMap = lookup.asMap(); for (String key : asMap.keySet()) { System.out.println("Key: " + key + " - Value: " + asMap.get(key)); } }
Example 3
Source File: App.java From drools-workshop with Apache License 2.0 | 4 votes |
public static void printTopology(Topology lookup){ Map<String, List<Topology.Entry>> asMap = lookup.asMap(); for(String key : asMap.keySet()){ System.out.println("Key: "+ key + " - Value: "+asMap.get(key)); } }
Example 4
Source File: App.java From drools-workshop with Apache License 2.0 | 4 votes |
public static void printTopology(Topology lookup){ Map<String, List<Topology.Entry>> asMap = lookup.asMap(); for(String key : asMap.keySet()){ System.out.println("Key: "+ key + " - Value: "+asMap.get(key)); } }