You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ManagedChannelImpl@8e4bb0] Created with target language.googleapis.com:443 Exception in thread "main" java.lang.NoSuchMethodError #587
//Instanciate a client
LanguageServiceClient language = LanguageServiceClient.create();
//Text to analyze
String text = "Hello world";
Document doc = Document.newBuilder().setContent(text).setType(Type.PLAIN_TEXT).build();
//Detect the sentiment
Sentiment sentiment = language.analyzeSentiment(doc).getDocumentSentiment();
System.out.printf("Text: %s%n", text);
System.out.printf("Sentiment: %s, %s%n", sentiment.getScore(), sentiment.getMagnitude());
When I execute the code, I obtain an error:
log4j:WARN No appenders could be found for logger (io.netty.util.internal.logging.InternalLoggerFactory).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
mars 29, 2017 12:26:59 PM io.grpc.internal.ManagedChannelImpl <init>
INFOS: [ManagedChannelImpl@8e4bb0] Created with target language.googleapis.com:443
Exception in thread "main" java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.directExecutor()Ljava/util/concurrent/Executor;
at io.grpc.internal.ClientCallImpl.<init>(ClientCallImpl.java:103)
at io.grpc.internal.ManagedChannelImpl$RealChannel.newCall(ManagedChannelImpl.java:556)
at io.grpc.auth.ClientAuthInterceptor.interceptCall(ClientAuthInterceptor.java:82)
at io.grpc.ClientInterceptors$InterceptorChannel.newCall(ClientInterceptors.java:120)
at com.google.api.gax.grpc.HeaderInterceptor.interceptCall(HeaderInterceptor.java:57)
at io.grpc.ClientInterceptors$InterceptorChannel.newCall(ClientInterceptors.java:120)
at io.grpc.internal.ManagedChannelImpl.newCall(ManagedChannelImpl.java:535)
at com.google.api.gax.grpc.DescriptorClientCallFactory.newCall(DescriptorClientCallFactory.java:54)
at com.google.api.gax.grpc.DirectCallable.futureCall(DirectCallable.java:60)
at com.google.api.gax.grpc.ExceptionTransformingCallable.futureCall(ExceptionTransformingCallable.java:62)
at com.google.api.gax.grpc.RetryingCallable$RetryingResultFuture.issueCall(RetryingCallable.java:216)
at com.google.api.gax.grpc.RetryingCallable.futureCall(RetryingCallable.java:84)
at com.google.api.gax.grpc.UnaryCallable.futureCall(UnaryCallable.java:243)
at com.google.api.gax.grpc.UnaryCallable.futureCall(UnaryCallable.java:254)
at com.google.api.gax.grpc.UnaryCallable.call(UnaryCallable.java:282)
at com.google.cloud.language.spi.v1.LanguageServiceClient.analyzeSentiment(LanguageServiceClient.java:213)
at com.google.cloud.language.spi.v1.LanguageServiceClient.analyzeSentiment(LanguageServiceClient.java:190)
at com.atchikrealtime.product.moderation.google.test.GoogleTest.myNaturalLanguageTest(GoogleTest.java:402)
at com.atchikrealtime.product.moderation.google.test.GoogleTest.main(GoogleTest.java:259)
Activity
lesv commentedon Apr 22, 2017
@scraly Is this still an issue for you?
nnegrey commentedon Dec 7, 2018
Hi,
It looks like there wasn't a followup for this issue. If this is still an issue please feel free to reopen it and we'll be happy to help!
Thanks! :)
chore(deps): update dependency com.google.cloud:google-cloud-mediatra…
chore(deps): update dependency com.google.cloud:libraries-bom to v22 (#…
chore(deps): update dependency com.google.cloud:google-cloud-mediatra…
chore(deps): update dependency com.google.cloud:libraries-bom to v22 (#…
chore(deps): update dependency com.google.cloud:libraries-bom to v24.…
deps: update dependency com.google.guava:guava to v31 (#587)
deps: update dependency com.google.guava:guava to v31 (#587)
chore(deps): update dependency com.google.cloud:libraries-bom to v24 (#…