Home » Archived » COSMOS » Developing a Custom MDR - Posting on behalf of "Pathuri, Hanu"
|Developing a Custom MDR - Posting on behalf of "Pathuri, Hanu" [message #10356]
||Thu, 01 May 2008 15:18
| No real name
Registered: July 2009
a) IItemConstraintHandler is a generic interface used for all constraints
associated with item templates (e.g. instance id handler, record type
handler, and etc...). If you look at
you'll notice that it extends AbstractItemConstraintHandler, which
b) That depends on the type of constraints your MDR will support.
To support item templates you need to implement: IItemTemplateHandler (or
optionally extend AbstractItemTemplateHandler)
For each item constraints (i.e. Instance id, record type, property value,
and XPath), you need to implement IItemConstraintHandler (or optionally
To support relationship templates you need to implement:
For each relationship constraint (i.e. Instance id, record type, property
value, and XPath), you need to implement IRelationshipConstraintHandler (or
optionally extend AbstractRelationshipConstraintHandler)
c) The default implementation of the CMDBf query engine, invokes
IRelationshipTemplateHandler.execute(...) for each item in the source and
target item template. If there are multiple relationships, then you're
template handlers will be invoked multiple times based on the entries of the
source and target item templates.
> Is there any way to extend the example to cover most traversed paths to
> help newbies like myself?
In most cases, yes.
> Based on my assessment, we can reuse
> org.eclipse.cosmos.dc.cmdbf.services.query.service.impl and the following
> classes in org.eclipse.cosmos.samples.cmdbf.services.query
> a) We need to write classes similar to the classes mentioned in this
> b) We need to add another class ItemConstraintHandler.java
Ideally you want to reuse as much code as possible under the plug-in:
org.eclipse.cosmos.dc.cmdbf.services and make your MDR based on a revision
I'm posting this e-mail thread to the newsgroup so it can benefit others.
To learn how to access COSMOS newsgroup, click on the 'newsgroup' link from
COSMOS main web page. We can continue the discussion from there.
Thanks and good luck,
Overall, we are very impressed with COSMOS initiative and commitment of this
Thanks for the prompt and detailed response.
I have the following questions:
a) There seem to be no sample code for implementing IItemConstraintHandler
in the Sample Query Service. Is there sample code that we can look at?
b) What are the generic interfaces that all our Domain Objects must
By looking at the code, it appears that if Our Domain Objects implement
IItemConvertible, IXMLWritable, would the framework automatically take care
c) It is unclear how to implement RelationShipTemplate in a generic way? For
instance, if we have to support multiple relationships, how does the code
Is there any way to extend the example to cover most traversed paths to help
newbies like myself?
I am beginning to figure out exposing our proprietary data in such a way
that it can be adopted easily into COSMOS framework.
Based on my assessment, we can reuse
org.eclipse.cosmos.dc.cmdbf.services.query.service.impl and the following
classes in org.eclipse.cosmos.samples.cmdbf.services.query
a) We need to write classes similar to the classes mentioned in this package
b) We need to add another class ItemConstraintHandler.java
We would greatly appreciate any guidance on this regard.
Thanks in advance,
Here are a few recommendations:
1) If you're not already familiar with CMDBf, you can read the standard
2) Even though the following document is a bit outdated, it still will gives
you a good overview of the CMDBf framework:
This document will describe how you can use COSMOS' APIs to provide CMDBf
services (i.e. query/registration).
3) In i10 we transitioned from the OSGi platform to web services. An MDR in
i10 is a web service running on the Axis2 engine. The student/teacher
sample is your best point of reference to determine how all pieces of COSMOS
works. The sample is composed of two parts:
a) The CMDBf implementation of the services
b) Wrapping to package the sample as an MDR (i.e. a web service)
The code for the first part can be retrieved from COSMOS CVS under:
The second part can be retrieved from:
org.eclipse.cosmos.samples.cmdbf.services contains an implementation of a
record type constraint:
For the overall flow of the query operation, see
The plug-in can be retrieved under the following CVS module:
org.eclipse.cosmos/data-collection. Notice the result is suppressed in the
last step (i.e. step 4: processContentSelectors (queryResult, cmdbfQuery);)
We are working towards solidifying our documentation and sample set.
Let us know if you have any other questions.
Phone Number: (905) 413-3712
Service Modeling Language - COSMOS
I am beginning to develop an MDR for exposing Qualcomm properitary
provisioning system based on COSMOS framework. I am looking at the code
written by you in Samples project.
While I understand overall flow, I am not quite clear on how to implement
record constraints and how the filtering happens based on 'SuppressResult'
Is there a generic example which would cover all features of Graph Query
I have internally championed that COSMOS framework is the Best Approach and
got approval to build a MDR. I need all the guidance that I can get to move
forward on this.
I am looking to get direction and help.
I would greatly appreciate it if you can give me guidance and necessary
pointers in this respect.
BTW, Are there any training sessions going to be held for Developers Like to
adopt COSMOS framework? If so, when and where?
Thanks in advance,
Current Time: Sat Mar 17 12:55:08 GMT 2018
Powered by FUDForum
. Page generated in 0.01465 seconds