forked from tada/pljava
-
Notifications
You must be signed in to change notification settings - Fork 0
Logging
thallgren edited this page Jan 14, 2013
·
1 revision
PL/Java uses the standard java.util.logging.Logger Hence, you can write things like:
Logger.getAnonymousLogger().info( "Time is " + new Date(System.currentTimeMillis()));At present, the logger is hardwired to a handler that maps the current state of the PostgreSQL configuration setting log_min_messages to a valid Logger level and that outputs all messages using the backend function ereport(). The following mapping apply between the Logger levels and the PostgreSQL backend levels:
| java.util.logging.Level | PostgreSQL level |
|---|---|
| SEVERE | ERROR |
| WARNING | WARNING |
| INFO | INFO |
| FINE | DEBUG1 |
| FINER | DEBUG2 |
| FINEST | DEBUG3 |