Wednesday, September 17, 2008

A problem with HibernateTools of JBossTools on Eclipse Ganymede

Latest version of Hibernate Tools 3.2.3ga is broken. It's using nonexistent class SWTResourceUtil which existed in Eclipse Europa. Opening Hibernate views ends with

Java.lang.NoClassDefFoundError: org/eclipse/ui/internal/util/SWTResourceUtil at prg.hibernate.eclipse.console.workbench.xpl.AnyAdaptableLabelProvider.getImage(AnyAdaptableLabelProvider.java:166) at org.eclipse.jface.viewers.WrappedViewerLabelProvider.getImage(WrappedViewerLabelProvider.java:117) at org.eclipse.jface.viewers.WrappedViewerLabelProvider.update(WrappedViewerLabelProvider.java:165) at org.eclipse.jface.viewers.ViewerColumn.refresh(ViewerColumn.java:145) at org.eclipse.jface.viewers.AbstractTreeViewer.doUpdateItem(AbstractTreeViewer.java:932) at org.eclipse.jface.viewers.AbstractTreeViewer$UpdateItemSafeRunnable.run(AbstractTreeViewer.java:102) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
and more...

Some developers are now working for a fix but for now you can patch it by yourself. Find plugin org.eclipse.ui.workbench_xxxx.jar of previous version of Eclipse (3.3 for example) and open it with some ZIP extractor. Copy class org/eclipse/ui/internal/util/SWTResourceUtil.class to current plugin jar of your Ganymede installation and restart Eclipse.

Some say that Hibernate configuration plugin works slower than in Europa version but who cares as it works at least!(!)
The solution was taken from Hibernate bug report http://opensource.atlassian.com/projects/hibernate/browse/HBX-1068 

1 comment:

  1. This can't solve the problem entirely. The Hibernate 3.X XML Editor is missing. When I run the SchemaExport, Eclipse auto exit itself. Crap!

    ReplyDelete