rds-json generate json with index key on first level of array

agentzh agentzh at gmail.com
Mon Feb 25 20:03:23 UTC 2013


On Mon, Feb 25, 2013 at 12:56 AM, Mauro Stettler wrote:
> Thanks, that would probably be possible.
> It's just that this URL is called very frequently, so I'm trying to do
> everything as resource efficient as possible. I am worried that parsing the
> json in lua in Nginx and reformatting it would be too heavy on the server
> load. So I would have preferred if there is some way how I can tell the
> rds-json module to format it the way I want.

No, ngx_rds_json does not support this very JSON structure. Because
there's tons of different possible JSON structures, I don't quite feel
like implementing complex configuration templates in ngx_rds_json in
pure C, which is a daunting task and adds complexity to this simple

I believe using ngx_lua for complicated formatting requirements is the
right way to go.

Best regards,

More information about the nginx mailing list