Implementing exponential backoff

Should fix #2