Fórum

Build-Service NullPointer Exception issue

Vasilios Kaloidis, modificado 7 Anos atrás.

Build-Service NullPointer Exception issue

New Member Postagens: 11 Data de Entrada: 18/07/16 Postagens Recentes
Hello,

I recently switched my Eclipse workspace from a folder in my Documents to my portlet folder. I had to do this because I started using Eclipse SVN plugin and had to checkout files directly to the portlet folder, rather than a folder in my Documents.

Not sure if my workspace switch is related - but I am getting a Null Pointer error throw whenever I try to build-service on any project. I cleared out all my old LR generated service files, went over my liferay project files (liferay-display.xml, hook.xml, package.properties, lr-portlet.xml, portlet.xml and ofcourse service.xml) with a fine-tooth comb, and I have come to the conclusion that my issue is not coming from within my project. Plus this error happens when I attempt to build services in other projects that build fine on other computers.

I also tried deleting my SDK folder, unzipping a fresh one, and moving my build-props file and portlets folder over. This did not fix the issue. I re-added my liferay-sdk in eclipse also.

Here is the stack trace that comes with the error when I attempt to build-service:

An internal error occurred during: "Build services".
java.lang.NullPointerException
at com.liferay.ide.project.core.LiferayPluginsSDKProject.getSDK(LiferayPluginsSDKProject.java:171)
at com.liferay.ide.project.core.LiferayPluginsSDKProject.adapt(LiferayPluginsSDKProject.java:63)
at com.liferay.ide.service.core.job.BuildServiceJob.getProjectBuilder(BuildServiceJob.java:68)
at com.liferay.ide.service.core.job.BuildServiceJob.runBuild(BuildServiceJob.java:119)
at com.liferay.ide.service.core.job.BuildServiceJob$1.run(BuildServiceJob.java:101)
at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2313)
at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2295)
at com.liferay.ide.service.core.job.BuildServiceJob.run(BuildServiceJob.java:107)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

Also, here is my service.xml just incase - http://pastebin.com/2afsZQkL

Thanks in advance - the support I get in the forum is great.