Skip to content
This repository has been archived by the owner on Jul 27, 2022. It is now read-only.

Commit

Permalink
feat: replace cloud_storage with custom implementation (#18) (#42)
Browse files Browse the repository at this point in the history
* feat: replace cloud_storage with custom implementation (#18)

* feat: use ring directly

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
tustvold and kodiakhq[bot] authored Jul 5, 2022
1 parent 755370c commit 4eac786
Show file tree
Hide file tree
Showing 9 changed files with 684 additions and 317 deletions.
8 changes: 6 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,12 @@ azure_storage_blobs = { version = "0.2", optional = true, default-features = fal
bytes = "1.0"
chrono = { version = "0.4", default-features = false, features = ["clock"] }
# Google Cloud Storage integration
cloud-storage = { version = "0.11.1", optional = true, default-features = false, features = ["rustls-tls"] }
futures = "0.3"
serde = { version = "1.0", default-features = false, features = ["derive"], optional = true }
serde_json = { version = "1.0", default-features = false, optional = true }
rustls-pemfile = { version = "1.0", default-features = false, optional = true }
ring = { version = "0.16", default-features = false, features = ["std"] }
base64 = { version = "0.13", default-features = false, optional = true }
# for rusoto
hyper = { version = "0.14", optional = true, default-features = false }
# for rusoto
Expand All @@ -48,7 +52,7 @@ walkdir = "2"
[features]
azure = ["azure_core", "azure_storage_blobs", "azure_storage", "reqwest"]
azure_test = ["azure", "azure_core/azurite_workaround", "azure_storage/azurite_workaround", "azure_storage_blobs/azurite_workaround"]
gcp = ["cloud-storage"]
gcp = ["serde", "serde_json", "reqwest", "reqwest/json", "reqwest/stream", "chrono/serde", "rustls-pemfile", "base64"]
aws = ["rusoto_core", "rusoto_credential", "rusoto_s3", "hyper", "hyper-rustls"]

[dev-dependencies] # In alphabetical order
Expand Down
4 changes: 1 addition & 3 deletions src/aws.rs
Original file line number Diff line number Diff line change
Expand Up @@ -909,9 +909,7 @@ mod tests {
let err = get_nonexistent_object(&integration, Some(location))
.await
.unwrap_err();
if let Some(ObjectStoreError::NotFound { path, source }) =
err.downcast_ref::<ObjectStoreError>()
{
if let ObjectStoreError::NotFound { path, source } = err {
let source_variant = source.downcast_ref::<rusoto_core::RusotoError<_>>();
assert!(
matches!(
Expand Down
Loading

0 comments on commit 4eac786

Please sign in to comment.