java.lang.IllegalArgumentException: Jetty ALPN/NPN has not been properly configured. when trying to use PubSub
See original GitHub issueHi,
I am trying to use the google cloud libraries to connect to PubSub but I am getting the following exception when trying to execute the following code:
projectID = "XYZ";
subscriptionID = "ABC/XYZ";
subscriptionName = SubscriptionName.create(projectID, subscriptionID);
subscriber = Subscriber.defaultBuilder(subscriptionName, new MessageReceiverEx()).build();
subscriber.startAsync().awaitRunning();
Caused by: java.lang.IllegalStateException: Expected the service InnerService [FAILED] to be RUNNING, but the service has FAILED
at com.google.common.util.concurrent.AbstractService.checkCurrentState(AbstractService.java:328)
at com.google.common.util.concurrent.AbstractService.awaitRunning(AbstractService.java:266)
at com.google.api.core.AbstractApiService.awaitRunning(AbstractApiService.java:97)
at ...
Caused by: java.lang.IllegalArgumentException: Jetty ALPN/NPN has not been properly configured.
at io.grpc.netty.GrpcSslContexts.selectApplicationProtocolConfig(GrpcSslContexts.java:174)
at io.grpc.netty.GrpcSslContexts.configure(GrpcSslContexts.java:151)
at io.grpc.netty.GrpcSslContexts.configure(GrpcSslContexts.java:139)
at io.grpc.netty.GrpcSslContexts.forClient(GrpcSslContexts.java:109)
at io.grpc.netty.NettyChannelBuilder$NettyTransportFactory.<init>(NettyChannelBuilder.java:470)
at io.grpc.netty.NettyChannelBuilder.buildTransportFactory(NettyChannelBuilder.java:338)
at io.grpc.internal.AbstractManagedChannelImplBuilder.build(AbstractManagedChannelImplBuilder.java:305)
at com.google.api.gax.grpc.InstantiatingChannelProvider.createChannel(InstantiatingChannelProvider.java:125)
at com.google.api.gax.grpc.InstantiatingChannelProvider.getChannel(InstantiatingChannelProvider.java:110)
at com.google.cloud.pubsub.v1.Subscriber.doStart(Subscriber.java:239)
at com.google.api.core.AbstractApiService$InnerService.doStart(AbstractApiService.java:149)
at com.google.common.util.concurrent.AbstractService.startAsync(AbstractService.java:211)
at com.google.api.core.AbstractApiService.startAsync(AbstractApiService.java:121)
at com.google.cloud.pubsub.v1.Subscriber.startAsync(Subscriber.java:228)
The last line in my code (subscriber.startAsync().awaitRunning();
) is the position where the upper exception origines from.
Am I using something wrong or is this a bug?
I am using compile group: 'com.google.cloud', name: 'google-cloud-pubsub', version:'0.22.0-beta'
as gradle dependency.
Issue Analytics
- State:
- Created 6 years ago
- Comments:27 (3 by maintainers)
Top Results From Across the Web
Jetty ALPN/NPN has not been properly configured
Just started trying to use Google Cloud PubSub for the first time with my GAE (Standard) app. When trying to create a topic...
Read more >Different Netty Versions in dependencies of flink-runtime make ...
Caused by: java.lang.IllegalArgumentException: Jetty ALPN/NPN has not been properly configured. at io.grpc.netty.GrpcSslContexts.
Read more >Event Hub Service - General Electric
The Event Hub publish-subscribe service is built to be secure, highly scalable, ... java.lang.IllegalArgumentException: Jetty ALPN/NPN has not been properly.
Read more >Jetty ALPN/NPN has not been properly configured-Springboot
Coding example for the question java.lang.IllegalArgumentException: Jetty ALPN/NPN has not been properly configured-Springboot.
Read more >Authentication
Version Independence: does not require using a different library version depending ... is not configured properly” or “Jetty ALPN/NPN has not been properly...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
What system are you using? I had similar problem but because of alpine linux
Google libs bring in: netty-tcnative-boringssl-static 1.1.33.Fork26 which is incompatible with the 2.x.x of netty-tcnative
I’ll ask the client library team if they can shade or upgrade this stuff.