celix icon indicating copy to clipboard operation
celix copied to clipboard

Prototype Service factory

Open pnoltes opened this issue 2 years ago • 2 comments

Prototype service factory

Add support for registering and using prototype service factories for C and C++. Also add support registering and using bundle service factories for C++.

Background

Chapter 5.9 "Service Factory" of the OSGi 8 spec mentions 3 types of scoped service objects:

  • singleton: A normal service
  • bundle: Create service instance per requesting bundle
  • prototype; Create service instance per request

Apache Celix currently only supports the singleton scoped services and bundle scoped service factory (note that OSGi spec 5 only has a bundle scoped service factory).

pnoltes avatar Aug 23 '23 14:08 pnoltes

I just noticed that C++ version of per bundle service factory is not implemented. Recently one user requiring it (as described by #766) is forced to use the SOD pattern, since he does not want to use C interface.

PengZheng avatar Aug 02 '24 10:08 PengZheng

I just noticed that C++ version of per bundle service factory is not implemented.

I'm planning to pick up this issue after completing the removal of the deprecated utils and framework APIs. However, if this issue needs to be addressed sooner, please feel free to assign it to someone else.

pnoltes avatar Aug 03 '24 09:08 pnoltes