Skip to content

Transparently handle session terminations during long-polling between Proxy and Broker #70

Open
@TKussel

Description

@TKussel

If the long-polling of tasks or results is disrupted by session terminations (e.g. caused by latency spikes), the proxy client is not informed of that connection loss. An alternative, transparent long-polling mechanism could look like the following:

The long polling wait_time is set as a maximum wait time. If no wait_time is given, a sensible default cap is chosen (e.g. 1 minute). The proxy chooses a lower wait time for repeated long-polls to the broker, up to the chosen maximum time. The timeout for that connection is chosen using a learning mechanism analyzing previous requests (and optionally an echo endpoint in the broker) and converging to an optimal time.

In case of a fast, unimpeded connection, the result is returned – as expected by the application – as fast as it is available in the broker or at least partially after wait_count. In case of a broken session, the connection is transparently reinitialized by the proxy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions