Skip to content

Fix grpc async interceptors

Shivam Bairoliya requested to merge sbairoliya/fix_async_interceptors into master

Before raising this MR, consider whether the following are required, and complete if so:

  • Unit tests
  • Metrics
  • Documentation update(s)

If not required, please explain in brief why not.

Description

GRPC interceptors for sync and async behave differently. Have a look at https://github.com/grpc/grpc/issues/31442

Changes proposed in this merge request:

  • First commit updates the auth token loader class to be in the channel class instead of the auth interceptor base. This allows the sharing of the state
  • Second commit changes the logic for how interceptors are created in buildgrid

Validation

Ran the test from this file. Before the change the bytestream read request fails

Test file for https://gitlab.com/BuildGrid/buildgrid/-/merge_requests/1032 ($3688705) · Snippets · Snippets · GitLab

After the request the bytessream read request passes

Edited by Shivam Bairoliya

Merge request reports