Hello,

I'm trying to migrate a custom provider interface to register OSGi services.

This is a pre existing implementation, functionally similar to Java's SPI, with one caveat; it doesn't use a zero arg constructor.

The constructor has two arguments an array of strings, and a ClassLoader.

Otherwise for all intents and purposes, it's an SPI, implementing services use a META-INF services file.

The interface for the service exists and has implementations.

The ClassLoader passed in is used to resolve classes from the service client.

It doesn't use the Java SPI mechanism, so we have access to the code that creates the service.

Each client will require a different Service instance.

I was thinking something like a Service Factory might do the job, any thoughts or advice?

Thanks in adv,

Peter.
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to