-
Bug
-
Resolution: Done
-
Major
-
4.3.0.Alpha2
-
None
-
- Add configuration to workspace
- Try to open the database node
- NullPointerException
While receiving a schema from Database initially a java.lang.NullPointerException* is thrown.
Stack trace can be found here.
While debugging the plugin i found the problem at the implementation of the anonymous comperator in org.hibernate.eclipse.console.workbench.LazyDatabaseSchemaWorkbenchAdapter.getChildren(Object, IProgressMonitor).
res = toArray(result.iterator(), Object.class, new Comparator<Object>() { public int compare(Object arg0, Object arg1) { return getName(arg0).compareTo(getName(arg1)); } private String getName(Object o) { String result = null; try { Method m = o.getClass().getMethod("getName", new Class[] {}); m.invoke(o, new Object[] {}); } catch (Exception e) { throw new RuntimeException(e); } return result; } });
The string result is never set. So the compareTo is always failing.
I haven't looked it up, but the problem might consist also in earlier versions of JBoss tools.