Skip to content
easycaptcha.to

Latency analysis

A faster polling loop is not a faster solver

Measure the delay between remote completion and local observation before attributing latency changes to recognition or worker scheduling.

By the easycaptcha team · Published

Reading map for A faster polling loop is not a faster solver: Observation delay; Use a controlled timing fixture; Compare held observations honestly.
An illustrated reading map of the considerations discussed below.View full-size illustration

A job can finish between two lookups. Your application notices completion only when the next observation returns. A longer pause can therefore increase observed latency even if the remote work takes exactly the same time.

Observation delay

This is observation lag. Keep it separate from admission, queue wait, and solving when comparing clients or modes. A method-level stopwatch is not a measurement of internal worker computation.

Use a controlled timing fixture

For an illustrative fixture that becomes complete just after one lookup, a one-second observer notices sooner than a ten-second observer. The fixture did not solve faster; the client checked sooner. Repeat with different completion moments to see the relationship between pause and observation.

Use deterministic fixtures for that experiment instead of spending paid tasks to rediscover a scheduling effect. Then evaluate the deployed observer’s request volume and connection behavior.

Compare held observations honestly

A raw-API held lookup can reduce repeated requests and observation delay while keeping a connection open. It still has a bounded server interval and a separate client timeout. Basic SDK lookup methods should follow their documented signatures.

Set the transport deadline to allow the chosen wait interval plus overhead. Ending local waiting does not cancel accepted work, so keep the ID and decide who reconciles the outcome.

Report the clocks you actually observe

Document each event pair, pause, deadline, and unknown result. If the service does not expose an authoritative completion timestamp, do not claim an exact observation lag inferred from a client-only trace. You can still compare observable end-to-end behavior with that limitation stated.

Avoid making a shorter timeout appear faster by excluding jobs that did not finish before it. Keep those attempts in the cohort and reconcile them separately.

Polling versus long polling covers resource tradeoffs, stage timing gives an event model, and tail latency shows why the few slow observations matter even when a mean looks acceptable.

Frequently asked questions

Can polling make a completed job appear slower?

Yes. A result may be ready before the client checks again. Observation delay is part of measured client latency, not necessarily remote solve time.

How can I reduce repeated task lookups?

Consider the creation-time hold option and a suitable lookup schedule. Continue retrieving the same task rather than creating replacement paid work.

How can easycaptcha fit into my integration tests?

Use the documented recognition or token API for the hCaptcha stage, preserve task IDs, and inspect terminal results. Measure verifier acceptance and application completion separately from job completion.

Try easycaptcha

Test your hCaptcha workflow with easycaptcha

Use easycaptcha's task retrieval and creation-time hold option to compare observation strategies.

Use the recognition and token API to exercise your integration, inspect job results, and report observed acceptance. Get started with typed Python and JavaScript SDKs.