SamCooper / COMMON_SPEC_RIDS

1 stars 0 forks source link

importXML - create or check #106

Closed lacourte closed 5 years ago

lacourte commented 5 years ago

This issue assumes that a "complete" export file includes the XML export for

The importXML operation requires the creation of a new Service/ProviderConfiguration COM object. I assume the ConfigurationObjects COM object shall also be created, as it seems there is a one to one match between those two objects. The service objects shall be created if they "do not exist in the COM Archive" (3.4.14.2.d), or checked for identity if they "already exist in the COM Archive" (3.4.14.2.e/f).

As far as I understand it, the only way to know if an object exists in Archive is based on the object identifier. So if the identifier is present, then we can check if the object exists in Archive, and if the object content is the same. I also consider that if the identifier does not exist, then the object shall always be created. By the way, I also consider that any identifier for the Service/ProviderConfiguration and ConfigurationObjects COM objects shall be ignored. This rule only concerns the service objects.

My question relates to the potential need to create an XML file with no identifier present. The XML file is most probably created using the exportXML operation. This operation has no such option to decide if the identifiers must be exported or not.

SamCooper commented 5 years ago

Yes, the export option will be complete with identifiers. That does not preclude some other means of creating these XML files creating a configuration without Id (maybe from an external tool). It would not know what Id to suggest so by making them blank it is saying "please ingest and assign a new id".