-
-
Notifications
You must be signed in to change notification settings - Fork 52
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
Painfully slow on 16MB (minified) JSON #2
Comments
@corneliusroemer Thanks for your reporting! 👍 Could you share the actual JSON, if possible? I'd like to test it myself and understand the current data size limits. |
@corneliusroemer fx and jless are indeed famous for their ability to display content very quickly. On the other hand, I believe there can be a division of use cases: utilize fx or jless when you want to get an overview of the large JSON, and use fx and jless do allow for field lookup with .path.to.field and have some simple DSL query capabilities, but I understand that they cannot handle complex queries like jq can. |
Thanks for the detailed reply. I suppose some The biggest usability problem for large files is that keystrokes are delayed. |
@corneliusroemer You're absolutely right; there's a potential to degrade user experience.
|
Hey, I wrote a similar project a while ago: Jex. While the UI looks a lot better here, I didn't have this problem. I believe the difference is that I parsed the JSON once at load and then used the parsed structure from there on out. Looking at your code, you already parse the output to json so you're in a pretty good spot there. Even if you don't think it's worth it to switch your rendering code to use JQ's internal representation, I bet you could convert from JQ's representation to yours a lot faster if you didn't go through a string representation between the two. |
I would recommend Jaq, it's native rust and you can won't have to convert each time, and was built to fix some speed cases with many filters compared to jq. |
I love the idea of this tool, and the demo looks really cool too!
Installation worked flawlessly with
cargo install jnv
, but when I fired it up on a real JSON I had looked at withjq
earlier, I noticed it was painfully slow, unusably slow, response times were on the order of 5-10 seconds after each key stroke.Of course this is v0.1.0 - but just wanted to give feedback nonetheless from my real world test drive.
I'm on an M1 Pro with 32GB RAM which is fairly high end.
I tried reducing the display depth but that didn't help.
The text was updated successfully, but these errors were encountered: