[katello-devel] Better REST error messages

Lukas Zapletal lzap at redhat.com
Tue Aug 9 10:40:16 UTC 2011


Hello,

I slightly changed our HttpResource class error handling, so instead of

500 Internal Server Error

we get

Pulp::Consumer: 500 Internal Server Error (PUT 
/pulp/api/consumers/xxx/?owner=ACME_Corporation)

with the following meaning:

Pulp::Consumer - REST class throwing an error (Pulp or Candlepin etc)
500 Internal Server Error - REST exception message
PUT - HTTP method
/pulp/api/consumers/xxxx/?owner=ACME_Corporation - URL

No more digging in the Pulp log when it was Candlepin issue and vice 
versa. Enjoy.

-- 
Later,

  Lukas Zapletal | E32E400A
  RHN Satellite Engineering
  Red Hat Czech s.r.o. Brno




More information about the katello-devel mailing list