Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: sumi rpc support read stream #3362

Merged
merged 30 commits into from
Mar 5, 2024
Merged

feat: sumi rpc support read stream #3362

merged 30 commits into from
Mar 5, 2024

Conversation

bytemain
Copy link
Member

Types

  • 🎉 New Features

Background or solution

previously, we just read full content of a file, if the file is so large, it will consume many memories, so our program maybe oom.

I took a look at the applicable scenarios that can be changed:

  • calculate md5
  • guess encoding
  • load file content

Changelog

sumi rpc support read stream

@opensumi opensumi bot added the 🎨 feature feature required label Feb 26, 2024
Copy link

codecov bot commented Feb 27, 2024

Codecov Report

Attention: Patch coverage is 82.60870% with 136 lines in your changes are missing coverage. Please review.

Project coverage is 58.16%. Comparing base (65b42c3) to head (3cfa72e).

Files Patch % Lines
...ages/connection/src/common/rpc-service/registry.ts 65.00% 19 Missing and 2 partials ⚠️
packages/connection/src/common/fury-extends/any.ts 79.38% 20 Missing ⚠️
packages/connection/src/common/rpc/connection.ts 88.14% 15 Missing and 1 partial ⚠️
packages/connection/src/common/rpc/message-io.ts 88.28% 13 Missing ⚠️
packages/connection/src/common/server-handler.ts 67.64% 10 Missing and 1 partial ⚠️
...file-service/src/node/disk-file-system.provider.ts 33.33% 8 Missing and 2 partials ⚠️
...kages/connection/src/common/fury-extends/one-of.ts 90.47% 6 Missing ⚠️
...kages/connection/src/browser/ws-channel-handler.ts 63.63% 4 Missing ⚠️
...ckages/connection/src/common/rpc-service/center.ts 86.66% 4 Missing ⚠️
...es/file-service/src/browser/file-service-client.ts 0.00% 4 Missing ⚠️
... and 12 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3362      +/-   ##
==========================================
+ Coverage   58.09%   58.16%   +0.07%     
==========================================
  Files        1406     1405       -1     
  Lines       86576    86676     +100     
  Branches    17866    17907      +41     
==========================================
+ Hits        50298    50419     +121     
+ Misses      32996    32974      -22     
- Partials     3282     3283       +1     
Flag Coverage Δ
jsdom 53.02% <69.82%> (+0.08%) ⬆️
node 17.87% <80.69%> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

railway-app bot commented Feb 29, 2024

This PR is being deployed to Railway 🚅

core: ◻️ REMOVED

@bytemain
Copy link
Member Author

bytemain commented Mar 5, 2024

等到 monaco 0.45 的时候,就可以接入这个 stream 了:
CleanShot 2024-03-05 at 14 23 10@2x

Ricbet
Ricbet previously approved these changes Mar 5, 2024
Copy link
Member

@Ricbet Ricbet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Aaaaash
Aaaaash previously approved these changes Mar 5, 2024
@bytemain bytemain dismissed stale reviews from Aaaaash and Ricbet via 3cfa72e March 5, 2024 06:46
@bytemain bytemain requested a review from erha19 March 5, 2024 06:47
Copy link
Member

@erha19 erha19 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bytemain bytemain merged commit 859782a into main Mar 5, 2024
11 of 12 checks passed
@bytemain bytemain deleted the feat/support-read-stream branch March 5, 2024 08:34
@bytemain bytemain mentioned this pull request Mar 5, 2024
1 task
@erha19 erha19 added the v3 OpenSumi 3.0 label Mar 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🎨 feature feature required v3 OpenSumi 3.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants