Entering content frame

Background documentation General Rules for Using Logs and Traces in J2EE Engine Locate the document in its SAP Library structure

...

       1.      The difference between logs and traces – logs are mainly addressed to an administrator of a customer system, while traces are addressed to developers and support organizations. An administrator typically is not interested in the details of the system architecture, but in areas according to his / her administration tasks. A developer, on the other hand, wants to see the details of the control flow. Of course, a log file may also be a good starting point for error analysis done by support engineers.

Logs are normally written to categories and traces are normally written to locations. Categories are semantic topics corresponding generally to administration tasks. Locations refer to certain points in the coding and can be identified with package-, class-, or function-names.

Note

Category names, as a rule, are not application names or names of organization units. In principle, categories are shared between different applications. If you end up with categories that correspond to your software structure, then your category design is probably wrong.

       2.      Using logs and traces – during normal operation, developers and supporters are not looking at a running system. On the other hand, the administrator has to check the system regularly. This implies that traces do not have to be shown during normal operation, but logs do.

                            a.      Only write to those messages that are important for an administrator who supervises the system during normal operation. Write to traces everything that might be important to trace erroneous behavior.

                            b.      Messages with severity DEBUG and PATH must be written as traces only. They must not be written as log messages.

                            c.      Any error message (of severity ERROR or FATAL) has to be written as a log message. Messages of severity ERROR or FATAL must not be written as trace messages

 

Leaving content frame