Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

feat/gitserver: don't log memoryObservation error if it occured due to context cancellation#63209

Closed
ggilmore wants to merge 2 commits into
graphite-base/63209from
06-11-feat_gitserver_don_t_log_memoryobservation_error_if_it_occured_due_to_context_cancellation
Closed

feat/gitserver: don't log memoryObservation error if it occured due to context cancellation#63209
ggilmore wants to merge 2 commits into
graphite-base/63209from
06-11-feat_gitserver_don_t_log_memoryobservation_error_if_it_occured_due_to_context_cancellation

Conversation

@ggilmore

@ggilmore ggilmore commented Jun 11, 2024

Copy link
Copy Markdown
Contributor

This PR changes the behavior of the git cli commands to ignore errors from the memory observer if they occurred due to cancellation. Such errors are expected if the user cancels the request, and so there is no reason to generate logspam.

Test plan

Existing CI tests

This PR only reduces logspam, and as such doesn't need extensive new unit tests.

Changelog

  • Reduce logspam in the gitserver command functionality by ignoring memory observation errors if they occurred due to external context cancellation.

@cla-bot cla-bot Bot added the cla-signed label Jun 11, 2024
@github-actions github-actions Bot added team/product-platform team/source Tickets under the purview of Source - the one Source to graph it all labels Jun 11, 2024

Copy link
Copy Markdown
Contributor Author

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @ggilmore and the rest of your teammates on Graphite Graphite

@ggilmore ggilmore changed the base branch from 06-11-feat_internal_memcmd_ignore_context_cancellation_errors_from_stop_ to graphite-base/63209 June 11, 2024 19:23
…63208)

This PR tweaks the memory observer implementation to ignore context
cancellation if they only occurred if we explicitly called Stop (which
calls the context's cancellation function). This helps to reduce
logspam.


## Test plan

Unit tests


## Changelog

- Slightly improve logspam from Linux memory observation logic by
ignoring context cancellation errors that occur when the user explicitly
stopped the observer.
@ggilmore ggilmore requested a review from eseliger June 11, 2024 19:23
@ggilmore ggilmore force-pushed the 06-11-feat_gitserver_don_t_log_memoryobservation_error_if_it_occured_due_to_context_cancellation branch from 27a1b34 to 3deae9a Compare June 11, 2024 19:24
@ggilmore ggilmore requested a review from a team June 11, 2024 19:24
@ggilmore ggilmore deleted the branch graphite-base/63209 June 11, 2024 19:24
@ggilmore ggilmore closed this Jun 11, 2024
@ggilmore ggilmore marked this pull request as ready for review June 11, 2024 19:24
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla-signed team/product-platform team/source Tickets under the purview of Source - the one Source to graph it all

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant