DescriptionMake service protocol respect isolate lifecycle
Status:
- Currently the getIsolate API tries to guess the status of the isolate
when it is in between the IsolateRunnable and PauseStart, by reporting
it as already in the PauseStart status.
This can potentially make flaky all the tests that uses PauseStart to
synchronize with the actual status of the Isolate.
- In the previous situation the timestamp of the event is guessed too,
potentially reporting a wrong value.
- Even with the previous fix the is still a race condition that can lead
to a getIsolate responde with a PauseStart status to be sent before
the actual PauseStart event.
Changes:
- Fallback to None pause event if the isolate is in between
IsolateRunnable and PauseStart, avoiding double posting.
- Send the PauseStart event before the actual status change, partially
avoiding the race conditions.
- Set the pause timestamp before the actual status change, fully
avoiding the race condition.
Closes https://github.com/dart-lang/sdk/issues/28624
R=asiva@google.com, rmacnak@google.com
Committed: https://github.com/dart-lang/sdk/commit/5534568ff1f3d598b61c40f46a477e32a39bdea0
Patch Set 1 #
Total comments: 4
Patch Set 2 : Added documentation #
Total comments: 1
Patch Set 3 : Make test more understandable #Patch Set 4 : Merged with upstream #
Messages
Total messages: 11 (4 generated)
|