From: SourceForge.net <no...@so...> - 2009-09-24 14:47:31
|
Bugs item #2845128, was opened at 2009-08-26 14:07 Message generated for change (Settings changed) made by blaschke-oss You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=712784&aid=2845128&group_id=128809 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Java Client (JSR48) Group: Function Status: Open >Resolution: Fixed Priority: 5 Private: No Submitted By: Patrick Schaefer (psnotch) Assigned to: Dave Blaschke (blaschke-oss) Summary: CIMObjectPath.toString() misses host Initial Comment: During the data collection for SAN switches and SAN fabric we retrieve data with various Enumerate Instance calls and try to correlate the instances using the String representation of the COPs. After initial investigation it turned out that COPs for the same instance sometimes have the host information included in the String and sometimes not. example: CIM Enum gets list of CIMInstances of CIM_FCPort, then CIMInstance.getObjectPath().toString() returns following : (one example) /root/brocade1:Brocade_SwitchFCPort.CreationClassName="Brocade_SwitchFCPort",DeviceID="200500051E34EA73",SystemCreationClassName="Brocade_Switch",SystemName="100000051E34EA73" CIM enum gets list of CIMInstances of CIM_SystemDevice, then get key which datatype is CIMObjectPath, then toString(), returns //9.47.98.213/root/brocade1:Brocade_SwitchFCPort.CreationClassName="Brocade_SwitchFCPort",DeviceID="200500051E34EA73",SystemCreationClassName="Brocade_Switch",SystemName="100000051E34EA73" We don't see this with the previous CIM Client version. ---------------------------------------------------------------------- >Comment By: Dave Blaschke (blaschke-oss) Date: 2009-09-24 09:47 Message: Patch sent for community review. During a 2 week period any exploiter may comment on the patch, request changes or turn it down completely (with good reason). For the time being the patch is part of the "Experimental" branch in CVS. ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2009-09-24 08:58 Message: In this case I believe my original patch will do because a) the CIMOM is "at fault" here as it sometimes returns host and sometimes doesn't (which means we are not overlooking an error somewhere in the client) and b) toString() is documented to be used for debugging purposes only. ---------------------------------------------------------------------- Comment By: chrisreich (chrisreich) Date: 2009-09-23 04:49 Message: With CIM Client 1.x the COPs do not contain the host. I have no CIM trace right now, but I had a look at the CIM XML trace some time ago and there the host was sometimes included in the CIMOM response and sometimes not. ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2009-09-22 21:30 Message: Also, what was the behavior with CIM Client 1.x? Were all the COPs with or without the host? ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2009-09-22 10:41 Message: CIMObjectPath.toString() uses MOF.objectHandle() to obtain the string representation of the COP, and that method simply prints out the scheme, host and port IF AVAILABLE. In this case then it would seem that one COP has a valid host (9.47.98.213) while the other has a null host, so it would seem that the COPs were created in two different manners. There are three different ways to set the COP's host: 1) CIMObjectPath constructors with two or three parameters automatically create null host 2) CIMObjectPath constructors with four or more parameters have host as one of the parameters, but the user could pass in null 3) CIMObjectPath constructor with one parameter parses the object path string that may or may not contain host Do you have an XML trace to see what is being returned from the server in each of the example cases? I'd be interested to see if there is a difference, as I could not find where the client would drop a host (set it to null) if it exists. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=712784&aid=2845128&group_id=128809 |