cayenne-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrus Adamchik <>
Subject Re: Cayenne under OSGi
Date Thu, 14 Nov 2013 14:56:17 GMT
So thanks to Cristiano pinging me offline, I spent some time on reviewing this again. I think
we need to take the following steps to integrate Abodata’s OSGi code (or follow it as a
pattern when we write ours) :

1. Reorg Cayenne Maven structure, making cayenne-server and cayenne-client real Maven modules
instead of aggregates. We’ve discussed this a few times, and IIRC I was the only one who
opposed it :) I no longer do. We can use <optional> and “provided” dependencies
to exclude the extras like JGroups and keep it clean.

2. We need to add OSGi metadata to cayenne-server (and other Cayenne jars in the chain…
likely just cayenne-di).

3. We need to create OsgiServerModule with an overridden AdhocObjectFactory. This will implement
refactored ClassRegistry and will load all model classes per this example:

4. We may (or may not?) put those few OSGi classes in a separate cayenne-server-osgi module
(to avoid dependency on OSGi framework in the base cayenne-server).

I placed #1 in my work stack (and really hope something else doesn’t pop up that pushes
it down :-/ ) I don’t think Cristiano can create sensible patches against trunk without
it. After this is done, we can discuss whether me or Cristiano can do 2..4.


On Jan 31, 2013, at 3:42 PM, Cristiano Ghersi <> wrote:
> Good morning,
> My company (Abodata, has ported Cayenne into OSGi
> environment, and we would like to contribute to Cayenne project with this
> enhancement as I posted under user mailing list on October 2012.
> Following your instructions, we have uploaded the full content under the
> github repo:
> Basically, we have packaged the source code of 3.1 version into an OSGi
> bundle called cayenne-osgi, adding some stuff to manage the particular
> classloading features of OSGi.
> Then we added also another bundle, called Cayenne-3.1-Dependencies, that
> packages all the required dependencies.
> I'm at complete disposal for every clarification you need.
> I'll wait for your feedback.
> Best
> cghersi

View raw message