Adjusted memory strategy of json conversion.
Handle invalid json and packages without payload.