Close #5
Remove final line separator from the output using trim().
Write the received JSON object in the JBOSS logs.