Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » [OSGi services] Connection configurations as services with a Connection Service consuming them
[OSGi services] Connection configurations as services with a Connection Service consuming them [message #105963] Fri, 07 March 2008 12:46
Philipp Kursawe is currently offline Philipp KursaweFriend
Messages: 135
Registered: July 2009
Senior Member

I need a Connection Provider Service to be present in the system and
users of this connection should just be able to use the currently active
one to interact with it. For instance one could register a
"ConnectionUser" service that will be injected the currently active
Connection to work with by Dependency Injection.

So inspired by ApplicationDescription services I thought about
registering 0..n Connection Configuration Services (that can be altered
in the UI or console) and the following to happen:
1. If there is no Connection Provider Service registered yet, a new one
is created and injected to all registered ConnectionUser by calling
2. If an existing Connection Configuration is changed and its the one
that is currently providing configuration for the active Connection
Provider than the provider disconnects and reconnects with the new settings.
3. If the currently existing providers configuration is removed from the
system the Provider is also removed.
4. A new provider is created by activating a Connection Configuration,
the old one is discarded.

Is this design any good or has it flaws?
I am not sure yet, how I could change the Connection Configuration after
the service is registered (its the properties of the service), since I
do not have access to the registered Services initial Properties.

Any thoughts?
Previous Topic:OSGi ManagedServiceFactory understanding
Next Topic:Jetty on Multiple Ports
Goto Forum:

Current Time: Sun Oct 24 19:32:36 GMT 2021

Powered by FUDForum. Page generated in 0.01195 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top