|
View:
New views
8 Messages
—
Rating Filter:
Alert me
|
|
|
How to construct the Resource URI when i have my own CIM classHello All
I am a beginner in openWSMAN. I would like to know, how to construct the Resource URI when i have my own CIM class. I have extended the CIM_ComputerSystem to create my own class, called TEST_ComputerSystem. I have also written the CMPI provider for my TEST_ComputerSystem Class. When I enumerate instances of my class through wsman by giving, wsman enumerate http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/TEST_ComputerSystem i get the error saying, <?xml version="1.0" encoding="UTF-8"?> <s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsman="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <s:Header> <wsa:To>http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</wsa:To> <wsa:Action>http://schemas.xmlsoap.org/ws/2004/08/addressing/fault</wsa:Action> <wsa:RelatesTo>uuid:ca8d5577-4c38-1c38-8002-ccb62ea01a00</wsa:RelatesTo> <wsa:MessageID>uuid:ca8d6bf1-4c38-1c38-8018-ccb62ea01a00</wsa:MessageID> </s:Header> <s:Body> <s:Fault> <s:Code> <s:Value>s:Sender</s:Value> <s:Subcode> <s:Value>wsa:DestinationUnreachable</s:Value> </s:Subcode> </s:Code> <s:Reason> <s:Text xml:lang="en">No route can be determined to reach the destination role defined by the WS-Addressing To.</s:Text> </s:Reason> <s:Detail> <wsman:FaultDetail>http://schemas.dmtf.org/wbem/wsman/1/wsman/faultDetail/InvalidResourceURI</wsman:FaultDetail> </s:Detail> </s:Fault> </s:Body> </s:Envelope> Connection failed. response code = 400 But when i use the filter option, like wsman enumerate http://schemas.dmtf.org/wbem/wscim/1/* --filter "select * from TEST_ComputerSystem" i could able to get the result. My question here is, for my own defined class, how do i get my instance with out using the --filter option. How should i construct my resource URI? Thanks Sundarlal |
|
|
Re: How to construct the Resource URI when i have my own CIM class* mhsundar <mhsundar@...> [May 02. 2008 07:51]:
> > wsman enumerate > http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/TEST_ComputerSystem The URI prefix (http://schemas.dmtf.org) is for the CIM base classes. So it doesn't match your own class. > > But when i use the filter option, like > > wsman enumerate http://schemas.dmtf.org/wbem/wscim/1/* --filter "select * > from TEST_ComputerSystem" Here you're enumerating all CIM base classes _and_ its derivates. Hence you also get your class (derived from CIM_ComputerSystem) > > i could able to get the result. > > > My question here is, for my own defined class, how do i get my instance with > out using the --filter option. How should i construct my resource URI? You have to register your own namespace as "vendor_namespaces" in /etc/openwsman/openwsman.conf using the class prefix. So add something like TEST=http://mhsundar.gmail.com/my/test to the "vendor_namespaces=" line and then call wsman with wsman enumerate http://mhsundar.gmail.com/TEST_ComputerSystem Klaus --- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ Openwsman-devel mailing list Openwsman-devel@... https://lists.sourceforge.net/lists/listinfo/openwsman-devel |
|
|
Re: How to construct the Resource URI when i have my own CIM classThanks a lot Mr. Klaus. Now i could understand the issue.
But how do i define my namespace?. > You have to register your own namespace as "vendor_namespaces" in > /etc/openwsman/openwsman.conf using the class prefix. > So add something like > TEST=http://mhsundar.gmail.com/my/test > to the "vendor_namespaces=" line and then call wsman with > wsman enumerate http://mhsundar.gmail.com/TEST_ComputerSystem I have a CIMOM server running on my localhost and i have created a namespace called "root/test". So in this case, will my vendor namespace be "http://localhost/root/test"? Can u please clarify? Thanks Sundarlal Klaus --- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ Openwsman-devel mailing list Openwsman-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openwsman-devel |
|
|
Re: How to construct the Resource URI when i have my own CIM class* mhsundar <mhsundar@...> [May 02. 2008 15:29]:
> > Thanks a lot Mr. Klaus. Now i could understand the issue. > > But how do i define my namespace?. For openwsman, its just a URL. I am not aware of any other rules or limitations. You might want to look at the namespaces listed as vendor_namespaces in openwsman.conf, most of them have digits in their path denoting a specific version. That's probably most useful. > > > You have to register your own namespace as "vendor_namespaces" in > > /etc/openwsman/openwsman.conf using the class prefix. > > So add something like > > TEST=http://mhsundar.gmail.com/my/test > > to the "vendor_namespaces=" line and then call wsman with > > > wsman enumerate http://mhsundar.gmail.com/TEST_ComputerSystem > > I have a CIMOM server running on my localhost and i have created a namespace > called "root/test". So in this case, will my vendor namespace be > "http://localhost/root/test"? Be careful not to mix wsman namespaces with CIM class namespaces. Wsman namespaces look like a URL (http://....) while CIM namespaces look like a path (foo/bar). Klaus ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ Openwsman-devel mailing list Openwsman-devel@... https://lists.sourceforge.net/lists/listinfo/openwsman-devel |
|
|
Re: How to construct the Resource URI when i have my own CIM classI am also encountering this issue and hoping to get a little more clarification. In your example you used : http://mhsundar.gmail.com/my/test, but how do we know what to put after the http://. I am still just unsure of how to construct the actual URL.
|
|
|
Re: How to construct the Resource URI when i have my own CIM classIf I remember things correctly, the resource URL passed to openwsman is divided into two parts actually. The first part is what we define in "vendor_namespaces" section and the other is CIM class name. For example, if we define "TEST=http://mhsundar.gmail.com/my/test" in "vendor_namespaces" section, "http://mhsundar.gmail.com/my/test/TEST_ComputerSystem" is a valid URL and "http://mhsundar.gmail.com/my/test/Linux_ComputerSystem" is not. That is to say, if you want to make your CIM class names recognized in openwsman, register the prefixes of the CIM class name with their corresponding URLs. Liang icole wrote: I am also encountering this issue and hoping to get a little more clarification. In your example you used : http://mhsundar.gmail.com/my/test, but how do we know what to put after the http://. I am still just unsure of how to construct the actual URL. Klaus Kaempf wrote:* mhsundar mhsundar@... [May 02. 2008 15:29]: ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ Openwsman-devel mailing list Openwsman-devel@... https://lists.sourceforge.net/lists/listinfo/openwsman-devel |
|
|
Re: How to construct the Resource URI when i have my own CIM classIf we have a custom provider how do we determine the vendor_namespace then? Thanks for the help
-Ian
|
|
|
Re: How to construct the Resource URI when i have my own CIM classI think it depends on you. Anything unique is OK, although it is often
some kind of vendor URL. Liang icole wrote: > If we have a custom provider how do we determine the vendor_namespace then? > Thanks for the help > > -Ian > > > > Hou,Liang wrote: > >> >> >> >> >> >> >> >> If I remember things correctly, the resource URL passed to openwsman is >> divided into two parts actually. The first part is what we define in >> "vendor_namespaces" section and the other is CIM class name. >> For example, if we define "TEST= http://mhsundar.gmail.com/my/test " in >> "vendor_namespaces" section, >> "http://mhsundar.gmail.com/my/test/TEST_ComputerSystem" is a valid URL >> and "http://mhsundar.gmail.com/my/test/Linux_ComputerSystem" is not. >> That is to say, if you want to make your CIM class names recognized in >> openwsman, register the prefixes of the CIM class name with their >> corresponding URLs. >> >> Liang >> >> >> icole wrote: >> >> I am also encountering this issue and hoping to get a little more >> clarification. In your example you used : >> http://mhsundar.gmail.com/my/test , >> but how do we know what to put after the http:// . I am still just unsure >> of >> how to construct the actual URL. >> >> >> >> Klaus Kaempf wrote: >> >> >> * mhsundar <mhsundar@...> [May 02. 2008 15:29]: >> >> >> Thanks a lot Mr. Klaus. Now i could understand the issue. >> >> But how do i define my namespace?. >> >> >> For openwsman, its just a URL. I am not aware of any other rules or >> limitations. >> You might want to look at the namespaces listed as vendor_namespaces >> in openwsman.conf, most of them have digits in their path denoting a >> specific version. That's probably most useful. >> >> >> >> >> You have to register your own namespace as "vendor_namespaces" in >> /etc/openwsman/openwsman.conf using the class prefix. >> So add something like >> TEST= http://mhsundar.gmail.com/my/test >> to the "vendor_namespaces=" line and then call wsman with >> >> >> >> wsman enumerate http://mhsundar.gmail.com/TEST_ComputerSystem >> >> >> I have a CIMOM server running on my localhost and i have created a >> namespace >> called "root/test". So in this case, will my vendor namespace be >> "http://localhost/root/test" ? >> >> >> Be careful not to mix wsman namespaces with CIM class namespaces. >> Wsman namespaces look like a URL ( http:// ....) while CIM namespaces >> look like a path (foo/bar). >> >> Klaus >> >> ------------------------------------------------------------------------- >> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference >> Don't miss this year's exciting event. There's still time to save $100. >> Use priority code J8TL2D2. >> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone >> _______________________________________________ >> Openwsman-devel mailing list >> Openwsman-devel@... >> https://lists.sourceforge.net/lists/listinfo/openwsman-devel >> >> >> >> >> >> >> >> >> >> >> >> >> ------------------------------------------------------------------------- >> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! >> Studies have shown that voting for your favorite open source project, >> along with a healthy diet, reduces your potential for chronic lameness >> and boredom. Vote Now at http://www.sourceforge.net/community/cca08 >> _______________________________________________ >> Openwsman-devel mailing list >> Openwsman-devel@... >> https://lists.sourceforge.net/lists/listinfo/openwsman-devel >> >> >> > > ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ Openwsman-devel mailing list Openwsman-devel@... https://lists.sourceforge.net/lists/listinfo/openwsman-devel |
| Free Forum Powered by Nabble | Forum Help |