2017-05-29 2 views
0

Ich führte die Vision-API für den Text-Extrakt aus einem Bild, beim Ausführen des Beispielcodes ist es fehlerhafter mit ihm unter Fehler Stack.Vision API Fehler unter Angabe von 'com.google.api.gax.grpc.ApiException: io.grpc.StatusRuntimeException: DEADLINE_EXCEEDED'

28. Mai 2017 10.46.48 io.grpc.internal.ManagedChannelImpl INFO: [ManagedChannelImpl @ 543788f3] Erstellt mit Ziel vision.googleapis.com:443 com.google.api.gax. grpc.ApiException: io.grpc.StatusRuntimeException: DEADLINE_EXCEEDED End bei com.google.api.gax.grpc.ExceptionTransformingCallable $ ExceptionTransformingFuture.onFailure (ExceptionTransformingCallable.java:109) bei com.google.api.gax.core.ApiFutures $ 1.onFailure (ApiFutures.java:52) bei com.google.common.util.concurrent.Futures $ 6.run (Futures.java:1764) bei com.google.common.util.concurrent.MoreExcutors $ DirectExecutor.execute (MehrExecu tors.java:456) bei com.google.common.util.concurrent.AbstractFuture.executeListener (AbstractFuture.java:817) bei com.google.common.util.concurrent.AbstractFuture.complete (AbstractFuture.java:753) bei com.google.common.util.concurrent.AbstractFuture.setException (AbstractFuture.java:634) bei io.grpc.stub.ClientCalls $ GrpcFuture.setException (ClientCalls.java:466) bei io.grpc.stub. ClientCalls $ UnaryStreamToFuture.onClose (ClientCalls.java:442) bei io.grpc.internal.ClientCallImpl $ ClientStreamListenerImpl.close (ClientCallImpl.java:481) bei io.grpc.internal.ClientCallImpl $ ClientStreamListenerImpl.access $ 600 (ClientCallImpl.java : 398) bei io.grpc.internal.ClientCallImpl $ ClientStreamListenerImpl $ 1StreamClosed.runInContext (ClientCallImpl.java:513) bei i.grpc.internal.ContextRunnable.run (ContextRunnable.java:52) bei io.grpc.internal.SerializingExecutor $ TaskRunner.run (SerializingExecutor.java:154) bei java.util.concurrent.Executors $ RunnableAdapter. Anruf (Executors.java:511) bei java.util.concurrent.FutureTask.run (FutureTask.java:266) bei java.util.concurrent.ScheduledThreadPoolExecutor $ ScheduledFutureTask.access $ 201 (ScheduledThreadPoolExecutor.java:180) auf Java .util.concurrent.ScheduledThreadPoolExecutor $ ScheduledFutureTask.run (ScheduledThreadPoolExecutor.java:293) bei java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1142) bei java.util.concurrent.ThreadPoolExecutor $ Worker.run (ThreadPoolExecutor .java: 617) bei java.lang.Threa d.run (Thread.java:745) Verursacht durch: io.grpc.StatusRuntimeException: DEADLINE_EXCEEDED bei io.grpc.Status.asRuntimeException (Status.java:545) ... 13 weitere

I führe den Code von Eclipse in meinem lokalen System aus.

Ich habe versucht, die folgenden Elemente wie in einigen Foren gefunden; 1) Alle Netty * -Geräte von 4.1.6 auf 4.1.3 wurden herabgestuft. 2) Google-Cloud-Vision-0.10.0-Beta.jar wurde auf google-cloud-vision-0.9.4-beta.jar herabgestuft), um die pom.xml 4) Hinzufügen von GOOGLE_APPLICATION_CREDENTIALS in Windows-Umgebungsvariable Hinzufügen - wies auf die JSON-Datei für den Service Account heruntergeladen

+0

Wie lange ist die Frist konfiguriert? –

+0

Hallo Carl, ich bin neu bei GCP.Ich habe versucht, die Konfiguration herauszufinden, war aber nicht erfolgreich. Kannst du mir helfen, wo ich die Konfiguration finde? –

Antwort

0

Versuchen Sie, Termin beim Erstellen Stub

blockingStub = SomeGrpc 
    .newBlockingStub(channel) 
    .withDeadlineAfter(5, TimeUnit.SECONDS); 

und sehen, ob das hilft

Verwandte Themen