crossbario / crossbario/autobahn-python

Successful connection doesn't reset the exponential backoff state

Open
#1,597 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
2.5k
Forks
768
PR merge metrics
No merged PRs in 30d

Description

When I kill crossbar, I can see python-autobahn doing exponential backoff which is fine, however, if the connection re-establishes, the existing state isn't cleared. So if there is a subsequent disconnect, instead of the retry_delay being 0, it continues to grow the previous retry delay

In these circumstances, small outages cause the retry_delay to accumulate, building up to a 5+ minute wait before it even attempts a connection

I'm looking into how I can reach this from the Component, or if changes need to be made to the library, but I wanted to open this in case anyone has feedback or a workaround

Thanks in advance

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the Component connection handling and the library's exponential backoff logic. Confirm where a successful reconnect leaves retry state unchanged, then verify that a later disconnect begins with a zero retry delay rather than the accumulated value.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
networking
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.