Multiple instances of Agent connected to a client [message #10707] |
Sun, 20 March 2005 06:45  |
Eclipse User |
|
|
|
Originally posted by: lars.nospam.nix_ohlenDOT.se
Hi,
I have created a HCE Agent using Java. The Agent produces CBEs (by
connecting to a network device and transform the log entries in to CBE)
All works well when one client uses one instance of the Agent.
But we have a need to monitor more that one network device at a time. But
this fails with my current configuration.
The effect (from what I can tell from the HCE daemon log) that the first
session (e.g. connection between client and my agent) drops when I starts
the second instance. It seams that my client code has some "singleton"
behavour and that only one instance can be active.
A couple of questions here:
* Is multi instance of the same agent connected from one client feasable. Is
what I'm trying to do possible?
* Any suggestions what to change in my code?
BR
Lars
|
|
|
|
|
Re: Multiple instances of Agent connected to a client [message #11577 is a reply to message #11540] |
Tue, 22 March 2005 07:28   |
Eclipse User |
|
|
|
Hi Lars,
Unfortunately, without seeing more of the client code, I do not know why
there is a reconnection. In theory, if an agent is null, the client code
should attach and starting the remote agent. The connection to the host or
node need only be established once. As such, adding a sleep or delay
certainly does not break any design constraint (other an a performance
degradation) but I question its necessity.
The Agent Controller is undergoing a major rewrite by the folks at Intel
for TPTP v4.0. As such, the architecture will change. The HLD
Specification for the Data Collection & Communication Component document
describes the new architecture.
In short, agents and clients are only tightly coupled after the client
is attached to an agent. The client may detach, which frees the agent to be
reattached or attached by another client. However, agents cannot be
associated with a particular client when not attached and one agent cannot
be attached and monitored by more than one client at one time.
Paul
"Lars Ohl
|
|
|
Re: Multiple instances of Agent connected to a client [message #11613 is a reply to message #11577] |
Tue, 22 March 2005 09:49   |
Eclipse User |
|
|
|
Originally posted by: lars._ohlen_nospm.se
Hi Paul,
Thanks for clearing things out. I will try and see if I can remove my sleep
statement, but I'm pretty sure that I did not
get any agent otherwise.
The client code sample I used as a base, was the code that you and Miguel
handed out during tutorial 22 @ eclipsecon.
So I guess that you had altered the code to make it as simple/informative as
possible. BTW your tutorial gave me
the TPTP start I needed. Next I will jump on the TPTP 4.0 train a.s.a.p
Lars
"Paul Slauenwhite" <paules@ca.ibm.com> wrote in message
news:d1p7o5$h1i$1@news.eclipse.org...
> Hi Lars,
> Unfortunately, without seeing more of the client code, I do not know
why
> there is a reconnection. In theory, if an agent is null, the client code
> should attach and starting the remote agent. The connection to the host
or
> node need only be established once. As such, adding a sleep or delay
> certainly does not break any design constraint (other an a performance
> degradation) but I question its necessity.
>
> The Agent Controller is undergoing a major rewrite by the folks at
Intel
> for TPTP v4.0. As such, the architecture will change. The HLD
> Specification for the Data Collection & Communication Component document
> describes the new architecture.
>
> In short, agents and clients are only tightly coupled after the client
> is attached to an agent. The client may detach, which frees the agent to
be
> reattached or attached by another client. However, agents cannot be
> associated with a particular client when not attached and one agent cannot
> be attached and monitored by more than one client at one time.
>
> Paul
>
> "Lars Ohl
|
|
|
Re: Multiple instances of Agent connected to a client [message #11648 is a reply to message #11540] |
Wed, 23 March 2005 19:44  |
Eclipse User |
|
|
|
We do intend for it to be possible to have multiple clients monitoring a
single agent when the new protocol is rolled out, but it will still be up to
the agent implementation to decide whether or not it wants to support that.
So if an agent wants to enable sharing, it can do that, but if it wants to
declare itself as unshareable, it can do that instead.
As you seem to have discovered, the lifecycle management described in the
HLD applies only to the new protocol implementation (and isn't implemented
even there yet). I don't believe the HCE gets involved in trying to control
the lifecycle in the 3.x releases.
-Andy
|
|
|
Powered by
FUDForum. Page generated in 0.03427 seconds