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

Performance improvement needed, too slow for large data #206

Open
hoogw opened this issue Jan 17, 2020 · 1 comment
Open

Performance improvement needed, too slow for large data #206

hoogw opened this issue Jan 17, 2020 · 1 comment

Comments

@hoogw
Copy link

hoogw commented Jan 17, 2020

Performance improvement needed.

I test 60K (350MB) json file, oboe, compare to browser native stream api
is 10 times slower.

Only for small amount of data, difference is trivals.

Oboe, must have some over head over xhr.

If you use browser native stream api replace current xhr,

would it greatly improve the performance?

Now, for large data, I can't use oboe, it is way too slow. Instead, I just use browser native stream api , write simple parser on my own.

@hoogw
Copy link
Author

hoogw commented Jan 24, 2020

I guess, not verified, the slowness of oboe, is caused by blob, Blob/FileReader , blob builder etc....

To make it fast, need to use
var string = new TextDecoder(encoding).decode(uint8array);

there are several article talking about this slowness:

https://developers.google.com/web/updates/2012/06/How-to-convert-ArrayBuffer-to-and-from-String

https://stackoverflow.com/questions/6965107/converting-between-strings-and-arraybuffers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
@hoogw and others