For IntelliJ IDEA,
Android Studio or Eclipse



/** * <p>createNettyChannel.</p> * * @param host a {@link String} object. * @param options a {@link BigtableOptions} object. * @return a {@link ManagedChannel} object. * @throws SSLException if any. */ public static ManagedChannel createNettyChannel(String host, BigtableOptions options, ClientInterceptor ... interceptors) throws SSLException { // Ideally, this should be ManagedChannelBuilder.forAddress(...) rather than an explicit // call to NettyChannelBuilder. Unfortunately, that doesn't work for shaded artifacts. ManagedChannelBuilder<?> builder = ManagedChannelBuilder .forAddress(host, options.getPort()); if (options.usePlaintextNegotiation()) { builder.usePlaintext(true); } return builder .idleTimeout(Long.MAX_VALUE, TimeUnit.SECONDS) .maxInboundMessageSize(MAX_MESSAGE_SIZE) .userAgent(BigtableVersionInfo.CORE_UESR_AGENT + "," + options.getUserAgent()) .intercept(interceptors) .build(); }