Sage-Bionetworks / schematic

Package for biomedical data model and metadata ingress management
https://schematicpy.readthedocs.io/en/latest/cli_reference.html
MIT License
22 stars 25 forks source link

Refactor `synapse/store.py` submodule to allow for different asset stores (like Gen3) #348

Open BrunoGrandePhD opened 3 years ago

BrunoGrandePhD commented 3 years ago

Is your feature request related to a problem? Please describe.

@milen-sage wants us to start thinking of how we can add support for additional asset stores such as Gen3 (in addition to Synapse). This will come after #312 is implemented.

Describe the solution you'd like

One possible solution is to design a base class with method signatures that raise NotImplementedError by default. Then, different asset stores would be implemented by creating a new class inheriting from the base class and overriding each applicable method. This doesn't need to be all methods, but it should be clear which methods represent the minimum required for schematic to work.

We will probably rename the synapse submodule to store or asset_store, and individual Python files therein will implement inherited versions of the base class.

How important is this feature? Select from the options below: • Low - it's an enhancement but not crucial for work

When will use cases depending on this become relevant? Select from the options below: • Long-term - 6 months - 1 year

@milen-sage: Feel free to override my long-term time frame estimates for this feature.

milen-sage commented 3 years ago

Just to clarify, Gen3 is only one option; there could be other asset stores (e.g. cancer digital slide archive (DSA)). In addition, the refactor would be beneficial even if Synapse is the only supported asset store.