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

Add timeout capabilities #11

Open
claudioseveri opened this issue Aug 1, 2015 · 1 comment
Open

Add timeout capabilities #11

claudioseveri opened this issue Aug 1, 2015 · 1 comment
Assignees

Comments

@claudioseveri
Copy link

In time-sensitive applications (e.g. a sensor that uploads data every minute) a timeout feature in data reads and writes to the server might help dealing with slow internet connections, ensuring that the function never exeeds a certain time duration.
Python module "requests" already supports this, so it's only a single-line edit to do.

@claudioseveri claudioseveri changed the title Add timeout capability Add timeout capabilities Aug 1, 2015
@bachwehbi
Copy link
Member

Good point!

I would like to keep the API coherent with the rest of Beebotte SDKs.
Thinking about adding the timeout as a parameter of the BBT object, something like:

bbt = BBT( _accesskey, _secretkey, hostname = _hostname)

timeout = 6 # 6 seconds
bbt.setTimeout(timeout)

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

No branches or pull requests

2 participants