-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make object ID accessible from a small file without having to parse inventory #579
Comments
I agree that it would be nice to have a less expensive way to get an object's id. I currently use a regex to get this in rocfl so I don't have to parse the entire inventory when I just want the id. |
If we were to follow on from the use of NAMASTE to specify the type of an object (Conformance Declaration, |
@zimeon if you use a NAMASTE file then the We have discussed a short-term solution to this, storing an id.json or metadata.json file in the logs directory pending a decision for the OCFL object spec itself. |
Yes, given that object ids should be URIs, they would need to be encoded if you wanted to use namaste. @ptsefton It might be more fitting to use an extension in the short-term. |
@pwinckles Can an extension do things like add an extra file to the object root? Spec says "The OCFL Object Root must not contain files or directories other than those specified in the following sections." |
No, you'd just do like you described with the logs dir. So, you'd write the file to |
Just to clarify, in an object the path to the new metadata file would be |
No, I was suggesting putting it in the objects extension directory, so it would be something like |
There are a variety of ways of approaching this problem. A lot involve some form of caching with no intrinsic OCFL spec changes. Therefore we think this is best kept as an optional extension. |
Editors' discussion 2023-09-22: Per #579 (comment) we think this is best addressed by either application caching or and extension |
I thought this had been discussed before but I can’t find an issue.
It would be good to be able to find an OCFL Object’s ID without having to load the inventory, which could be an expensive operation. For example in writing a library you might want to be able to return a list of Object IDs so they can be consumed, eg by an indexer. To get the ID, now though you have to parse the inventory, pass the ID to another process which then also has to parse the inventory to use the object.
Could we just have an id file with string in it (or maybe other useful metadata without the potentially large parts).
The text was updated successfully, but these errors were encountered: