Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » Problem with dataStore.initialize() with the eclipse.org/bpel - model
Problem with dataStore.initialize() with the eclipse.org/bpel - model [message #93664] Tue, 21 August 2007 11:41
Eclipse UserFriend
Originally posted by: user.domain.invalid

Hi,

i have a problem with the generation of the hibernate-mapping file.
My model project is the standard Bpel-Model from www.eclipse.org/bpel/.

I use Eclipse 3.3 WTP. And teneo 0.8. The code of the DB initialization is:

public static void main(String[] args) {

final String dataStoreName = "bpel20";
final HbDataStore dataStore = (HbDataStore) HbHelper.INSTANCE
.createRegisterDataStore(dataStoreName);
Properties hibernateProperties = new Properties();
hibernateProperties.setProperty(Environment.DRIVER,
"com.mysql.jdbc.Driver");
hibernateProperties.setProperty(Environment.USER, "XXX");
hibernateProperties.setProperty(Environment.URL,
"jdbc:mysql://127.0.0.1:3306/bpel20");
hibernateProperties.setProperty(Environment.PASS, "XXX");
hibernateProperties.setProperty(Environment.DIALECT,
"org.hibernate.dialect.MySQLInnoDBDialect");

dataStore.setHibernateProperties(hibernateProperties);
// coonfig persistence options
Properties persistenceOptions = new Properties();
persistenceOptions.setProperty(PersistenceOptions.INHERITANC E_MAPPING,
"JOINED");
persistenceOptions.setProperty(
PersistenceOptions.FETCH_CONTAINMENT_EAGERLY, "true");
dataStore.setPersistenceProperties(persistenceOptions);
dataStore.setEPackages(new EPackage[] {
org.eclipse.bpel.model.BPELPackage.eINSTANCE });
dataStore.initialize();
}



I get an error at the dataStore initalization. The following error
occured:

(...)

[main] DEBUG org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator
- Creating mapping for eclass Process
1236 [main] DEBUG
org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator - Creating
mapping for eclass ExtensibleElement
Exception in thread "main" java.lang.IllegalArgumentException: No
annotated model element present for: ExtensibleElement for type EClass
has its epackage been registered with Teneo?
at
org.eclipse.emf.teneo.annotations.pamodel.impl.PAnnotatedMod elImpl.checkAnnotatedPresent(PAnnotatedModelImpl.java:322)
at
org.eclipse.emf.teneo.annotations.pamodel.impl.PAnnotatedMod elImpl.getPAnnotated(PAnnotatedModelImpl.java:268)
at
org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator.pr ocessClass(DefaultAnnotator.java:353)
at
org.eclipse.emf.teneo.hibernate.hbannotation.util.HibernateD efaultAnnotator.processClass(HibernateDefaultAnnotator.java: 178)
at
org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator.pr ocessClass(DefaultAnnotator.java:362)
at
org.eclipse.emf.teneo.hibernate.hbannotation.util.HibernateD efaultAnnotator.processClass(HibernateDefaultAnnotator.java: 178)
at
org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator.pr ocessPackage(DefaultAnnotator.java:319)
at
org.eclipse.emf.teneo.annotations.mapper.DefaultAnnotator.ma p(DefaultAnnotator.java:210)
at
org.eclipse.emf.teneo.annotations.mapper.PersistenceMappingB uilder.buildMapping(PersistenceMappingBuilder.java:128)
at
org.eclipse.emf.teneo.hibernate.HbDataStore.mapEPackages(HbD ataStore.java:531)
at
org.eclipse.emf.teneo.hibernate.HbSessionDataStore.mapModel( HbSessionDataStore.java:149)
at
org.eclipse.emf.teneo.hibernate.HbSessionDataStore.initializ e(HbSessionDataStore.java:70)
at test.MainTest.createDatabase(MainTest.java:27)
at test.MainTest.main(MainTest.java:19)
Previous Topic:[EMF-Compare] left and right model
Next Topic:Problem with dataStore.initialize() with the eclipse.org/bpel - model
Goto Forum:
  


Current Time: Fri Apr 19 20:54:05 GMT 2024

Powered by FUDForum. Page generated in 0.03287 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top