There are two python gRPC services A and B.
Service A needs to call a rpc on service B in order to send a response to the client.
Service A also has an interceptor that adds information to gRPC contexts it uses.
Question:
How can I pass the gRPC context to service B so I can access those information on gRPC contexts in service B?
Since you are changing the python object itself, it is not currently possible to pass it in the gRPC call. although you can do this manually by setting your metadata using
send_initial_metadatamethod of your context and writing a new interceptor in serviceBto parse this information stored ininvocation_metadataand setting it in the context of your second service.