[INFRAUTILS-37] diagstatus CLI should not to use JMX to obtain information from local node to avoid ConnectException on 127.0.0.1 Created: 02/May/18  Updated: 24/Aug/18  Resolved: 29/May/18

Status: Resolved
Project: infrautils
Component/s: diagstatus
Affects Version/s: None
Fix Version/s: Fluorine

Type: Bug Priority: High
Reporter: Michael Vorburger Assignee: Michael Vorburger
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

INFRAUTILS-36 made me look more into the code in DiagStatusCommand, and I don't understand why on earth it uses JMX to call LOCAL code? I get the point of that code to get diagstatus from remote cluster members, but to query the local diagstatus, that seems... weird - we can, easily, just call the local service!

I'll raise a change proposing this.



 Comments   
Comment by Faseela K [ 02/May/18 ]

The RMI Connector will not be involved, when DiagStatusCommand detects that 127.0.0.1 is self-address. So we should debug why 127.0.0.1 is not coming as self-address. If is it not coming, the proposed patch from Michael also will not solve the problem.

Comment by Michael Vorburger [ 02/May/18 ]

This really (now, with the new log) is a functional Bug and no longer just a technical Enhancement idea.

Comment by Michael Vorburger [ 02/May/18 ]

No, I got totally confused... as discussed on c/71662, my proposed technical enhancement will NOT fix the problem jluhrsen hit, because it does not do away with this code path - NB getRemoteStatusSummary() VS getLocalStatusSummary(). To avoid confusing others further, I propose that we keep this issue for the technical enhancement, and track the actual functional bug under a new INFRAUTILS-38. I'll delete my previous comment above with the stack trace to avoid future confusion of this issue with the new INFRAUTILS-38.

Comment by Jamo Luhrsen [ 02/May/18 ]

I am not sure which Jira to comment on, this or INFRAUTILS-38 but something I just learned.

in my patch where I'm trying to do the status.getErrorCause().get() I will hit this problem
where I get:

Status retrieval JMX Operation failed for node 127.0.0.1

Ignoring the trace for now.

NOTE: this is all manually and locally.

When I remove that .get(), the problem goes away, so I'll get this:

karaf@root()> showsvcstatus
Timestamp: Wed May 02 11:14:19 PDT 2018
Node IP Address: 127.0.0.1
System is operational: true
System ready state: ACTIVE
  OPENFLOW            : OPERATIONAL       Optional.empty
karaf@root()>

So, maybe we can keep this INFRAUTILS-37 as this specific issue and figure that out. However, the
other problem we can track in INFRAUTILS-38 is maybe related, but also not because of the .get()
issue. That is running a distro that does not have that change. I'll comment more in that jira.

Comment by Jamo Luhrsen [ 02/May/18 ]

ok, so we can let this jira stay to track the work vorburger is doing in 71662. I did cherry pick
it locally to double check that it does not help me get past INFRAUTILS-36, so we still need that to
chase down. I'll update that jira too.

Generated at Wed Feb 07 20:02:06 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.