@Test public void testNotStartedWithServices() { discoveryClient.addDiscoveredService(APPLE_1_SERVICE); discoveryClient.addDiscoveredService(APPLE_2_SERVICE); discoveryClient.addDiscoveredService(DIFFERENT_TYPE); discoveryClient.addDiscoveredService(DIFFERENT_POOL); assertEquals(serviceSelector.selectAllServices(), ImmutableList.of()); }
@Override public List<ServiceDescriptor> selectAllServices() { return this.serviceDescriptors.get(); }
CachingServiceSelector implements ServiceSelector, ServiceDescriptorsListener { @Override public List<ServiceDescriptor> selectAllServices() { return this.serviceDescriptors.get(); } }
CachingServiceSelector implements ServiceSelector, ServiceDescriptorsListener { @Override public List<ServiceDescriptor> selectAllServices() { return this.serviceDescriptors.get(); } CachingServiceSelector(String type, ServiceSelectorConfig selectorConfig, NodeInfo nodeInfo); }
CachingServiceSelector implements ServiceSelector, ServiceDescriptorsListener { @Override public List<ServiceDescriptor> selectAllServices() { return this.serviceDescriptors.get(); } CachingServiceSelector(String type, ServiceSelectorConfig selectorConfig, NodeInfo nodeInfo); @Override String getType(); @Override String getPool(); @Override List<ServiceDescriptor> selectAllServices(); @Override void updateServiceDescriptors(Iterable<ServiceDescriptor> newDescriptors); }
CachingServiceSelector implements ServiceSelector, ServiceDescriptorsListener { @Override public List<ServiceDescriptor> selectAllServices() { return this.serviceDescriptors.get(); } CachingServiceSelector(String type, ServiceSelectorConfig selectorConfig, NodeInfo nodeInfo); @Override String getType(); @Override String getPool(); @Override List<ServiceDescriptor> selectAllServices(); @Override void updateServiceDescriptors(Iterable<ServiceDescriptor> newDescriptors);  }