Issue Details (XML | Word | Printable)

Key: OPENJPA-10
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Unassigned
Reporter: Patrick Linskey
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OpenJPA

persistence unit name should be default diagnostic context for standard OpenJPA log impl

Created: 10/Aug/06 01:33 AM   Updated: 01/Mar/07 02:13 AM
Return to search
Component/s: None
Affects Version/s: None
Fix Version/s: 0.9.7

Time Tracking:
Not Specified

Resolution Date: 01/Feb/07 06:41 AM


 Description  « Hide
OpenJPA's default logging implementation has a concept of a diagnostic context, roughly stolen from log4j. The basic idea is that in a configuration file, the user can specify a diagnostic context string that will be printed out with each log message. The result is that if a user has multiple EntityManagerFactories running in the same JVM, she can distinguish between the different logging outputs, even if they all just go to stderr.

The JPA spec requires that persistence units are named uniquely. This presents us with an opportunity: we could check for the existence of multiple EMFs and, if found and the user did not specify a diagnostic context, automatically set the logging diagnostic context based on the name of the persistence unit.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Patrick Linskey made changes - 01/Feb/07 06:41 AM
Field Original Value New Value
Resolution Fixed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]
Patrick Linskey made changes - 01/Mar/07 02:13 AM
Fix Version/s 0.9.7 [ 12312340 ]