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

Bug 365699

Summary: Allow registering services in OSGi runtime from Maven
Product: z_Archived Reporter: Tobias Oberlies <t-oberlies>
Component: TychoAssignee: Jan Sievers <jan.sievers>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Tobias Oberlies CLA 2011-12-06 05:27:07 EST
It shall be possible to register services in Tycho's embedded Equinox runtime which are implemented in the Maven world.

Although this has already been done as part of bug 365012 (see commit 7f78257), I think that this deserves its own bug number.

Example: The FileLockService is needed both in Maven and OSGi. Additionally, it is needed before the embedded Equinox is started. Therefore it must be implemented on the Maven side. With this 
enhancement, it is possible to obtain the same implementation also as OSGi service in the OSGi runtime.
Comment 1 Tobias Oberlies CLA 2011-12-06 05:43:43 EST
As already mentioned, this has been implemented by Jan in commit 7f78257 [1].

I've done a small modification to this [2] to only allow the registration of services in EquinoxLifecycleListeners. Until we really need it differently, I would make the services registered from Maven non-dynamic.

[1] http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/commit/?id=7f78257fff8602f8d124e8336fdbb9df1a24fd29
[2] http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/commit/?id=713962c047eb048223d711c62bdb418931172890