- This topic has 10 replies, 3 voices, and was last updated 20 years, 4 months ago by Riyad Kalla.
-
AuthorPosts
-
peterwontnerMemberUsing the Generate Hibernate Mappings action from the DE (RMB on a table), with the “Update Hibernate Configuration File” check box ticked, causes any previously defined properties to get wiped out, i.e. all the database connection information. The work around at the moment is to clear the check box and manually add the mapping info to the configuration file.
Riyad KallaMemberI will ask the hibernate dev to look at this.
support-jeffMemberpeter –
Are you doing this with a project created under ME 3.8-beta2? There may be an incompatibility issue. Also, please look at your error logs for Eclipse and send along relevant entries. This can be obtained from <<workspace_dir>>/.metadata/.log or from the Error Log view inside Eclipse.
peterwontnerMemberJeff,
The project is a brand new project created with ME at the configuration level shown below.
configuration info…OS
Windows XP Pro SP 1Eclipse
Version: 3.0.0
Build Id: 200406192000MyEclipse
Version: 3.8.1 +QF20040823
Build Id: 200408201200-3.8.1 +QF20040823This is the contents of the .log file after performing this operation…
!SESSION Aug 25, 2004 07:24:45.722 ———————————————
eclipse.buildId=I200406192000
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US!ENTRY org.eclipse.update.configurator Aug 25, 2004 07:24:45.722
!MESSAGE Could not install bundle /C:/Program Files/MyEclipse/eclipse/plugins/org.eclipse.draw2d_3.0.0/ Bundle “org.eclipse.draw2d” version “3.0.0” has already been installed from: update@/e:/Eclipse_3/eclipse/plugins/org.eclipse.draw2d_3.0.0/!ENTRY org.eclipse.update.configurator Aug 25, 2004 07:24:45.802
!MESSAGE Could not install bundle /C:/Program Files/MyEclipse/eclipse/plugins/org.eclipse.gef_3.0.0/ Bundle “org.eclipse.gef” version “3.0.0” has already been installed from: update@/e:/Eclipse_3/eclipse/plugins/org.eclipse.gef_3.0.0/!ENTRY org.eclipse.core.runtime 4 2 Aug 25, 2004 07:24:54.634
!MESSAGE Problems encountered starting up plug-in: “org.osgi.framework.BundleException: Exception in org.eclipse.core.internal.compatibility.PluginActivator.start() of bundle com.genuitec.eclipse.wizards.”.
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.core.internal.compatibility.PluginActivator.start() of bundle com.genuitec.eclipse.wizards.
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:975)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:937)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:421)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:293)
at org.eclipse.core.internal.plugins.PluginDescriptor.doPluginActivation(PluginDescriptor.java:349)
at org.eclipse.core.internal.plugins.PluginDescriptor.getPlugin(PluginDescriptor.java:328)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.ui.internal.EarlyStartupRunnable.getPluginForCompatibility(EarlyStartupRunnable.java:140)
at org.eclipse.ui.internal.EarlyStartupRunnable.run(EarlyStartupRunnable.java:68)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:758)
at org.eclipse.ui.internal.Workbench$15.run(Workbench.java:1281)
at java.lang.Thread.run(Thread.java:534)
Caused by: java.lang.NoSuchMethodError: org.eclipse.gef.palette.PaletteEntry.getId()Ljava/lang/String;
at com.genuitec.eclipse.snippetinstaller.SnippetInstaller.installLibrary(Unknown Source)
at com.aston.AstonWizardsPlugin.installSnippetLibraries(Unknown Source)
at com.aston.AstonWizardsPlugin.startup(Unknown Source)
at org.eclipse.core.internal.compatibility.PluginActivator.start(PluginActivator.java:50)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:958)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:954)
… 14 more
Root exception:
java.lang.NoSuchMethodError: org.eclipse.gef.palette.PaletteEntry.getId()Ljava/lang/String;
at com.genuitec.eclipse.snippetinstaller.SnippetInstaller.installLibrary(Unknown Source)
at com.aston.AstonWizardsPlugin.installSnippetLibraries(Unknown Source)
at com.aston.AstonWizardsPlugin.startup(Unknown Source)
at org.eclipse.core.internal.compatibility.PluginActivator.start(PluginActivator.java:50)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:958)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:954)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:937)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:421)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:293)
at org.eclipse.core.internal.plugins.PluginDescriptor.doPluginActivation(PluginDescriptor.java:349)
at org.eclipse.core.internal.plugins.PluginDescriptor.getPlugin(PluginDescriptor.java:328)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.ui.internal.EarlyStartupRunnable.getPluginForCompatibility(EarlyStartupRunnable.java:140)
at org.eclipse.ui.internal.EarlyStartupRunnable.run(EarlyStartupRunnable.java:68)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:758)
at org.eclipse.ui.internal.Workbench$15.run(Workbench.java:1281)
at java.lang.Thread.run(Thread.java:534)!ENTRY org.eclipse.ui 4 4 Aug 25, 2004 07:24:54.644
!MESSAGE Unhandled Exception!ENTRY com.genuitec.eclipse.wizards 4 0 Aug 25, 2004 07:24:54.654
!MESSAGE Unable to execute early startup code for an extension
!STACK 0
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.ui.internal.EarlyStartupRunnable.getPluginForCompatibility(EarlyStartupRunnable.java:140)
at org.eclipse.ui.internal.EarlyStartupRunnable.run(EarlyStartupRunnable.java:68)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:758)
at org.eclipse.ui.internal.Workbench$15.run(Workbench.java:1281)
at java.lang.Thread.run(Thread.java:534)
Caused by: org.eclipse.core.runtime.CoreException: Problems encountered starting up plug-in: “org.osgi.framework.BundleException: Exception in org.eclipse.core.internal.compatibility.PluginActivator.start() of bundle com.genuitec.eclipse.wizards.”.
at org.eclipse.core.internal.plugins.PluginDescriptor.throwException(PluginDescriptor.java:284)
at org.eclipse.core.internal.plugins.PluginDescriptor.doPluginActivation(PluginDescriptor.java:351)
at org.eclipse.core.internal.plugins.PluginDescriptor.getPlugin(PluginDescriptor.java:328)
… 9 more
Root exception:
org.eclipse.core.runtime.CoreException[2]: org.osgi.framework.BundleException: Exception in org.eclipse.core.internal.compatibility.PluginActivator.start() of bundle com.genuitec.eclipse.wizards.
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:975)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:937)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:421)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:293)
at org.eclipse.core.internal.plugins.PluginDescriptor.doPluginActivation(PluginDescriptor.java:349)
at org.eclipse.core.internal.plugins.PluginDescriptor.getPlugin(PluginDescriptor.java:328)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.ui.internal.EarlyStartupRunnable.getPluginForCompatibility(EarlyStartupRunnable.java:140)
at org.eclipse.ui.internal.EarlyStartupRunnable.run(EarlyStartupRunnable.java:68)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:758)
at org.eclipse.ui.internal.Workbench$15.run(Workbench.java:1281)
at java.lang.Thread.run(Thread.java:534)
Caused by: java.lang.NoSuchMethodError: org.eclipse.gef.palette.PaletteEntry.getId()Ljava/lang/String;
at com.genuitec.eclipse.snippetinstaller.SnippetInstaller.installLibrary(Unknown Source)
at com.aston.AstonWizardsPlugin.installSnippetLibraries(Unknown Source)
at com.aston.AstonWizardsPlugin.startup(Unknown Source)
at org.eclipse.core.internal.compatibility.PluginActivator.start(PluginActivator.java:50)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:958)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:954)
… 14 more!ENTRY org.eclipse.ui 4 4 Aug 25, 2004 07:24:54.664
!MESSAGE Bad extension specification!ENTRY com.genuitec.eclipse.wizards 4 0 Aug 25, 2004 07:24:54.674
!MESSAGE startup class must implement org.eclipse.ui.IStartup
support-jeffMemberNothing in log specifically about hibernate tools? Most of this looks like some install problems. Riyad, any clues from what peter has posted?
Could you post the contents of the file <<workspace_dir>>/<<project>>/.myhibernatedata?
Riyad KallaMemberPeter,
This is minor, but your Eclipse build ID (Build Id: 200406192000 ) is not for the final Eclipse 3.0 GA build, which our 3.8 GA release needs to run correctly. I wouldn’t be surprised if this wierdness clears itself up as soon as you reinstall Eclipse 3.0 GA and MyEclipse 3.8.1 + Quickfix.
peterwontnerMemberRe-installed as suggested, and it works. Thanks very much for all your help.
peterwontnerMemberActually hitting another issue now. When I try and run a Hibernate based application from ME, I am getting the following exception while trying to initialise Hibernate transaction…
java.lang.UnsupportedOperationException: The user must supply a JDBC connection
at net.sf.hibernate.connection.UserSuppliedConnectionProvider.getConnection(UserSuppliedConnectionProvider.java:32)
at net.sf.hibernate.impl.BatcherImpl.openConnection(BatcherImpl.java:286)
at net.sf.hibernate.impl.SessionImpl.connect(SessionImpl.java:3326)
at net.sf.hibernate.impl.SessionImpl.connection(SessionImpl.java:3286)
at net.sf.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:40)
at net.sf.hibernate.transaction.JDBCTransactionFactory.beginTransaction(JDBCTransactionFactory.java:19)
at net.sf.hibernate.impl.SessionImpl.beginTransaction(SessionImpl.java:2231)
at main.LockRegister.test(LockRegister.java:58)
at main.LockRegister.main(LockRegister.java:109)
13:50:14,290 INFO SessionFactoryObjectFactory:82 – Not binding factory to JNDI, no JNDI name configuredMy configuration file is shown below…
<hibernate-configuration><session-factory>
<!– properties –>
<property name=”connection.url”>jdbc:oracle:thin:@gba-build-xp:1521:chs</property>
<property name=”dialect”>net.sf.hibernate.dialect.Oracle9Dialect</property>
<property name=”connection.username”>chspeterw</property>
<property name=”connection.password”>chspeterw</property>
<property name=”connection.driver_class”>oracle.jdbc.driver.OracleDriver</property><property name=”show_sql”>true</property>
<property name=”hbm2ddl.auto”>create</property><!– mapping files –>
<mapping resource=”/Lockreg.hbm.xml”/></session-factory>
</hibernate-configuration>
I can’t figure out what is wrong with this. One thing I have noticed is that my configuration file is not being copied to the bin package during compilation.
Riyad KallaMemberIs your connection URL correct? (jdbc:oracle:thin:@gba-build-xp:1521:chs) it looked to me like you have an extra colon right before the @, but then again I am not farmiliar with Oracle connection strings.
One thing I have noticed is that my configuration file is not being copied to the bin package during compilation.
Is it in the root of your source tree? Do you have auto build on? Do you have any property files that are getting copied correctly?
peterwontnerMemberHave just found and fixed the issue. Was incorrectly creating the session factory. I neglegted to call configure() on the configuration object before calling buildSessionFactory() – what an idiot!
But the last thing that is baffling me, which I think is either a real bug, or (more probably) user error. My hibernate mapping & configuration files are not being copied to the bin folder during a compile, so I have to manully add them before running. What could I be doing wrong?
Riyad KallaMemberDouble check your Window > Preferences > Java > Compiler > Build Path (tab) > Filtered Resources
field and make sure you don’t have .xml in there or something. By default the compiler will copy everything that is not a Java files and does not match that filter into the output dir. I’d also suggest checking your Workbench > Build resource automatically on modification settings just incase.
Also maybe check your project’s own Compiler settings to make sure you don’t have the main compiler settings overridden.
-
AuthorPosts