Fix gRPC messages too long by dropping at 1MiB on all fields
What does this MR do and why?
gRPC messages are generally enforced to be limited at 4MiB. This limit is not consistently enforced by all servers but it seems to be enforced in Cloudflare per gitlab-org/gitlab#509586 (comment 2676948545). We had previously also enforced this in the Go client code in this library but our enforcement was only limiting 1 field of the message at 4MiB. But we need to ensure the entire message is smaller than 4MiB. This was especially problematic as our ActionResponse messages embed the same large text twice due to backwards compatibility.
Therefore this MR fixes 2 problem:
- Reduce the field limit to 1MiB to be more confident that the whole message fits within the 4MiB limit
- Apply this field limit to all the long response fields. The legacy response as well as the specific response body fields for normal results and HTTP responses
We also have an open issue in gitlab-org/gitlab#560498 (closed) to apply a similar fix to our node executor.
Related issues
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
| Before | After |
|---|---|
How to set up and validate locally
Closes #77 (closed)