Conversation
Signed-off-by: Valery Piashchynski <[email protected]>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #130 +/- ##
==========================================
+ Coverage 97.96% 98.67% +0.70%
==========================================
Files 5 6 +1
Lines 295 377 +82
==========================================
+ Hits 289 372 +83
+ Misses 6 5 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
🟡 Changes recommended
Resolve the critical build, cleanup, and unbounded reconciliation issues before approval.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Adds deferred service.Update support for partial configuration changes while active processes continue running.
Changes:
- Adds runtime updates with environment replacement and process-count reconciliation.
- Refactors process-group and lifecycle management.
- Adds unit/integration coverage and dependency updates.
File summaries
| File | Reviewed changes | Final findings |
|---|---|---|
update_test.go |
Update tests | — |
tests/update_test.go |
Integration and concurrency tests | Critical (1 vote): new(tt.target) does not compile at lines 572 and 582. |
tests/mock/observer.go |
Structured log capture | Moderate (1 vote): Returned attribute maps alias stored records; deep-copy them on reads. |
tests/helpers/rpc.go |
Update RPC helper | — |
tests/go.sum |
Test dependency checksums | — |
tests/go.mod |
Test dependency updates | — |
rpc.go |
Update and lifecycle RPCs | — |
rpc_test.go |
RPC lifecycle tests | — |
process.go |
Process snapshots and shutdown handling | Critical (1 vote): stop can dereference a nil command for an unstarted process. |
process_test.go |
Process cleanup tests | — |
plugin.go |
Plugin lifecycle integration | — |
plugin_test.go |
Plugin lifecycle tests | — |
group.go |
Deferred updates and process reconciliation | Critical (1 vote): math.MaxInt can trigger unbounded worker/timer reconciliation and resource exhaustion. |
go.work.sum |
Workspace checksums | — |
go.sum |
Dependency checksums | — |
go.mod |
API dependency updates | — |
config.go |
Configuration cloning and validation | — |
Review details
Suppressed comments (2)
tests/mock/observer.go:23
Allonly clones the slice, so each returnedAttrsmap still aliases the stored record;FilterMessageandFilterMessageSnippetreturn the same aliases. A caller that mutates an attribute can change historical records and race withHandle, contradicting the “Attribute maps are immutable” contract; deep-copy the maps on every read or remove that claim.
// All returns the captured records. Attribute maps are immutable.
func (o *ObservedLogs) All() []LoggedEntry {
o.mu.RLock()
defer o.mu.RUnlock()
return slices.Clone(o.logs)
tests/update_test.go:582
new(tt.target)cannot compile becausenewaccepts a type, not a value. This prevents the test package from building; take the address of theint64field instead (for example,&tt.target).
helpers.Update(t, client, &serviceV1.Update{Name: "update", ProcessNum: new(tt.target)})
- Files reviewed: 15/17 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Signed-off-by: Valery Piashchynski <[email protected]>
Signed-off-by: Valery Piashchynski <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add
service.Updatefor partial configuration changes while current processes continue running.api-go/v6 v6.0.0-beta.15and align startup and shutdown with Endure.closes: roadrunner-server/roadrunner#2119
API: roadrunner-server/api#80.
Docs: roadrunner-server/docs#80.