This change adds a new cloud remote based on Azure Blob Storage [1] and
the azure-storage-blob SDK [2].
The implementation closely follows the patterns laid out by the existing
cloud remotes (AWS and GCP). Notable differences include:
- No use of a lock in the progress-bar callback and no requirement to
look up total transfer size ahead of time: the Azure Storage SDK
provides the total transfer bytes and current transfer offset in its
progress callback.
- When `exists` is called, check the existence of every blob instead of
listing the entire container. Container list operations can be
expensive so unless the number of checked files is very large, making
separate requests is likely going to be more efficient.
- For increased flexibility, access credentials for the Azure Storage
backend can be provided either connection-string style via the remote
URL or via environment variables. The Azure Storage backend can be
emulated via Azurite [3].
[1] https://azure.microsoft.com/en-us/services/storage/blobs/
[2] https://github.com/Azure/azure-storage-python
[3] https://github.com/Azure/azurite
This change was created together with @EricSchles.
From now on, we identify our cache files by their md5sum,
so that we can avoid cache collission in branching scenario
and also dedup same data at the same time.
Fixes#250, #251
Signed-off-by: Ruslan Kuprieiev <[email protected]>
These are to allow using OAuth with your dvc, as
this is the recomended way to access gcp.
Fixes#203
Signed-off-by: Ruslan Kuprieiev <[email protected]>
This command shows status for data files. I.e.
$ dvc status data/
new file: .cache/Posts-train.tsv_2ccd8e7
new file: data/llss
modified: .cache/Posts.xml_512a612
new file: .cache/empty_0000000
new file: data/oss
new file: .cache/matrix-test.p_69b924d
new file: .cache/dir21111/Posts.xml.tgz_cd71d01
so it will tell us if there are any new/modified/deleted data
files that you might want to push/pull/etc.
Fixes#158
Signed-off-by: Ruslan Kuprieiev <[email protected]>
From now on, 'dvc import' supports s3 and gcp links.
This patch also does some RFC to properly parse url's
scheme using urllib instead of relying on hand-made
regex. Code for downloding files from http urls is moved
to data_cloud.py in preparation for pull/push support
for http/https/ftp schemes in the future.
Also added dummy progress updates(start/finish) for gcp,
as i couldn't find an API call that allows callbacks to
update progress properly.
Fixes#49
Signed-off-by: Ruslan Kuprieiev <[email protected]>
Currently dvc downloads data from cloud even if we already
have the same file downloaded. This patch fixes it by checking
md5 before attempting to download.
Fixes#159
Signed-off-by: Ruslan Kuprieiev <[email protected]>
New names fit much better:
sync_to_cloud -> push
sync_from_cloud -> pull
remove_from_cloud -> remove
Signed-off-by: Ruslan Kuprieiev <[email protected]>
We already have 'sync' command, but users report it to be confusing
when both local and remote files exist, so lets introduce two direct
commands to implicitly push and pull from cloud.
Fixes#157.
Signed-off-by: Ruslan Kuprieiev <[email protected]>
This will make the structure of dvc more linear
making it easier to read. Plus, these changes
are needed in preparation for libdvc, as they
move all cmdline parsing to one common place.
This patch also refactors our settings system
also make it more linear and remove abstraction
levels that are not needed and only cause confusion.
There is a lot more to be done in preparation for
dvc lib and RFC overall, but this a first step
in that long journey.
Signed-off-by: Ruslan Kuprieiev <[email protected]>
I.e. if network is gone for some reason, report that we're
able to sync some targets instead of just throwing exceptions
about broken pipe or something.
Signed-off-by: Ruslan Kuprieiev <[email protected]>