This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 283607 - JPA: dynamic metamodel requires initialization during EntityManagerFactory creation
Summary: JPA: dynamic metamodel requires initialization during EntityManagerFactory cr...
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Nobody - feel free to take it CLA
QA Contact:
URL: http://wiki.eclipse.org/EclipseLink/D...
Whiteboard:
Keywords:
Depends on: 266912
Blocks: 297748
  Show dependency tree
 
Reported: 2009-07-15 14:11 EDT by Michael OBrien CLA
Modified: 2022-06-09 10:35 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael OBrien CLA 2009-07-15 14:11:31 EDT
>In section 6.2.3 "Bootstrapping" of the JPA 2.0 specification - it states that the metamodel must be initialized on EMF creation. 
"When the entity manager factory for a persistence unit is created, it is the responsibility of the persistence 
provider to initialize the state of the metamodel classes of the persistence unit. Any generated metamodel classes must be accessible on the classpath." 

>This design document involves the "dynamic" metamodel and not the static canonical metamodel - however in the introduction for section 6.2, the spec describes the two metamodel access methods dynamic or static to be interchangable. 
So my question is - do we allow the dynamic metamodel to continue to to be lazy initialized on the EMF when a getMetamodel() call is requested - or do we create the metamodel automatically during EMF construction. 
This question is best answered when we have the requirements of the canonical metamodel - which will use the dynamic metamodel to introspect the metadata.
Comment 1 Michael OBrien CLA 2009-07-27 16:22:58 EDT
>All new JPA 2.0 code modifications are categorized as enhancement until the JPA 2.0 RI is released.
Comment 2 Michael OBrien CLA 2009-11-12 07:37:53 EST
>This issue has been deprecated by the fix and move to EntityManagerFactoryImpl in DI 92 and SVN rev# 5541 on 14 Oct 2009
http://wiki.eclipse.org/EclipseLink/Development/JPA_2.0/metamodel_api#DI_92:_20091008:_Move_metamodel_instance_field_from_EntityManagerFactory_to_EntityManagerSetupImpl
http://fisheye2.atlassian.com/changelog/eclipselink/?cs=5541
Comment 3 Eclipse Webmaster CLA 2022-06-09 10:35:26 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink