Hello fellow TMFers,
Looking for some advice on Relationship type to be used in a TMF622 payload.
Consider the below Catalog model of an Offering making a composite Product avaialble to the market.
(I am aware of the general industry momentum towards making Offerings composite/bundled while keeping products atomic, but this is not possible every time)
I am using a flat Order Line Item payload structure, such that each Product (parent and children) are represented as individual OLIs that are at the same level and describing relationships between the parent & child OLI using OrderItemRelationship node.
(The other alternatives are using OLI hierarchy or using nested Product structure to represent the structure)
Thus, my TMF622 (simplified) payload looks like below -
{"productOrderItem": [
{
"action": "add",
"id": "OLI-001",
"product": {
"productSpecification":{"name":"BB Package"},
"productOffering": {"id": "BB1234", "name": "BB Gold Offer"}
},
"productOrderItemRelationship": [
{"id": "OLI-002", "relationshipType": "hasChild"},
{"id": "OLI-003", "relationshipType": "hasChild"}
]
},
{
"action": "add",
"id": "OLI-002",
"product": {
"productSpecification":{"name":"Router"},
"productOffering": {"id": "BB1234", "name": "BB Gold Offer"}
},
"productOrderItemRelationship": [
{"id": "OLI-001", "relationshipType": "hasParent"}
]
},
{"action": "add",
"id": "OLI-003",
"product": {
"productSpecification":{"name":"Support"},
"productOffering": {"id": "BB1234", "name": "BB Gold Offer"}
},
"productOrderItemRelationship": [
{"id": "OLI-001", "relationshipType": "hasParent"}
]
}]}
In the above example, the parent OLI describes relationships with the children OLIs using "hasChild".
Is it necessary/mandated by TMF Specs to have the child OLI also describe it's relationship with the parent with "hasParent"?
Can I not describe only at the parent level and leave it there?
In a nutshell, why does the relationship has to be described by both the parent and children. Parent says these are my children, children say this is my parent (other than for an extra validation reasons?)
Thanks
S
------------------------------
Shashank Inamdar
------------------------------