Implements COMETD-408 (allow more detailed error handling)

Hi Simone,

as requested, here the pull request for the master - hope everything is ok, that was my first git/github experience...

Best Regards,
Florian