...
Description | Details | Decisions | |||||
---|---|---|---|---|---|---|---|
1 | Assume flat attributes (no complex data types) but data could be stored as json object in SPI impl. for convenience/PoC | ||||||
2 | SPI Implementation NOT using Model (service) current ENM SPI does! | ||||||
3 | Are we going to have XPath/query builder? |
| |||||
4 | Having a fluent interface in my opinion would be way more intuitive and practical. E.g. //AND of two restrictions Restriction and(Restriction firstRestriction, Restriction secondRestriction) //OR of two restrictions Restriction or(Restriction firstRestriction, Restriction secondRestriction) //NOT of a restriction Restriction not(Restriction restriction) This will give any user of the API an intuitive way to build a complex query and the developer a tree to navigate and translate to SQL (or any other query language). A developer could do something the likes of myQuery.setRestriction(restriction1.and(restrcition2).and(restriction3)) | 5 | When do we get attributes? | How do control how many attributes we get back? | We will have an (optional) output specification with the following options
| ||
5 | Should we use the name node or fragment? | We decided on the name DataNode | /Node7 | ||||
6 | Do we want to split the interface? | Maybe we could just have a 3 Alternatives
| peristenceStore
| Change Data SPI to DataStore - methods to add data.
The above will be in separate maven modules. Any data object they need will be in the same module. We will not have a querybuilder in SPI but the SPI will have to understand the | querycpsPath. | The java API will use a builder pattern to create a cpsPath |
ENM SPI Study
Details about the ENM SPI can be found here: Spike
...
Name | Definition | Capabilities | |
---|---|---|---|
1 | DataStoreObjectDataStoreService | Provides the basic information needed to access an object. |
|
2 | PersistenceStore | Adding functionality for handling attributes |
Passes the attributes supplied by the user for a new persistence object so that they may be verified as required.
Initializes the attributes for a new persistence object. This method should be invoked when creating a new persistence object rather than using setAttributes() as it will have different behavior, namely:
Gets the values for the attributes which have been specifically set on this object. This includes attributes which:
Note that an attribute may have been specifically set to null so the values returned in the map may contain nulls.
Determines if the supplied attribute has been specifically set (includes attributes which were set to null).
Gets all of the attribute names available in this persistence object.
Unsets the values of the supplied attributes.
|
| |||
2 | DataNode Object |
|
CpsAdmin SPI
Name | Definition | Capabilities | |
---|---|---|---|
1 | DataspacePersistenceService |
The below are currently in our SPI
| |
2 | AnchorPersistenceService |
| |
3 | Dataspace Object |
| |
4 | Anchor Object |
|
Module SPI
Name | Definition | Capabilities | |
---|---|---|---|
1 | ModulePersistenceService | Adding functionality for handling attributes |
Remove all associations of this persistence object.
Retrieves the namespace of the type of object the type query is to target.
|
2 | BasicModuleObject | Create a simple CPS Module Object |
|
...