Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 313753

Summary: Facets don't work with 'custom workspace'
Product: [Technology] Tigerstripe Reporter: Steve Jerman <sjerman>
Component: HeadlessAssignee: Project Inbox <tigerstripe.core-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: erdillon, rcraddoc
Version: 0.5   
Target Milestone: 0.5M0   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:

Description Steve Jerman CLA 2010-05-20 11:47:12 EDT
If I run headless generation:

WS=/RandomApps/tychoTest/testModelWorkspace/xmp-im-foundation-module/target/ws
PROJECT=GENERATION_PROJECT=/RandomApps/tychoTest/testModelWorkspace/xmp-im-foundation-module

java -Xmx800m -XX:MaxPermSize=256m -XstartOnFirstThread  \
  -jar /Users/steve/.m2/repository/p2/osgi/bundle/org.eclipse.equinox.launcher/1.0.201.R35x_v20090715/org.eclipse.equinox.launcher-1.0.201.R35x_v20090715.jar \
  -os=macosx -ws=cocoa -arch=x86_64 \
-clean=true \
 -consolelog \
  -data $WS \
  -nosplash \
  -install /RandomApps/tychoTest/testModelWorkspace/ProjectOne/target/work \
  -configuration /RandomApps/tychoTest/testModelWorkspace/ProjectOne/target/work/configuration \
  -application org.eclipse.tigerstripe.workbench.headless.tigerstripe \
  $PROJECT

Generation works fine without a facet enabled. Get this error when they are enabled. Note the 'custom workspace'.

ava.lang.NullPointerException
	at org.eclipse.tigerstripe.workbench.internal.contract.segment.FacetReference.getTSProject(FacetReference.java:228)
	at org.eclipse.tigerstripe.workbench.internal.contract.segment.FacetReference.computeFacetPredicate(FacetReference.java:242)
	at org.eclipse.tigerstripe.workbench.internal.contract.segment.FacetReference.getFacetPredicate(FacetReference.java:279)
	at org.eclipse.tigerstripe.workbench.internal.core.model.ArtifactManager.setActiveFacet(ArtifactManager.java:2313)
	at org.eclipse.tigerstripe.workbench.internal.api.impl.ArtifactManagerSessionImpl.setActiveFacet(ArtifactManagerSessionImpl.java:550)
	at org.eclipse.tigerstripe.workbench.internal.api.impl.TigerstripeProjectHandle.setActiveFacet(TigerstripeProjectHandle.java:446)
	at org.eclipse.tigerstripe.workbench.internal.core.generation.M1Generator.internalRun(M1Generator.java:587)
	at org.eclipse.tigerstripe.workbench.internal.core.generation.M1Generator.run(M1Generator.java:378)
	at org.eclipse.tigerstripe.workbench.internal.core.generation.M1Generator.run(M1Generator.java:84)
	at org.eclipse.tigerstripe.workbench.internal.api.impl.TigerstripeProjectHandle.generate(TigerstripeProjectHandle.java:485)
	at org.eclipse.tigerstripe.workbench.headless.Tigerstripe.generateTigerstripeOutput(Tigerstripe.java:149)
	at org.eclipse.tigerstripe.workbench.headless.Tigerstripe.start(Tigerstripe.java:58)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
	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(EclipseStarter.java:368)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1311)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1287)
Comment 1 Eric Dillon CLA 2010-05-20 11:52:25 EDT
I ran into this when the parameters were incorrect.
It seems you're missing the name of the project behind "PROJECT"

WS=/RandomApps/tychoTest/testModelWorkspace/xmp-im-foundation-module/target/ws
PROJECT=/xmp-im-foundation-module GENERATION_PROJECT=/RandomApps/tychoTest/testModelWorkspace/xmp-im-foundation-module

could you try that.
Comment 2 Richard Craddock CLA 2010-06-10 09:02:07 EDT
This was nothing to do with the custom worksace, but InstalledModules.

Now fixed.