Comments (10)
For other storage adapters, we could store them in a sidecar file. The other option would be to store them in the metadata store instead. I don't have a strong preference for one over the other, but it seems like the sidecar file would make the storage adapters more self-contained.
from valkyrie.
Right now the mime_type/filename are stored in the metadata store. It basically goes "Book -> FileSet -> FileNode -> FileInStorageAdapter"
from valkyrie.
@tpendragon it seems like we should be able to upload a file with no metadata. Does that imply that the model would have only id/mime_type/filename ?
from valkyrie.
@jcoyne Which model?
from valkyrie.
I guess that would be FileSet
from valkyrie.
So, I see a couple options.
-
Postcard -> FileSet -> FileNode('mime_type', 'filename', 'width', 'height') -> (via file_identifiers) FileInStorageAdapter('content')
-
Postcard -> FileSet -> FileInStorageAdapter('filename', 'mime_type', 'width', 'height') (Problem is disk-based here, how do we store that info? And we won't be able to query for properties of the file)
-
Postcard -> FileSet -> FileNode('width', 'height', 'filename', 'mime_type') -> FileInStorageAdapter('filename', 'mime_type')
Which do you see as best?
from valkyrie.
Could we have
Postcard -> FileSet -> FileNode -> AbstractMetadataNode
Where AbstractMetadataNode could be part of the StorageAdapter or part of the Persistence?
So the StorageAdapter::Disk could take a metadata_store as an argument (file based store or database)
So the StorageAdapter::Memory could take a metadata_store as an argument (memory based store or database)
and the StorageAdapter::Fedora would have a default metadata store of (fcr:metadata/HTTP headers)?
from valkyrie.
@jcoyne That could work! I'm not sure how to implement it though - if you have any ideas I'd like to see it
from valkyrie.
I mentioned this in another ticket:
I think the easy way to solve this is to:
- Get rid of FileNode.
- Add a
metadata
property to our File class - Require a metadata adapter as an initialization argument for our Disk storage adapter, so it knows where to store metadata.
from valkyrie.
Requiring a metadata adapter for storage adapters that don't support metadata natively sounds like a good solution to me. If we really wanted to store tech metadata in a sidecar file, we could make a metadata adapter to do that.
from valkyrie.
Related Issues (20)
- Add language to README about branch naming
- Update references of hard-coded legacy master branch name to main branch name
- Valkyrie StorageAdapter Files should have a `#close` method
- Valkyrie StorageAdapter Files shouldn't open a file handle on instantiation
- If enable_extension fails in the first DB migration, it should provide a better error about what to do.
- Storage adapters should have #id_for HOT 2
- Transition Lando to docker-compose for development environment
- Update the gemspec to require MFA for RubyGems releases
- Identify a new Product Owner HOT 5
- Fedora StorageAdapter finds root node for `nil` identifer
- Validate Fedora 6.3 RC1
- Postgres query service should use find_each in #find_all and #find_all_of_model for efficiency HOT 1
- Release v3.0.2 HOT 2
- Support mapping a pre-existing Fedora 6 repository to models.
- Dry::Types::Params::* missing from Valkyrie::Types HOT 1
- Document versioning for StorageAdapters
- Fedora storage adapter expects io to have #length
- Blank values for type Valkyrie::ID cause URI-to-ID lookups to return the Fedora base path as an ID HOT 2
- Valkyrie::StorageAdapter documentation correction? HOT 1
- Valkyrie::StorageAdapter::File - insert a higher abstraction to support cloud providers? HOT 20
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 valkyrie.