Skip to content
This repository has been archived by the owner on Nov 1, 2023. It is now read-only.

Reduce mutation in the agent state machine #2710

Merged
merged 9 commits into from
Dec 21, 2022
Merged

Conversation

chkeita
Copy link
Contributor

@chkeita chkeita commented Dec 16, 2022

Summary of the Pull Request

Removing the shared mutable state (&mut self) from the agent state machine. The intent is to make the code easier to reason with.

@codecov-commenter
Copy link

codecov-commenter commented Dec 16, 2022

Codecov Report

Merging #2710 (11587bb) into main (3a5101b) will decrease coverage by 0.00%.
The diff coverage is 32.96%.

@@            Coverage Diff             @@
##             main    #2710      +/-   ##
==========================================
- Coverage   28.55%   28.55%   -0.01%     
==========================================
  Files         320      320              
  Lines       38050    38108      +58     
==========================================
+ Hits        10866    10881      +15     
- Misses      27184    27227      +43     
Impacted Files Coverage Δ
src/agent/onefuzz-agent/src/commands.rs 0.00% <0.00%> (ø)
src/agent/onefuzz-agent/src/config.rs 0.00% <0.00%> (ø)
src/agent/onefuzz-agent/src/coordinator.rs 5.26% <0.00%> (-0.38%) ⬇️
src/agent/onefuzz-agent/src/debug.rs 0.00% <0.00%> (ø)
src/agent/onefuzz-agent/src/main.rs 0.42% <0.00%> (ø)
src/agent/onefuzz-agent/src/reboot.rs 0.00% <0.00%> (ø)
src/agent/onefuzz-agent/src/setup.rs 0.00% <0.00%> (ø)
src/agent/onefuzz-agent/src/work.rs 10.85% <0.00%> (-0.44%) ⬇️
src/agent/onefuzz-agent/src/worker.rs 57.94% <0.00%> (ø)
src/agent/onefuzz-agent/src/reboot/double.rs 5.00% <6.66%> (-3.34%) ⬇️
... and 8 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@chkeita chkeita changed the title reduce unnecessary mutation in the agent Reduce mutation in the agent state machine Dec 19, 2022
@chkeita chkeita marked this pull request as ready for review December 19, 2022 18:22
@chkeita chkeita enabled auto-merge (squash) December 21, 2022 19:08
@chkeita chkeita merged commit 4dbc9c0 into microsoft:main Dec 21, 2022
@AdamL-Microsoft AdamL-Microsoft mentioned this pull request Jan 5, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants