refactor: Rewrite JS API to share server implementation of Flight/Barrage#5890
Merged
niloc132 merged 262 commits intodeephaven:mainfrom Sep 10, 2024
Merged
refactor: Rewrite JS API to share server implementation of Flight/Barrage#5890niloc132 merged 262 commits intodeephaven:mainfrom
niloc132 merged 262 commits intodeephaven:mainfrom
Conversation
niloc132
commented
Sep 6, 2024
| // assert isSorted(); | ||
| } | ||
|
|
||
| public void appendRanges(List<Range> ranges, long firstItemSubindex) { |
Member
Author
There was a problem hiding this comment.
That this new method is unused is one of my qualms about this change - or at least is an opportunity to improve. A binary search when we get started on add/remove/shift, bulk adding as we encounter consecutive untouched ranges, or getting the index of the last range touched so we can bulk add the rest would let us skip ~O(n) long + ops or Range.overlap (i.e. two compares) for each range. Not going to make a huge difference, compared to the work so far, but could buy us a little more breathing room.
nbauernfeind
previously approved these changes
Sep 9, 2024
nbauernfeind
previously approved these changes
Sep 9, 2024
nbauernfeind
approved these changes
Sep 10, 2024
mofojed
approved these changes
Sep 10, 2024
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Rewrites JS API Flight/Barrage to share code as much as possible with the JVM client/server implementation. Some classes are effectively copied with minor updates to function in the browser, such as WebBarrageStreamReader. Others offer alternative implementations to generic interfaces, like WebChunkReaderFactory. Finally, super source is added to handle classes in Deephaven, gRPC, and Java itself, to allow use of those types in the browser.
Notably, JS clients subscriptions are now the same implementation for both viewports and full table subscriptions. This change may degrade performance of viewports in some case relative to previous versions. To help mitigate this, in certain cases the configuration property
web.flattenViewportmay improve things. This lets the server instruct all clients to flatten their tables before subscribing.Fixes #188
Fixes #186