Automatically set IP address in a declarative service (ideas or best practices?) [message #658448] |
Tue, 08 March 2011 14:58 |
Pablo Mising name Messages: 24 Registered: July 2010 |
Junior Member |
|
|
Hi all.
I am doing research about distributed and service-oriented algorithms in clusters and heterogeneous networks, and I would like to use OSGi and ECF in my thesis.
Due to I want to do research in P2P topographies (that is, not all-to-all connections), I would like to deploy ECF in several nodes of a cluster and doing the services bindings manually (or semi-automatic). For example, bundle A in Node A requires service B from Node B and service C from node C and B.
So, the idea is to expose all service hosts in DS way and bind manually or also in a declarative way, but I have several doubts:
- The first one is about setting "org.eclipse.ecf.containerFactoryArgs" in each service to expose. In DS you can set it in the xml description file, but, this URL will be different in each node, so I should change in every xml in every node? Or I could access to ComponentContext properties and set the ip in the activate() method of the component? (reading this URL from command line or whatever). Is this a good programming practice?
- My second doubt is related to the first: how can I execute the activate() method of a componet before being used or bound by a consumer? I think that this is possible, but I don't know how to do it.
- My final doubt is how to say to each node which service of what node must chose. I've thought in using filters of the service registry. filtering by IPs and other properties, but also I want to know wich is the best programming practice to do it. Maybe I should investigate Zookeeper?
Or maybe should I wait until Remote Services Admin (RSA) becomes available along this month? Perhaps it could be the solution to all my problems : )
Thanks in advance.
EDIT: Agh, I did not remember that Scott Lewis answered me several months ago in another thread. It includes useful information to take into account. Sorry about duplication of threads.
[Updated on: Tue, 08 March 2011 15:11] Report message to a moderator
|
|
|
Re: Automatically set IP address in a declarative service (ideas or best practices?) [message #658909 is a reply to message #658448] |
Thu, 10 March 2011 12:20 |
Markus Kuppe Messages: 177 Registered: July 2009 |
Senior Member |
|
|
On 03/08/2011 03:58 PM, Pablo wrote:
> Hi all.
> I am doing research about distributed and service-oriented algorithms in
> clusters and heterogeneous networks, and I would like to use OSGi and
> ECF in my thesis.
>
> Due to I want to do research in P2P topographies (that is, not
> all-to-all connections), I would like to deploy ECF in several nodes of
> a cluster and doing the services bindings manually (or semi-automatic).
> For example, bundle A in Node A requires service B from Node B and
> service C from node C and B.
>
> So, the idea is to expose all service hosts in DS way and bind manually
> or also in a declarative way, but I have several doubts:
>
> - The first one is about setting "org.eclipse.ecf.containerFactoryArgs"
> in each service to expose. In DS you can set it in the xml description
> file, but, this IP will be different in each node, so I should change in
> every xml in every node? Or I could access to ComponentContext
> properties and set the ip in the activate() method of the component?
> (reading this IP from command line or whatever). Is this a good
> programming practice?
>
> - My second doubt is related to the first: how can I execute the
> activate() method of a componet before being used or bound by a
> consumer? I think that this is possible, but I don't know how to do it.
>
> - My final doubt is how to say to each node which service of what node
> must chose. I've thought in using filters of the service registry.
> filtering by IPs and other properties, but also I want to know wich is
> the best programming practice to do it. Maybe I should investigate
> Zookeeper?
>
> Or maybe should I wait until Remote Services Admin (RSA) becomes
> available along this month? Perhaps it could be the solution to all my
> problems : )
>
> Thanks in advance.
Hi Pablo,
you might want to move this thread over to the ecf-dev mailinglist [0].
Not many devs read the newsgroup.
Markus
[0] https://dev.eclipse.org/mailman/listinfo/ecf-dev
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04132 seconds