Skip to content

Support a customizable API request timeout #186

@bxm156

Description

@bxm156

We have run into a few cases now where Stripe’s default timeout has blocked our payment system workers. The timeout is currently set to 80 seconds, which can tie up our workers. Eventually, all workers can get tied up, and our system will stall, and our APIs return 503s (Service not available).

We would like to be able to set a custom timeout. Should a timeout occur, we will idempotently retry the transaction later. We don’t want to tie up our workers for 80s waiting on response for a single transaction, because we have more requests to process. As developers, we need to be able to tune our application’s behavior, and having an uncontrollable 80 second timeout doesn’t meet our requirements.

It looks to be a simple addition to the python-stripe library, and it is already supported for Google App Engine. I can see in the Issue history that it has been requested multiple times. I don’t quite understand why there has been a hesitation to allow developers to set their own timeout, but I would like to open this up for discussion again.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions