facebook

JBoss Hibernate Tools Plugin Conflict in MyEclipse 4.1

  1. MyEclipse Archived
  2.  > 
  3. Database Tools (DB Explorer, Hibernate, etc.)
Viewing 15 posts - 1 through 15 (of 23 total)
  • Author
    Posts
  • #245102 Reply

    Jim Watkins
    Member

    Hi,

    I know this falls under the general problem of plugin dependencies conflicting with each other, but I’m hoping somebody made this work.

    I have traditionally used the jboss projects hibernate tools, and so far still like them better. This has never been a problem until 4.1, where I now don’t get any of the hibernate views, tools, or perspectives if I enable myeclipse. I can roll back to 4.03 and boom, full functionality back.

    I use myeclipse as a manual install seperate from my std plugins which are also done as an extension location (hibernate tools and subclipse basically), so it’s pretty easy to toggle these things around.

    I’ve tried Eclsipe 3.1 and 3.1.1 and all manner of -clean stuff. I’m just looking for tips on how to dig deeper into this issue.

    #245103 Reply

    Riyad Kalla
    Member

    Jim,
    The reason is that in 4.1 we integrated work from the hibernate tools project (the mapping generator) so now there are conflicts between the projects. Moving forward we will continue to pull in the better features from HT so hopefully you won’t need the two of them side by side.

    What is it about HT that you use most?

    #245143 Reply

    Jim Watkins
    Member

    In 2 words, schema export/regeneration. I have complex java objects and manage the mapping files myself, but then as the objects get richer I often regenerate the schema for our embedded derby databases. I know I have some other options for this, especially ant tasks, but just wanted to keep using what I know, and I didn’t see this functionality in my cursory review of hibernate functionality in myeclipse. Did I miss something?

    #245220 Reply

    Riyad Kalla
    Member

    No you didn’t, but I have added this to our TODO list.

    #245235 Reply

    Jim Watkins
    Member

    Great, thanks. I went to vote on it, but didn’t see it as an option for 5. I guess I will hold at 4.03 or learn to use the ant tasks in the meantime. Thanks for the prompt responses.

    #245456 Reply

    thomsongale
    Member

    We are also using the JBoss toolset and got a big surprise when we upgraded. The feature that we will miss the most is the HQLScratchPad. Without this, we’ll probably stay on the old version…

    #245688 Reply

    Jon Nermut
    Member

    I can’t believe you integrated hibernate tools and then turned features off!
    This is very poor form.

    Either integrate the whole thing, or leave it alone.

    We use the hibernate console and other aspects of the hibernate tools, and want to move to hibernate tools beta 2. But it wont the plugin wont even load because of ME’s half assed version of the plugin.

    Now I’m just going to have to try and hack it…

    #245690 Reply

    Jon Nermut
    Member

    Your right, there is a definite incompatibility between ME 4.1 and Hibernate Tools 3.1 beta 2.
    The ME hibernate plugin fails on startup with:

    Caused by: java.lang.NoSuchMethodError: org.hibernate.eclipse.HibernatePlugin.getDefault()Lorg/hibernate/eclipse/HibernatePlugin;
    at com.genuitec.eclipse.hibernate.core.HibernateCore.getDataPlugin(HibernateCore.java:178)
    at com.genuitec.eclipse.hibernate.core.HibernateCore.computeMyEclipseHibernateVarPath(HibernateCore.java:164)
    at com.genuitec.eclipse.hibernate.classpath.HibernateClasspathVariableInitializer.initialize(HibernateClasspathVariableInitializer.java:33)
    at org.eclipse.jdt.core.JavaCore.getClasspathVariable(JavaCore.java:1443)
    at com.genuitec.eclipse.hibernate.core.HibernateCore.initializeDefaultPreferences(HibernateCore.java:448)
    at com.genuitec.eclipse.core.GenuitecPlugin.getPreferenceStore(GenuitecPlugin.java:75)
    at com.genuitec.eclipse.hibernate.core.HibernateCore.<init>(HibernateCore.java:107)

    Could you please fix the incompatibility and release a point version with the latest version of hibernate tools, with the console *turned on* ?
    I will have to wait for this before I can upgrade our dev environment.

    Thanks,

    Jon

    #245695 Reply

    support-michael
    Keymaster

    After reviewing the underlying assumptions between MyEclipse 4.X and Hibernate Tools 3.X it appears that we made an honest mistake by not completing an update of the MyEclipse Hibernate Tools integration to coexists cleanly with JBoss HT. We apologize for the inconvenience and the problem will be remedied in the upcoming ME 4.1.1 at the end of Feb.

    #245711 Reply

    Jon Nermut
    Member

    OK thanks Michael. Is there any chance of a patch before 4.1.1?

    I note also that Hibernate Tools has put out beta4 yesterday. It is unfortunate that HT is in such active development, it must be a struggle to keep up.

    #246011 Reply

    Here’s how to get hibernate-tools 3.1beta4 to work, disabling any MyEclipse Hibernate functionality (NOTE: This is only meant as a workaround if you absolutely NEED hibernate-tools, following the steps below might seriously screw your Eclipse/MyEclipse installation. So please only proceed if you really know what you’re doing!)

    OK, on to the gory details…

    1. Locate the MyEclipse install location, it should contain two folders “plugins” and “features”. Let’s call this $MYECLIPSE.
    2. Create two folders named “disabled_plugins” and “disabled_features” in $MYECLIPSE.
    3. Move the MyEclipse Hibernate feature (folder: $MYECLIPSE/features/com.genuitec.myeclipse.hibernate_4.0.100 ) to the “disabled_features” folder
    4. Move the following folders from $MYECLIPSE/plugins to “disabled_plugins”:
      1. com.genuitec.eclipse.hibernate_4.0.100
      2. com.genuitec.myeclipse.hibernate_4.0.100
      3. org.hibernate.eclipse.console_4.0.100
      4. org.hibernate.eclipse.mapper_4.0.100
      5. org.hibernate.eclipse_4.0.100
    5. Last step: remove the dependency from the main MyEclipse feature. Open the file $MYECLIPSE/features/com.genuitec.myeclipse.enterprise.workbench_4.0.100/feature.xml.
      Locate the following snippet:

      <includes
               id="com.genuitec.myeclipse.hibernate"
               version="4.0.100"
               name="MyEclipse Hibernate Support"/>
      

      … and comment it out, like:

      <!--
      <includes
               id="com.genuitec.myeclipse.hibernate"
               version="4.0.100"
               name="MyEclipse Hibernate Support"/>
      -->
      

    Now restart Eclipse (preferably using “-clean” switch), install hibernate-tools 3.1 (if you have not already done so) and enjoy!

    #246027 Reply

    Just noticed that I still had 4.1 Milestone1… however, I install 4.1GA and repeated the procedure, it still seems to work. Just replace all version numbers with “4.1.0” in the previous post!

    #246106 Reply

    beming
    Member

    I am using hibernate tools too — just want to run the hsql on eclipse… so I am using tow Eclipse Platform, one using ME4.1, the other use hibernate tools^_^

    #246122 Reply

    Jon Nermut
    Member

    Bump. Any chance of a quick fix before the end of the month?

    #246134 Reply

    i used the reverse engineering tool with a mysql innodb and in the generated mappings some of the foreign key constrains were missing… i could not find any switch in your database console to selct innodb… in the hibernate console you can specify the mysql innodb dialect… i tried your workaround to activate the hibernate tools, but this crashed my installation… i moved also back to a basic eclipse wtp version to use the original hibernate tools and everything was fine… i also would like to see full hibernate tools support in myeclipse!

Viewing 15 posts - 1 through 15 (of 23 total)
Reply To: JBoss Hibernate Tools Plugin Conflict in MyEclipse 4.1

You must be logged in to post in the forum log in