@Test public void testConfigLoading() { String[] expectedChannelConfigNames = new String[] { DEFAULT_HOST_PORT_CFG, DEFAULT_HOST_CFG, DEFAULT_PORT_CFG, DEFAULT_HOST_SSL_ONE_WAY_CFG, DEFAULT_PORT_SSL_CFG, DEFAULT_HOST_PORT_SSL_DISABLED_CFG }; assertThat(grpcConfig.channels().size(), equalTo(expectedChannelConfigNames.length + 2)); assertThat(grpcConfig.channels().keySet(), hasItems(expectedChannelConfigNames)); assertThat(grpcConfig.channels().keySet(), hasItems(GrpcChannelsProvider.DEFAULT_CHANNEL_NAME)); }
Map<String, GrpcChannelDescriptor> channels() { return channelConfigs; }
GrpcChannelsProvider { Map<String, GrpcChannelDescriptor> channels() { return channelConfigs; } }
GrpcChannelsProvider { Map<String, GrpcChannelDescriptor> channels() { return channelConfigs; } private  GrpcChannelsProvider(Map<String, GrpcChannelDescriptor> channelDescriptors); }
GrpcChannelsProvider { Map<String, GrpcChannelDescriptor> channels() { return channelConfigs; } private  GrpcChannelsProvider(Map<String, GrpcChannelDescriptor> channelDescriptors); static GrpcChannelsProvider create(); static GrpcChannelsProvider create(Config config); static GrpcChannelsProvider.Builder builder(); static GrpcChannelsProvider.Builder builder(Config config); ManagedChannel channel(String name); }
GrpcChannelsProvider { Map<String, GrpcChannelDescriptor> channels() { return channelConfigs; } private  GrpcChannelsProvider(Map<String, GrpcChannelDescriptor> channelDescriptors); static GrpcChannelsProvider create(); static GrpcChannelsProvider create(Config config); static GrpcChannelsProvider.Builder builder(); static GrpcChannelsProvider.Builder builder(Config config); ManagedChannel channel(String name); static final String DEFAULT_CHANNEL_NAME; static final String DEFAULT_HOST; static final String CFG_KEY_CHANNELS; static final int DEFAULT_PORT; }