Skip to content

Randomly getting io.grpc.StatusException: INTERNAL on all requests #262

Open
@outofdate

Description

@outofdate

Hey.
I wanted to migrate to grpc-kotlin from kroto+(great lib, but as i see it is not updating), so i recently updated all libraries to the last versions(grpc libs to 1.38.0, grpc-kotlin to 1.1.0). Everything goes smooth, except i often randomly get an Exception io.grpc.StatusException: INTERNAL. Can't find source of it and had to think that something is configured wrong in our project, related to coroutines.

After some digging i changed CoroutineStub to BlockingStub and all works perfectly fine.

2021-05-19 13:25:01.133 E/BasePresenter$onError: io.grpc.StatusException: INTERNAL
        at io.grpc.Status.asException(Status.java:551)
        at io.grpc.kotlin.ClientCalls$rpcImpl$1$1$1.onClose(ClientCalls.kt:295)
        at io.grpc.internal.ClientCallImpl.closeObserver(ClientCallImpl.java:553)
        at io.grpc.internal.ClientCallImpl.access$300(ClientCallImpl.java:68)
        at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInternal(ClientCallImpl.java:739)
        at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInContext(ClientCallImpl.java:718)
        at io.grpc.internal.ContextRunnable.run(ContextRunnable.java:37)
        at io.grpc.internal.SerializingExecutor.run(SerializingExecutor.java:123)
        at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:98)
        at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
        at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
        at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
        at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

We use grpc on Android.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions