This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 258538 - [JPA 2.0] persistence unit properties
Summary: [JPA 2.0] persistence unit properties
Status: RESOLVED FIXED
Alias: None
Product: Dali JPA Tools
Classification: WebTools
Component: General (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: 2.3 M2   Edit
Assignee: Tran Le CLA
QA Contact:
URL:
Whiteboard: JPA2.0
Keywords: plan
Depends on: 249023
Blocks:
  Show dependency tree
 
Reported: 2008-12-11 14:45 EST by Karen Butzke CLA
Modified: 2010-01-21 12:56 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Karen Butzke CLA 2008-12-11 14:45:06 EST
The JPA spec now defines some persistence unit properties
javax.persistence.lock.timeout — value in seconds for pessimistic lock timeout
javax.persistence.query.timeout — value in seconds for query timeout

The following properties defined by this specification are intended for use in Java SE environments:
javax.persistence.jdbc.driver — fully qualified name of the driver class
javax.persistence.jdbc.url — driver-specific URL
javax.persistence.jdbc.user — username used by database connection
javax.persistence.jdbc.password
Comment 1 Karen Butzke CLA 2008-12-12 14:00:43 EST
javax.persistence.lock.timeout - this is supported by EclipseLink in 1.1 bug 248489

javax.persistence.jdbc.driver — fully qualified name of the driver class
javax.persistence.jdbc.url — driver-specific URL
javax.persistence.jdbc.user — username used by database connection
javax.persistence.jdbc.password
These are targeted to EclipseLink 2.0 in bug 249023


javax.persistence.query.timeout - unsure about this one
Comment 2 Neil Hauge CLA 2009-08-06 10:17:22 EDT
I think we want to always use (write) the new jdbc property names for both Generic 2.0 and the EclipseLink 2.0 platforms.  We should also be able to read the old EclipseLink property names for backwards compatibility, but we can always write the new properties out when values are changed.  This would require removing the old property.  The other option would be to update values using the old property names if they are present.
Comment 3 Tran Le CLA 2009-08-06 18:17:01 EDT
We would want to have the same properties organization on JPA 2.0 platform then on the EclipseLink 2.0 platform.
Connection tab
	javax.persistence.jdbc.driver 
	javax.persistence.jdbc.url
	javax.persistence.jdbc.user
	javax.persistence.jdbc.password
Options tab
Miscellaneous Options group 
	javax.persistence.lock.timeout
	javax.persistence.query.timeout
	javax.persistence.validation.group.pre-persist
	javax.persistence.validation.group.pre-update
	javax.persistence.validation.group.pre-remove

Comment 4 Tran Le CLA 2009-09-08 13:22:32 EDT
Dali can now read EclipseLink 1.1 or 2.0 persistence unit properties, and will have the following behavior when legacy properties names are found:
- If there is no change to the persistence.xml, the xml file remains unchanged.
- If EclipseLink 1.1 and 2.0 names are present for the same property, EclipseLink 2.0 name will be retained.
- If there is any change to the persistence.xml, migration to new properties names will take place.