Skip to content

Error while running Instrumented tests on Android project  #9254

@felipezad

Description

@felipezad

What version of gRPC-Java are you using?

1.46.0

What is your environment?

Android
JDK11
Gradle 7+

What did you expect to see?

Able to run instrumented tests.

What did you see instead?

receiver class io.grpc.netty.nettyserverbuilder does not define or inherit an implementation of the resolved method 'abstract io.grpc.serverbuilder delegate()' of abstract class io.grpc.internal.abstractserverimplbuilder.

Steps to reproduce the bug

After updating from

Gradle 4.+ to Gradle 7.+
JDK 8 to JDK 11+

Whenever I run the instrumented test the GRPC libraries started to pop up with this exception

receiver class io.grpc.netty.nettyserverbuilder does not define or inherit an implementation of the resolved method 'abstract io.grpc.serverbuilder delegate()' of abstract class io.grpc.internal.abstractserverimplbuilder.

At the moment I'm rolling back the Gradle version and JDK and it works fine.


I tried the following approaches:

  1. Update GRPC Libraries (to the latest or the one that works) https://github.com/grpc/grpc-java

  2. Use the GRPC-all Library

  3. Add the grpc-netty library, however, the documentation says that okhttp should be used.

  4. Receiver class io.grpc.netty.shaded.io.grpc.netty.NettyClientTransport does not define or inherit an implementation of the resolved method 'abstract io.grpc.internal.ClientStream newStream(io.grpc.MethodDescriptor, io.grpc.Metadata, io.grpc.CallOptions, io.grpc.ClientStreamTracer[])' of interface io.grpc.internal.ClientTransport googleapis/java-pubsub#903

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions