-
Notifications
You must be signed in to change notification settings - Fork 1
Allow multiple predicates per single Relationship #505
Description
The goal is to aggregate together Objects (currently called triples) under a single relationship, to let the user handle them through a single UI component, but being able to use different predicate URI depending on the data selected.
Proposal A: 32 hours
We modify the Relationship model to have multiple URIs, whenever an admin creates an Object it will have to link it to a Relationship and a single predicate URI within that Relationship. The model will be modified to allow the same Object to be used in multiple relationships, but it will have to be linked to a single predicate for each relationship, this will give freedom to aggregate the same Object under 2 different Relationships if needed. Export wise the Object linked to multiple Relationships it will be exported as many times it is used/selected in a KS, so it could be exported multiple times (multiple rows) if used in 2 different relationships, each time using the predicate URI linked to it . During the ingestion, if the new objects will be found under the predicate URI we are consuming, these objects will be automatically created and linked to the predicate URI and all the Relationships have this predicate URI.
Current relationships existing in the system will be migrated to this new model and their current predicate uri will be the first one, also the triples currently used will be linked according to the new design.
Acceptance criteria:
- Allow the admin user to create multiple predicate URI and predicate Name couples within the same Relationship.
- Change the name Triples to Composer Objects in the admin interface
- Allow the user to link CO (composer objects) to multiple relationships, and for each relationship to a specific predicate URI in that relationship which will be used for the export.
- UI wise, all objects linked to a relationship should be available to be selected with the same UI component, using the same component currently existing (single select, multi select, text area).
- When triggering the export, each object used with a relationship should be exported using the predicate URI, predicate Name and relationship label to which it was linked.
- When triggering the ingestion, when consuming a predicate URI currently existing in composer under one or multiple relationship, if we find new CO we will create new instances of CO with the new data encountered (Ingest dynamic relationships created #487 is propaedeutic to this, otherwise this last acceptance criteria cannot be done).
Proposal B: 14 hours
We keep the model as is but we add some new properties to the Triples/Composer Objects called Predicate URI and Predicate Name, which will be optional.
When triggering the export, if the CO has predicate URI and Name specified we export the CO using its own predicate URI and Name, otherwise we use the Predicate Name and URI specified in the relationship to which this is linked.
The same CO cannot be linked to multiple relationships, the model will be modified to allow multiple CO with the name and uri but linked to different relationships (duplicates).
At ingestion level we will only be able to add the new CO within the predicate URI configured for the relationships (#487 is propaedeutic to this, otherwise this last acceptance criteria cannot be done).
Acceptance criteria:
- Change the name Triples to Composer Objects (CO) in the admin interface
- Allow the user to specify Predicate Name and Predicate URI as part of the Triple/Composer object properties
- When triggering the export, if a CO has predicate name and uri specified as its own properties we use these for the export, otherwise we use the predicate name and uri specified in the relationship.
- When triggering the ingestion, when consuming the predicate URI specified for the relationship, we will create new COs linked to this relationship (Ingest dynamic relationships created #487 is propaedeutic to this, otherwise this last acceptance criteria cannot be done).