Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a first cut of an S3 backend for cwl-tes. It works pretty much the same way as the FTP backend: resources get uploaded to S3 and URLs in the workflow are rewritten to point to S3.
Activating the backend happens through the
--remote-storage-url
parameter: if this is a HTTP/S URL then it's assumed that we're talking to an S3-like system, and the URL should be of the formhttp(s)://<endpoint>/<bucket>
. S3 credentials are retrieved from the environment.Implementation-wise, the biggest change is in the addition of the
s3.py
module, which adds another subclass of theStdFsAccess
class. The other changes are in themain.py
module, where the biggest changes are in dispatching on the kind of remote storage URL, as well as making things reasonably polymorphic, so that the worker functions that do the uploading and parsing don't have to care about the type of storage backend.I wanted to share this at this point to get some input about design and future directions. I've only tried this with Minio, and while I've tried to leave the original FTP interface intact, I've not yet tested this in practice. I've also paid very little attention to unit tests (but would be glad to remedy this).
Very glad to hear comments and suggestions!