In my newly uploaded October 2015 version (5.03) of powerEXT Core I have
included Scott Klement’s port of C based YAJL (Yet Another JSON Library) a
port many seems to have overlooked.



Before I have written some sub-procedures in RPGLE (JSON node support) but
in comparison to YAJL I get 2.5-5x better performance with YAJL thus
reducing an average 20KB JSON REST/CRUD total request time in the browser
from 300ms to approx. 150ms or a performance gain 2x.



Now, it could be funny to compare performance in other techniques such as
node.js and .NET. So I have built a little demo program that should be easy
to replicate in another language or even other native JSON wrappers.



The program uses SQL to read a table we all have (QIWS/QCUSTCDT) but
instead of making a single JSON object per row it loops 1,000 times and
creates 1,000 row objects for each physical row in the table resulting in
132.000 JSON nodes being generated (31,500 per second) in a 3,6 MB JSON
object.



Using my RPG JSON node support it took 24 sec to generate the object, with
YAJL it took 4,2 sec - with smaller objects the perfomance gain is only
2.5x.



Resources:



Scott Klements YAJL port: http://www.scottklement.com/yajl/



powerEXT Core including YAJL: http://powerext.com



My test program: http://powerext.com/rpgyajl.txt





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.