Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow options like "timeout" to be passed to HTTPoison.get_blob underneath inside options #54

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

krishna1m
Copy link

Fixes #53

Allows to call the new signature like below -

Azurex.Blob.get_blob(name, container, recv_timeout: 60_000, timeout: 60_000, headers: [{"Content-Type", "application/json"}])

krishna1m and others added 5 commits August 29, 2024 13:48
…word list

Co-authored-by: Hitalo Siqueira <[email protected]>
Co-authored-by: Jon Lauridsen <[email protected]>
…son from Azurex for `get_blob`

Co-authored-by: Jon Lauridsen <[email protected]>
Allow passing connection parameters together with the container to blob
functions.

Values from the parameters are prioritized over default configuration.
Still always read azure connection string from application config, but
allow the element itself to be parameterised. Still default to azurex.

This change does introduce some breaking API changes, notably on
put_blob, to nest params under options (similar to an earlier commit's
work on get_blob).

Co-authored-by: Aman Kumar Singh <[email protected]>
Co-authored-by: Konstantinos Gkinis <[email protected]>
@mattpolzin
Copy link

Was it necessary to add the config element changes in the same PR? At first glance they look like separate goals. I'm not a maintainer, just asking the question.

@craigfurman
Copy link

craigfurman commented Oct 28, 2024

@mattpolzin sorry, these are definitely separate goals. When I recently committed to this fork's master branch the other day, I had no idea this PR existed.

@krishna1m let's close this, cut a branch before that recent fork commit, and PR that. If that lands, we can PR the config element bit separately. WDYT?

craigfurman and others added 3 commits December 18, 2024 11:35
Pave the way for merging in a branch from another fork that has not been
accepted upstream yet, which adds support for multiple azure storage
accounts, parameterised by call.

Previous commits in our fork here made breaking changes to a few
functions, e.g. `put_blob()`. Upstream, this function's final argument
is a keyword list defaulting to `[]`. In our fork, we've nested the
params keyword list inside another one, so that we can pass various
non-param overrides without having 2 keyword lists. The breaking change
isn't obvious in the type spec, but the user must pass a
differently-shaped keyword list.

The noaccOS fork has a similar motivation to add non-params overrides,
but they've taken the other approach: passing 2 keyword lists. When we
merge in their branch here, we'll have to pick a signature kind (2
keyword lists or a single nested one). Since we're already using a
nested one, we'll stick with that pattern and resolve the merge
conflicts.

First though, we must finish the interface change job that we'd started,
and nest params inside options for all functions. Interestingly, for
some functions, this is just a rename to make it clear we'd already
implicitly done this.

Co-authored-by: Harisudhan V R <[email protected]>
And also fix all tests.

Co-authored-by: Aman Kumar Singh <[email protected]>
Co-authored-by: Harisudhan V R <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Passing a timeout in get_blob does not work
5 participants