0 Replies Latest reply on Aug 1, 2017 7:05 AM by Marco Ferrari

    NPE when importing JDBC Database

    Marco Ferrari Newbie

      Hi all.

       

      Starting from a clean workspace I created a new project and I added a two new connection profiles (for Oracle and H2 dbs). Both pings are ok.

       

      When I try to import a new JDBC Database, I have the following issues:

      • Sometimes (not always) I get an NPE when selecting the connection profile

      !SESSION 2017-08-01 10:33:33.707 -----------------------------------------------

      eclipse.buildId=10.4.0.GA-v20170511-1748-B62

      java.version=1.8.0_131

      java.vendor=Oracle Corporation

      BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US

      Framework arguments:  -product com.jboss.devstudio.core.product

      Command-line arguments:  -os linux -ws gtk -arch x86_64 -product com.jboss.devstudio.core.product

       

       

      !ENTRY org.eclipse.ui 4 0 2017-08-01 10:34:08.346

      !MESSAGE Unhandled event loop exception

      !STACK 0

      java.lang.NullPointerException

      at org.teiid.designer.jdbc.JdbcManagerImpl.getJdbcSource(JdbcManagerImpl.java:336)

      at org.teiid.designer.jdbc.JdbcManagerImpl.getJdbcSources(JdbcManagerImpl.java:359)

      at org.teiid.designer.jdbc.ui.wizards.JdbcSourceSelectionPage.createControl(JdbcSourceSelectionPage.java:233)

      at org.teiid.designer.ui.common.wizard.AbstractWizard.createPageControls(AbstractWizard.java:153)

      at org.teiid.designer.ui.common.wizard.AbstractWizard.createPageControls(AbstractWizard.java:138)

      at org.teiid.designer.jdbc.ui.wizards.JdbcImportWizard.createPageControls(JdbcImportWizard.java:251)

      at org.eclipse.jface.wizard.WizardDialog.createPageControls(WizardDialog.java:696)

      at org.eclipse.jface.wizard.WizardDialog.setWizard(WizardDialog.java:1144)

      at org.eclipse.jface.wizard.WizardDialog.updateForPage(WizardDialog.java:1197)

      at org.eclipse.jface.wizard.WizardDialog.lambda$2(WizardDialog.java:1185)

      at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)

      at org.eclipse.jface.wizard.WizardDialog.showPage(WizardDialog.java:1185)

      at org.eclipse.jface.wizard.WizardDialog.nextPressed(WizardDialog.java:876)

      at org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:419)

      at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:618)

      at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:249)

      at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)

      at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5227)

      at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1340)

      at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4561)

      at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4151)

      at org.eclipse.jface.window.Window.runEventLoop(Window.java:818)

      at org.eclipse.jface.window.Window.open(Window.java:794)

      at org.eclipse.ui.internal.handlers.WizardHandler$Import.executeHandler(WizardHandler.java:158)

      at org.eclipse.ui.internal.handlers.WizardHandler.execute(WizardHandler.java:290)

      at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:295)

      at org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:90)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

      at java.lang.reflect.Method.invoke(Method.java:498)

      at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:55)

      at org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:282)

      at org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:264)

      at org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:132)

      at org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:152)

      at org.eclipse.core.commands.Command.executeWithChecks(Command.java:494)

      at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:488)

      at org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:210)

      at org.eclipse.ui.internal.handlers.LegacyHandlerService.executeCommand(LegacyHandlerService.java:353)

      at org.eclipse.ui.internal.actions.CommandAction.runWithEvent(CommandAction.java:155)

      at org.eclipse.ui.internal.actions.CommandAction.run(CommandAction.java:165)

      at org.eclipse.ui.actions.ImportResourcesAction.run(ImportResourcesAction.java:99)

      at org.eclipse.ui.actions.BaseSelectionListenerAction.runWithEvent(BaseSelectionListenerAction.java:167)

      at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:565)

      at org.eclipse.jface.action.ActionContributionItem.lambda$4(ActionContributionItem.java:397)

      at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)

      at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5227)

      at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1340)

      at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4561)

      at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4151)

      at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1121)

      at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)

      at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1022)

      at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:150)

      at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:693)

      at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)

      at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:610)

      at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)

      at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:138)

      at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)

      at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)

      at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)

      at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)

      at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

      at java.lang.reflect.Method.invoke(Method.java:498)

      at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)

      at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)

      at org.eclipse.equinox.launcher.Main.run(Main.java:1519)

      at org.eclipse.equinox.launcher.Main.main(Main.java:1492)

      • If I don't get the NPE, I am not able to select the newly created connection profile on the first try. I have to run the wizard multiple times after restarting Eclipse (I am using JBoss Development Studio)

       

      Environment:

      Ubuntu 17.04 x64

       

      Eclipse details:

        Red Hat JBoss Developer Studio (Branded Product) 10.4.0.GA-v20170511-1748-B62 com.jboss.devstudio.core.package null

        Teiid DataTools Connectivity 11.0.1.Final-v20170208-2046-B4143 org.teiid.datatools.connectivity.feature.feature.group JBoss by Red Hat

        Teiid Designer 11.0.1.Final-v20170208-2046-B4143 org.teiid.designer.feature.feature.group JBoss by Red Hat

        Teiid Designer Runtime 11.0.1.Final-v20170208-2046-B4143 org.teiid.designer.runtime.feature.feature.group JBoss by Red Hat

        Teiid Runtime Clients 11.0.1.Final-v20170208-2046-B4143 org.teiid.designer.teiid.client.feature.feature.group JBoss by Red Hat

        TestNG 6.11.0.201703011520 org.testng.eclipse.feature.group Cedric Beust

        WST Common Core (Patch for BZ 511793) 3.8.3.v201704191843 org.eclipse.wst.common_core_EBZ511793.feature.patch.feature.group JBoss by Red Hat

       

      THANKS!