java.lang.NoClassDefFoundError

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • If POJOs require thirdparty libraries which are not added to the classpath in the Hibernate Configuration, a lot of Exceptions occur. However, one of them is extremely annoying when it occurs as it is shown for *each* returned object in a HQL query result viewer. It is not possible to quit Eclipse in a clean way any more as the error message keeps popping up. I suggest to catch problems occuring in the label provider and show them *once* in the problems view. !ENTRY org.eclipse.jface 4 2 2006-11-22 13:48:00.053 !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface". !STACK 0 java.lang.NoClassDefFoundError: org/apache/commons/lang/builder/ToStringBuilder at com.example.SomePojo.toString(SomePojo.java:201) at org.hibernate.eclipse.console.views.QueryPageViewer$LabelProviderImpl.getColumnText(QueryPageViewer.java:77) at org.eclipse.jface.viewers.TableViewer.doUpdateItem(TableViewer.java:486) at org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRunnable.run(StructuredViewer.java:465) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:843) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:149) at org.eclipse.jface.viewers.StructuredViewer.updateItem(StructuredViewer.java:1955) at org.eclipse.jface.viewers.TableViewer.createItem(TableViewer.java:350) at org.eclipse.jface.viewers.TableViewer.internalRefreshAll(TableViewer.java:923) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:818) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:807) at org.eclipse.jface.viewers.StructuredViewer$7.run(StructuredViewer.java:1388) at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1323) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1386) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1345) at org.eclipse.jface.viewers.TableViewer.inputChanged(TableViewer.java:767) at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:250) at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:1542) at org.hibernate.eclipse.console.views.QueryPageViewer.createTable(QueryPageViewer.java:208) at org.hibernate.eclipse.console.views.QueryPageViewer.createControl(QueryPageViewer.java:187) at org.hibernate.eclipse.console.views.QueryPageViewer.<init>(QueryPageViewer.java:145) at org.hibernate.eclipse.console.views.QueryPageTabView.rebuild(QueryPageTabView.java:109) at org.hibernate.eclipse.console.views.QueryPageTabView.createPartControl(QueryPageTabView.java:151)
    via by Mike haller,
  • If POJOs require thirdparty libraries which are not added to the classpath in the Hibernate Configuration, a lot of Exceptions occur. However, one of them is extremely annoying when it occurs as it is shown for *each* returned object in a HQL query result viewer. It is not possible to quit Eclipse in a clean way any more as the error message keeps popping up. I suggest to catch problems occuring in the label provider and show them *once* in the problems view. !ENTRY org.eclipse.jface 4 2 2006-11-22 13:48:00.053 !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface". !STACK 0 java.lang.NoClassDefFoundError: org/apache/commons/lang/builder/ToStringBuilder at com.example.SomePojo.toString(SomePojo.java:201) at org.hibernate.eclipse.console.views.QueryPageViewer$LabelProviderImpl.getColumnText(QueryPageViewer.java:77) at org.eclipse.jface.viewers.TableViewer.doUpdateItem(TableViewer.java:486) at org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRunnable.run(StructuredViewer.java:465) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:843) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:149) at org.eclipse.jface.viewers.StructuredViewer.updateItem(StructuredViewer.java:1955) at org.eclipse.jface.viewers.TableViewer.createItem(TableViewer.java:350) at org.eclipse.jface.viewers.TableViewer.internalRefreshAll(TableViewer.java:923) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:818) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:807) at org.eclipse.jface.viewers.StructuredViewer$7.run(StructuredViewer.java:1388) at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1323) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1386) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1345) at org.eclipse.jface.viewers.TableViewer.inputChanged(TableViewer.java:767) at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:250) at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:1542) at org.hibernate.eclipse.console.views.QueryPageViewer.createTable(QueryPageViewer.java:208) at org.hibernate.eclipse.console.views.QueryPageViewer.createControl(QueryPageViewer.java:187) at org.hibernate.eclipse.console.views.QueryPageViewer.<init>(QueryPageViewer.java:145) at org.hibernate.eclipse.console.views.QueryPageTabView.rebuild(QueryPageTabView.java:109) at org.hibernate.eclipse.console.views.QueryPageTabView.createPartControl(QueryPageTabView.java:151)
    via by Mike haller,
    • java.lang.NoClassDefFoundError: org/apache/commons/lang/builder/ToStringBuilder at com.example.SomePojo.toString(SomePojo.java:201) at org.hibernate.eclipse.console.views.QueryPageViewer$LabelProviderImpl.getColumnText(QueryPageViewer.java:77) at org.eclipse.jface.viewers.TableViewer.doUpdateItem(TableViewer.java:486) at org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRunnable.run(StructuredViewer.java:465) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:843) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:149) at org.eclipse.jface.viewers.StructuredViewer.updateItem(StructuredViewer.java:1955) at org.eclipse.jface.viewers.TableViewer.createItem(TableViewer.java:350) at org.eclipse.jface.viewers.TableViewer.internalRefreshAll(TableViewer.java:923) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:818) at org.eclipse.jface.viewers.TableViewer.internalRefresh(TableViewer.java:807) at org.eclipse.jface.viewers.StructuredViewer$7.run(StructuredViewer.java:1388) at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1323) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1386) at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1345) at org.eclipse.jface.viewers.TableViewer.inputChanged(TableViewer.java:767) at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:250) at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:1542) at org.hibernate.eclipse.console.views.QueryPageViewer.createTable(QueryPageViewer.java:208) at org.hibernate.eclipse.console.views.QueryPageViewer.createControl(QueryPageViewer.java:187) at org.hibernate.eclipse.console.views.QueryPageViewer.<init>(QueryPageViewer.java:145) at org.hibernate.eclipse.console.views.QueryPageTabView.rebuild(QueryPageTabView.java:109) at org.hibernate.eclipse.console.views.QueryPageTabView.createPartControl(QueryPageTabView.java:151)
    No Bugmate found.