-
Notifications
You must be signed in to change notification settings - Fork 525
Stream API doesn't work without Javassist dependency #32
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
Comments
stream api is considered as "optional". 99% percent of time, byte array input will be the best option. |
Guess I am at that 1%. I have to process large json files and it is not possible to load them into the byte arrays held in memory. It should be possible to use streaming and writer API without dynamically linking anything or generating any code at runtime. |
The best option is to make a fork of this library. Delete IterImpl.java and rename IterImplForStreaming.java to IterImpl.java. The idea is to support streaming mode without virtual method call. So Javassist is used to shadow the class in runtime. |
That is pretty much what I had to do, but it is not maintainable like that. I'd have to stick with Jackson if that would be the only option. As a thought. Maybe make it other way around. Stream by default and replace virtual call when dynamic codegen is used... or provide JsonIteratorStream hardwired with IterImplForStreaming |
how about I maintain the fork for you? like lite version. It is just a bash script to copy the files needed over. What features do you need? Encoding or decoding? Iterator only or more? |
Thank you for a generous offer, but that won't be necessary. |
switch case based on string field is slow. that is the biggest bottleneck in all the parsing process. |
Javassist is listed as an optional dependency, however the following method is failing com.jsoniter.JsonIterator.parse(InputStream in, int bufSize) when Javassist is not available.
This shouldn't be happening for stream-only or static code generation.
The text was updated successfully, but these errors were encountered: