Hi Jonathan,
I came across this issue again, while working on something else.
It appears catalog API's do not explicitly mention that categories should have a tree structure (with the exception of TMF633 which does mention a "tree", but I believe it should emphasize that point).
As far as I can see, the only factor enforcing a tree structure is that category.parentId can contain a single value. If you omit category.parentId, sub categories could be referenced by multiple parent categories, and a graph structure could emerge rather than a tree.
Do you think enforcing a tree structure is necessary? (To be honest, I don't have any real world cases necessitating to extend it.)
Regards,
------------------------------
Şanver Narin
PiA-TEAM INC.
------------------------------
Original Message:
Sent: Oct 10, 2019 08:37
From: Şanver Narin
Subject: TMF 620 category.parentId
Thanks for the comments Jonathan.
Regards,
------------------------------
Şanver Narin
PiA-TEAM INC.
Original Message:
Sent: Oct 10, 2019 03:53
From: Jonathan Goldberg
Subject: TMF 620 category.parentId
Hi Sanver
Thanks for the suggestion
This parent ID pattern is followed in all the Category resources for the various catalogs.
You could argue that in a tree structure there is no need for the child to know who its parents are, only for the parents to know who its children are (and this is satisfied by an array of categoryRef as you describe). I don't think that we have bi-directional references anywhere in the Open API model, at least not in the parts I am familiar with. So the parent id is a logical pointer.
Hope it helps
------------------------------
Jonathan Goldberg
Amdocs Management Limited
Original Message:
Sent: Oct 01, 2019 09:15
From: Şanver Narin
Subject: TMF 620 category.parentId
Hi,
In TMF 620 category.parentId is defined as a simple string value.
Wouldn't it be better to change it to a ref (e.g. parentRef) pointing to the parent category resource, if any?
This may be a minor point, but it would be consistent with the soul of the API.
Regards,
------------------------------
Şanver Narin
PiA-TEAM INC.
------------------------------