Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Null Pointer Exception occurs when Web Service Wizard is launched with a resource from Java Project
Null Pointer Exception occurs when Web Service Wizard is launched with a resource from Java Project [message #499150] Fri, 20 November 2009 07:28 Go to next message
Tilak Sharma is currently offline Tilak SharmaFriend
Messages: 48
Registered: July 2009
Member
Hi,

I have used the extension point "org.eclipse.jst.ws.consumption.ui.wsImpl" to configure my custom Web Service type which now lists on the Web Service Wizard as "Bottom Up MyCustom Web Service" and "Top Down MyCustom Web Service".

Then I used extension point "org.eclipse.jst.ws.consumption.ui.objectSelectionWidget" to provide my custom UI to select a resource from workspace.

Now If I select a resource from a Java Project, and click Next on the Web Service Wizard, a Null Pointer Exception is thrown and logged in the Error Log. However, I will be able to complete the wizard inspite of this error.


Below is the stack trace :
java.lang.NullPointerException
at org.eclipse.wst.common.componentcore.internal.operation.Crea teReferenceComponentsOp.validateEdit(CreateReferenceComponen tsOp.java:61)
at org.eclipse.wst.common.componentcore.internal.operation.Crea teReferenceComponentsOp.execute(CreateReferenceComponentsOp. java:47)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl$1.run(DataModelPausibleOperationImpl .java:376)
at org.eclipse.core.internal.resources.Workspace.run(Workspace. java:1800)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.runOperation(DataModelPausibleOperat ionImpl.java:401)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.runOperation(DataModelPausibleOperat ionImpl.java:352)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.doExecute(DataModelPausibleOperation Impl.java:242)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.executeImpl(DataModelPausibleOperati onImpl.java:214)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.cacheThreadAndContinue(DataModelPaus ibleOperationImpl.java:89)
at org.eclipse.wst.common.frameworks.internal.datamodel.DataMod elPausibleOperationImpl.execute(DataModelPausibleOperationIm pl.java:202)
at org.eclipse.jst.ws.internal.common.J2EEUtils.addJavaProjectA sUtilityJar(J2EEUtils.java:1633)
at org.eclipse.jst.ws.internal.creation.ui.extension.PreService DevelopCommand.execute(PreServiceDevelopCommand.java:212)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFr agmentEngine.runCommand(CommandFragmentEngine.java:419)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFr agmentEngine.visitTop(CommandFragmentEngine.java:359)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFr agmentEngine.moveForwardToNextStop(CommandFragmentEngine.jav a:254)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleComman dEngineManager$6.run(SimpleCommandEngineManager.java:294)
at org.eclipse.jface.operation.ModalContext.runInCurrentThread( ModalContext.java:464)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.ja va:372)
at org.eclipse.jface.wizard.WizardDialog.run(WizardDialog.java: 934)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleComman dEngineManager.runForwardToNextStop(SimpleCommandEngineManag er.java:264)
at org.eclipse.wst.command.internal.env.ui.widgets.WizardPageMa nager.runForwardToNextStop(WizardPageManager.java:91)
at org.eclipse.wst.command.internal.env.ui.widgets.WizardPageMa nager.getNextPage(WizardPageManager.java:154)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleWizard Page.getNextPage(SimpleWizardPage.java:136)
at org.eclipse.jface.wizard.WizardDialog.nextPressed(WizardDial og.java:813)
at org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDi alog.java:369)
at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.jav a:624)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListe ner.java:228)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3422)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:825 )
at org.eclipse.jface.window.Window.open(Window.java:801)
at org.eclipse.ui.internal.navigator.wizards.WizardShortcutActi on.run(WizardShortcutAction.java:94)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498 )
at org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:583)
at org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:500)
at org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3422)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:2384)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2348)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:22 00)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:495)
at org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:288)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:490)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:193)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:386)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)

Here from J2EEUtils.java:1633 null is passed explicitly : refdm.getDefaultOperation().execute(monitor, null);

Can this NPE be avoided or is this a bug in WTP?


Thanks,
Tilak
Re: Null Pointer Exception occurs when Web Service Wizard is launched with a resource from Java Proj [message #500890 is a reply to message #499150] Mon, 30 November 2009 06:27 Go to previous message
Tilak Sharma is currently offline Tilak SharmaFriend
Messages: 48
Registered: July 2009
Member
I have logged a bug in eclipse bugzilla https://bugs.eclipse.org/bugs/show_bug.cgi?id=296430 for this bug.

[Updated on: Mon, 30 November 2009 06:29]

Report message to a moderator

Previous Topic:wsdl:service and port name changed by eclipse
Next Topic:Cannot start Tomcat in Eclipse
Goto Forum:
  


Current Time: Sat Nov 22 18:05:15 GMT 2014

Powered by FUDForum. Page generated in 0.02415 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software