Create JsRuntime#152
Merged
syntheticmagus merged 31 commits intoBabylonJS:masterfrom Feb 13, 2020
Merged
Conversation
…ing things into a more accurate semblance of the real architecture.
bghgary
requested changes
Feb 13, 2020
Contributor
bghgary
left a comment
There was a problem hiding this comment.
Mostly good. Some small issues.
Comment on lines
+12
to
+13
| arcana::task<std::string, std::exception_ptr> LoadUrlToStringAsync(const std::string url); | ||
| arcana::task<std::vector<uint8_t>, std::exception_ptr> LoadUrlToBytesAsync(const std::string url); |
Contributor
There was a problem hiding this comment.
nit: how about LoadTextAsync and LoadBinaryAsync for the function names?
| auto lock = AcquireTaskLock(); | ||
| auto whenAllTask = arcana::when_all(LoadUrlAsync<std::string>(GetAbsoluteUrl(url).data()), Task); | ||
| Task = whenAllTask.then(*m_dispatcher, m_cancelSource, [this, url](const std::tuple<std::string, arcana::void_placeholder>& args) { | ||
| std::scoped_lock lock{ m_taskMutex }; |
Contributor
There was a problem hiding this comment.
nit: spacing everywhere
Suggested change
| std::scoped_lock lock{ m_taskMutex }; | |
| std::scoped_lock lock{m_taskMutex}; |
Contributor
Author
There was a problem hiding this comment.
Did it, though I'm generally not a huge fan of more terse styles. Is there an established convention we're trying to align with on that?
Contributor
There was a problem hiding this comment.
LLVM default for clang format
bghgary
reviewed
Feb 13, 2020
bghgary
approved these changes
Feb 13, 2020
bghgary
added a commit
to bghgary/BabylonNative
that referenced
this pull request
Apr 13, 2026
Includes: - BabylonJS#147: Fix WorkQueue destructor deadlock - BabylonJS#149: Merge WorkQueue into AppRuntime - BabylonJS#150: Fix WebSocket test flake + UrlLib/AndroidExtensions updates - BabylonJS#151: Clean up deadlock regression test - BabylonJS#152: Fix performance test flake Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
bghgary
added a commit
that referenced
this pull request
Apr 14, 2026
[Created by Copilot on behalf of @bghgary] Bump JsRuntimeHost, arcana.cpp, and AndroidExtensions to latest. ## JsRuntimeHost (8086014) - **#147**: Fix WorkQueue destructor deadlock (cancel + no-op wake) - **#149**: Merge WorkQueue into AppRuntime (eliminates split-lifetime issues) - **#150**: Fix WebSocket test flake + update UrlLib/AndroidExtensions for consistent onClose-after-onError - **#151**: Clean up deadlock regression test (one-shot hook, expanded comments) - **#152**: Fix performance test flake (remove upper-bound setTimeout assertion) - **#154**: Hide arcana behind pimpl pattern in AppRuntime (arcana headers no longer exposed publicly) - **#155**: Update package-lock.json ## arcana.cpp (b9bf9d8) Includes test hooks for the deadlock regression test (`ARCANA_TEST_HOOKS` / `arcana::test_hooks::blocking_concurrent_queue`). ## AndroidExtensions (2e85a8d) Removes the redundant `errorCallback` from `onClose` in the Java WebSocket wrapper (AndroidExtensions#16). Matches the version JsRuntimeHost depends on via UrlLib. --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
Beginning the real decoupling process by removing all direct dependencies on
RuntimeImpland replacing them with dependencies on the newJsRuntime. This has resulted in some temporary code duplication as the Babylon Native API hasn't been changed yet, only its internal structure, so some things like URL loading end up semi-duplicated as ownership of capabilities is being moved from one place to another.