Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tetra/debug: Clone GetDebugResponse entries #3343

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

tpapagian
Copy link
Member

When running comand "tetra debug dump processcache", we get sometimes the following error:

Error: failed to get process dump debug info: rpc error: code = Internal desc = grpc: error while marshaling: marshaling tetragon.GetDebugResponse: size mismatch (see golang/protobuf#1609): calculated=1240, measured=1269

By checking the link provided in the error message, we can see that the most possible cause of the error is accidental sharing and concurrent mutation of a Protobuf message or submessage.

To avoid that issue, this patch clones mutable submessages.

We managed to reproduce that in a server with heavy load. This patch seems to solve that issue.

@tpapagian tpapagian added the release-note/misc This PR makes changes that have no direct user impact. label Jan 28, 2025
@tpapagian tpapagian requested a review from a team as a code owner January 28, 2025 08:37
@tpapagian tpapagian requested a review from jrfastab January 28, 2025 08:37
@tpapagian tpapagian added needs-backport/1.2 This PR needs backporting to 1.2 needs-backport/1.3 This PR needs backporting to 1.3 labels Jan 28, 2025
When running command "tetra debug dump processcache", we get sometimes
the following error:

Error: failed to get process dump debug info: rpc error: code = Internal
desc = grpc: error while marshaling: marshaling tetragon.GetDebugResponse:
size mismatch (see golang/protobuf#1609): calculated=1240,
measured=1269

By checking the link provided in the error message, we can see that the
most possible cause of the error is accidental sharing and concurrent mutation
of a Protobuf message or submessage.

To avoid that issue, this patch clones mutable submessages.

We managed to reproduce that in a server with heavy load. This patch
seems to solve that issue.

Signed-off-by: Anastasios Papagiannis <anastasios.papagiannis@isovalent.com>
@tpapagian tpapagian force-pushed the pr/apapag/clone_debug_message branch from 5b510fa to 17ca292 Compare January 28, 2025 08:41
@tpapagian tpapagian merged commit b76687b into main Jan 28, 2025
39 checks passed
@tpapagian tpapagian deleted the pr/apapag/clone_debug_message branch January 28, 2025 09:42
@tpapagian tpapagian added backport-pending/1.2 The backport for this PR is in progress. backport-pending/1.3 The backport for this PR is in progress. backport-done/1.2 PR backport done. backport-done/1.3 PR backport done. and removed needs-backport/1.2 This PR needs backporting to 1.2 needs-backport/1.3 This PR needs backporting to 1.3 backport-pending/1.2 The backport for this PR is in progress. backport-pending/1.3 The backport for this PR is in progress. labels Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-done/1.2 PR backport done. backport-done/1.3 PR backport done. release-note/misc This PR makes changes that have no direct user impact.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants