Comments (6)
That does look like a defect. _versionAt returns each item and entity as it was at that time, the numbered-version view of the register should do likewise. Will investigate when I'm able to get back to the registry work.
from ukl-registry-poc.
Thanks. Also note that in current form, it impossible to correlate the entity version with the register item; e.g. I don't know when /def/colours:4 was valid ... this information is visible neither from the /def/_colours?_view=version_list nor from a specific version of the register item (e.g. /def/_colours:6)
from ukl-registry-poc.
Having just checked, "regular" entities (e.g. /def/colours/red) seem to work fine ...
Request:
curl -i -H "Accept:text/turtle" http://ukgovld-registry.dnsalias.net/def/colours/_red:5
Response (selected triples):
http://ukgovld-registry.dnsalias.net/def/colours/_red
a reg:RegisterItem ;
...
owl:versionInfo 5 .
http://ukgovld-registry.dnsalias.net/def/colours/red
a skos:Concept ;
rdfs:label "reddish" ;
dct:description "A modified concept for the colour red" .
Request:
curl -i -H "Accept:text/turtle" http://ukgovld-registry.dnsalias.net/def/colours/_red:1
Response (selected triples):
http://ukgovld-registry.dnsalias.net/def/colours/_red
a reg:RegisterItem ;
...
owl:versionInfo 1 .
http://ukgovld-registry.dnsalias.net/def/colours/red
a skos:Concept ;
rdfs:label "red" ;
dct:description "A concept for the colour red" .
from ukl-registry-poc.
I think I have spotted the problem ...
Register:
i) the register: /def/colours
ii) the register item that provides the metadata about the register with respect to the super-register /def: /def/_colours
iii) the (current) version of the register item /def/_colours: /def/_colours:10
iv) the reg:EntityReference for /def/_colours:10: _:b0 (it's a blank node)
Because _:b0 is associated with a REGISTER resource (e.g. /def/colours) it only has property reg:entity (which provides a reference to /def/colours ... e.g. { _:b0 reg:entity <.../def/colours> . }
Entity:
i) the entity: /def/colours/red
ii) the register item that provides metadata about the entity with respect to the register /def/colours: /def/colours/_red
iii) the (current) version of the register item /def/colours/_red: /def/colours/_red:5
iv) the reg:EntityReference for /def/colours/_red:5: _:b1 (it's a blank node)
In this case, the reg:EntityReference resource _:b1 is associated with a "standard" ENTITY, thus it has two properties:
_:b1 a reg:EntityReference ;
reg:entity <.../def/colours/red> ;
reg:sourceGraph <.../def/colours/_red:2#graph> .
Crucially, the register item for "standard" entity points to a SPECIFIC description of the entity, whilst the register item for a register ONLY refers to the register (a VersionedThing).
My assumption is that the registry system compiles the description of the register by concatenating the properties from the CURRENT VERSION of the register to those persistent properties from the register VersionedThing.
Proposal:
i) rename property reg:sourceGraph to be reg:source
ii) reg:source can be used to refer to EITHER a graph (for a standard entity) or a Version (if the entity, like a Register, is a VersionedThing)
This way, the reg:EntityReference resource _:b0 would have the following properties:
_:b0 a reg:EntityReference ;
reg:entity <.../def/colours> ;
reg:source <.../def/colours:12> .
In this way, sufficient information is provided to the registry to compile the requisite properties from the VersionedThing AND the Version specifically referenced in the reg:EntityReference for a given version of the register item.
from ukl-registry-poc.
It's not quite that simple :)
The version number for a Register is updated if a new item is added to make it possible to reconstruct the register state.
The version number for the RegisterItem which holds the Register is only updated when the metadata changes.
So can't have the current version RegisterItem point to a specific version of a Register, that changes.
May be possible to achieve the behaviour you want in other ways or may need to reconsider how register versioning is implemented internally. Well look at this when I'm back.
from ukl-registry-poc.
Resolved.
I already had a property reg:entityVersion intended to play a similar role to reg:sourceGraph for cases where the entity being referred to is itself a VersionedThing.
I've updated the implementation to use that to track the version of the Register present at the time (each version of) the parent RegisterItem is created.
This allows you to see the explicit version correspondence and means that when you retrieve an earlier RegisterItem version for a Register you see the corresponding version of the Register not the current version.
This does create some internal complexity that will eventually need review and cleaning. As noted in the prior comment the problem is that the Register version continues to change to reflect new members without the owning RegisterItem version changing. Rather than do expensive propagation of those changes the internal API returns either the current Register version (when fetching the current version of the owning RegisterItem) or it fetches the recorded Register version (when fetching a specific version of the owning RegisterItem (which will be the version at Item creation time)). This gives expected behaviour in all cases but isn't very satisfying.
from ukl-registry-poc.
Related Issues (20)
- Configuring a SLAVE Registry instance as "read only"
- Batch-upload that fails during payload validation still creates the Register associated with the collection-root
- (Batch-)upload payload validation requires use of rdfs:label; skos:prefLabel is not sufficient
- Add support for OAuth 2.0 (OpenID Connect) HOT 1
- Additional roles in security model
- API security documentation bug
- Bootstrap duplication
- Remove owner/manager for bootstrap system registers
- Enhancements to release tagging behaviour.
- Requesting version of top-level register (or its register item) using webUI throws HTTP 500 exception HOT 1
- Support subproperties of rdfs:label
- Incomplete listing in native "View" mode
- Modification of NamespaceForward resource (code 200) is redirected to delegationTarget HOT 1
- HTTP 404 error encountered by IE8 users HOT 3
- Code migration and maintenance
- Data dictionary support
- Customisable lifecycle for Register items
- Change text indexing strategy
- Improve security for authenticated users HOT 4
- Propagation of content "patches" from MASTER Registry instance to SLAVE instances HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ukl-registry-poc.