mosinnik opened a new issue, #3020:
URL: https://github.com/apache/fory/issues/3020

   ### Question
   
   I have a lot of small xml data files (for example 350kb) which loaded on app 
startup. I tried to replace them by fory's binaries but faced with some problem 
- fory spent more time to compile schema then I saved from changing xml to 
fory. 
   I understand that this case is not main for Fory and economy will be 
significant on gigabytes but it is what it is.
   So is the way to make schema compilation before application start? For 
example as in protobuf we got generated sources that compiled with java app 
code.
   
   
   Some info about my case with xml file 350kb, time spending:
   without FORY.ensureSerializersCompiled() before cold run
   ```
   // first cold run
   xml load time:  148.5407ms
   fory load time: 329.1291ms
   // reruns on same File for both
   xml load time:  28.6406ms
   fory load time: 1.2944ms
   xml load time:  18.3849ms
   fory load time: 1.1509ms
   xml load time:  14.0866ms
   fory load time: 1.0308ms
   ```
   
   with FORY.ensureSerializersCompiled() before cold run
   ```
   // first cold run
   xml load time:  152.4519ms
   fory load time: 5.6785ms
   // reruns on same File for both
   xml load time:  27.0664ms
   fory load time: 1.288ms
   xml load time:  26.7402ms
   fory load time: 1.1875ms
   xml load time:  20.6955ms
   fory load time: 1.4123ms
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to