Skip to content
This repository was archived by the owner on Dec 23, 2023. It is now read-only.
This repository was archived by the owner on Dec 23, 2023. It is now read-only.

opencensus 0.28.1 breaks gRPC #2069

Description

@ejona86

0.28.1 hides io.opencensus.trace.unsafe.ContextUtils which is used directly by gRPC. This was broken by #2059. It seems ContextUtils should be marked deprecated for the moment, instead of hidden entirely. This breakage is especially surprising given the change was in a point release.

Migrating to ContextHandleUtils will need to take some careful thought, as there are multiple ways it would break with the current gRPC integration. Even if we fix this today in gRPC, it'd still be a month before the next release. In addition, a flag-day change like this requires upgrading an entire application all-at-once and so may prevent people from upgrading grpc and getting on the new opencensus APIs; keeping the old class available allows upgrading a piece at a time without breaking the world.

CC @zoercai

grpc-java/census/src/main/java/io/grpc/census/CensusTracingModule.java:42: error: ContextUtils is not public in io.opencensus.trace.unsafe; cannot be accessed from outside package
import io.opencensus.trace.unsafe.ContextUtils;
                                 ^
grpc-java/census/src/main/java/io/grpc/census/CensusTracingModule.java:344: error: ContextUtils is not public in io.opencensus.trace.unsafe; cannot be accessed from outside package
      return ContextUtils.withValue(context, span);
             ^
grpc-java/census/src/main/java/io/grpc/census/CensusTracingModule.java:385: error: ContextUtils is not public in io.opencensus.trace.unsafe; cannot be accessed from outside package
          newClientCallTracer(ContextUtils.getValue(Context.current()), method);
                              ^

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions