Thanks Davido and Tye for your replies. I will have a look at JSON::Tiny and see if that shows the same issue.
in reply to Re: JSON::XS Bool issue in mod_perl (XS--)
in thread JSON::XS Bool issue in mod_perl
I have just seen in the JSON documentation the following commend;
This module is not guaranteed to be thread safe and there are no plans to change this until Perl gets thread support (as opposed to the horribly slow so-called "threads" which are simply slow and bloated process simulations - use fork, it's much faster, cheaper, better).
I guess that mod_perl comes under threads due to the way that the module is reused over and over so I am not sure it's worth reporting as a bug.
if worst comes to worst I guess I could just use PP for now however some of the objects I need to encode can get quite big and will be slow but I am not sure if that will be noticeable due to the massive performance gains I get from mod_perl.
I will have to run some benchmarks next week to see which method will be the easiest. Thankfully all of the JSON code in my application is centralised so changing the JSON encoder is not a massive issue if XS will not work