GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||
GeezerVison is showing github.com — fix(worker): keep a worker isolate alive while a __runOnMainThread callback locks it by adrian-niculescu · Pull Request #2068 · NativeScript/android Conversation
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (4)
Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthroughCallbackHandlers tracks active main-thread callbacks by isolate and provides a wait method. BackgroundLooper waits for callbacks after destroying the worker runtime and before disposing its isolate. Worker callback exception handling releases its JavaScript handle before rethrowing. ChangesWorker callback lifecycle
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~15 minutes Change: Bug fix Sequence Diagram(s)sequenceDiagram
participant BackgroundLooper
participant Runtime
participant CallbackHandlers
participant MainThreadCallback
participant Isolate
BackgroundLooper->>Runtime: DestroyRuntime()
Runtime->>CallbackHandlers: RemoveIsolateEntries()
BackgroundLooper->>CallbackHandlers: WaitForMainThreadCallbacks(isolate)
MainThreadCallback->>CallbackHandlers: RunMainThreadEntry()
CallbackHandlers->>Isolate: Hold isolate while callback runs
CallbackHandlers-->>CallbackHandlers: Release hold after isolate locker
CallbackHandlers-->>BackgroundLooper: Return when no holds remain
BackgroundLooper->>Isolate: Dispose()
Suggested reviewers: Merge Risk: ⚪ Minimal · up to No merge-blocking issue is established; the worker callback shutdown change is ready for normal merge checks. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. A rabbit counts each callback’s stay Comment |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…s isolate handle The exception a worker's callback threw kept a handle into the worker isolate after RunMainThreadEntry let go of it, so the isolate could be disposed before the event loop reported it, and the report resolved the handle against the main thread's isolate. For a worker's callback the exception now drops the handle while the isolate is still held, and only its message and stack reach Java.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.