Foren

Liferay 7 service builder and OSGI

thumbnail
Andrey Filippov, geändert vor 8 Jahren.

Liferay 7 service builder and OSGI

Junior Member Beiträge: 27 Beitrittsdatum: 21.10.10 Neueste Beiträge
Hi!
I wonder Is there a possibility to use service builder for OSGI plugins? Is it possible to use Maven for it?

Thanks.
thumbnail
Devang Patel, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Regular Member Beiträge: 247 Beitrittsdatum: 19.01.15 Neueste Beiträge
Hi Andrey Filippov,
Here is your answer :

Thank You,
Devang Patel
thumbnail
David H Nebinger, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Liferay Legend Beiträge: 14917 Beitrittsdatum: 02.09.06 Neueste Beiträge
I don't think he's asking about OSGi services, I think he's asking about using SB in LR7.

Yes SB will endure in LR7, yes you will be able to use "mvn liferay:build-service" to invoke SB to build services.

OSGi is just the deployment container. When you push in your service jar and your service implementation, they'll be OSGi bundles and available to all other bundles as dependencies.
thumbnail
Andrey Filippov, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Junior Member Beiträge: 27 Beitrittsdatum: 21.10.10 Neueste Beiträge
Hi David,

Thanks for the answer. So technically it will be the same stuff like now - do "mvn liferay:build-service", then "mvn clean package" for service project to make *service.jar and then deploy this jar into hot deploy folder? Or I should make war file for the whole project and deploy it and Liferay will do all required to use services as OSGI plugin?
thumbnail
David H Nebinger, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Liferay Legend Beiträge: 14917 Beitrittsdatum: 02.09.06 Neueste Beiträge
Those are good questions, Andrey, but honestly I'm not sure.

I'm hopeful that I will be able to use SB to generate the layer that is OSGi-compatible and removes many of the class loader issues that we've faced in the past, although to think on it the service jar that you'd use as an external war would take a different form from the service jar bundle (since you don't need to worry about the class loader but you do need to get the references likely using a service tracker, ...).

I just don't know for sure if they're there yet...
thumbnail
Andrey Filippov, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Junior Member Beiträge: 27 Beitrittsdatum: 21.10.10 Neueste Beiträge
Thanks a lot! Waiting for the answers..
thumbnail
David H Nebinger, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Liferay Legend Beiträge: 14917 Beitrittsdatum: 02.09.06 Neueste Beiträge
You and me both, brother emoticon

For me, however, it's just to get up to speed on the coming 7 changes. Seems foolhardy to me for everyone to begin building for LR7 as though it's going into production the day after it's released.

I'm much more pragmatic, I'm going to wait for the first 7 GA to come out and give it some time cooking outside of production to make sure everything I have is compatible and there's no obvious bugs that are looming.
thumbnail
Ray Augé, geändert vor 8 Jahren.

RE: Liferay 7 service builder and OSGI

Liferay Legend Beiträge: 1197 Beitrittsdatum: 08.02.05 Neueste Beiträge
If you like you can help us to build out OSGi examples with the BLADE project that already contains SB using bndtools, gradle and maven.

https://github.com/rotty3000/blade

We're accepting Pull Requests from everyone!

Feel free to also join the public gitter channel for it here https://gitter.im/rotty3000/blade?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge

This is also a proving ground for many tools we are extracting from the traditional SDK into gradle and maven plugins of their own so you can assemble your project however you wish.

Cheers!