Forum Stats

  • 3,824,912 Users
  • 2,260,439 Discussions


Good practice logging requests in a database table


I'm recording the requests I receive in a database table for some of my services, in order to be able to follow up errors reported by the users when things go wrong.

So I created a table where I store metadata, like the timestamp at the beginning and end of the operation. I also store the method, the relative url, and even the :body_text in a clob.

I'm not sure if this is good practice, maybe they are already being stored somewhere in the data dictionary and I am doing redundant work. Do you know if this kind of info is already stored?

Also, I realized :body_text is empty if they send the parameters in header instead of in json.

Is there a parameter with the url I can use? (now I'm writing it literal).