Skip to content

docs: concurrency model + SDK 26.05.02 + new env settings#27

Merged
ancongui merged 1 commit into
mainfrom
docs/concurrency-model-and-sdk-26-05-02
May 19, 2026
Merged

docs: concurrency model + SDK 26.05.02 + new env settings#27
ancongui merged 1 commit into
mainfrom
docs/concurrency-model-and-sdk-26-05-02

Conversation

@ancongui
Copy link
Copy Markdown
Contributor

Summary

Documentation + version bumps closing out the last four PRs (#23, #24, #25, #26) and preparing the 26.05.02 SDK release.

New canonical doc

docs/concurrency.md — the multi-worker scaling story we've been improving end-to-end:

  • Four invariants (atomic transitions, EDA advisory lock, idempotency-key collision recovery, reaper revival)
  • Five orphan classes the reaper handles
  • Lease windows + reaper settings
  • Adapter compatibility matrix
  • Operator-side SQL recipes for detecting + manually re-claiming stuck jobs

Drift fixes

File Change
docs/deployment.md Scaling table claimed worker delivery was sharded via Redis consumer groups -- only true for FLYDOCS_EDA_ADAPTER=redis. Default is postgres with the advisory-lock-based competitive consumer. Worker / Bbox worker / Postgres / Redis rows all rewritten.
docs/troubleshooting.md New "Stuck jobs" section: one SQL snippet per orphan class + the operator override for forcing a re-claim + the explicit "cancel a RUNNING job" recipe.
env_template Added five concurrency settings introduced by the reaper PR.

Java SDK docs

File Change
sdks/java/QUICKSTART.md Spring Boot starter quickstart. Fixed pre-existing broken snippet that called doc.fields() on a Map<String,Object>.
sdks/java/TUTORIAL.md Two new sections: §9 Spring Boot starter + §10 Resilience knobs (opt-in retry + pool sizing). Table of contents updated. Old §9 (Reactive usage) renumbered to §11.
sdks/java/flydocs-examples/README.md NEW -- 1:1 parity with the Python SDK's examples README. Per-example mvn exec:java invocations + Spring Boot run command for the webhook receiver.

Version bumps to 26.05.02

Surface Before After
sdks/python/pyproject.toml 26.5.1 26.5.2
sdks/python/src/flydocs_sdk/_version.py 26.5.1 26.5.2
sdks/java/pom.xml (parent) 26.05.01 26.05.02
sdks/java/flydocs-sdk/pom.xml 26.05.01 26.05.02
sdks/java/flydocs-spring-boot-starter/pom.xml 26.05.01 26.05.02
sdks/java/flydocs-examples/pom.xml 26.05.01 26.05.02
FlydocsClientAsync.USER_AGENT 26.05.01 26.05.02
Doc snippets (README + QUICKSTART + TUTORIAL) 26.05.01 26.05.02

Tagging v26.05.02 after merge fires .github/workflows/publish-sdks.yaml which deploys the Java multi-module reactor to GitHub Packages and attaches the Python wheel + sdist to the GitHub Release.

Test plan

  • Python tests/unit + tests/integration: 311 passed, 2 skipped.
  • Pyfly tests/eda: 42 passed.
  • Java mvn verify reactor: 53 passed, 5 live integration cleanly skipped.
  • Java live integration vs :8400: 5/5 passed.
  • ruff check . clean.
  • ruff format --check . clean.

New canonical reference at ``docs/concurrency.md`` covering the
multi-worker safety story the recent four PRs delivered: atomic state
transitions, per-group ``pg_try_advisory_lock`` in the EDA drain,
idempotency-key collision recovery, and the ``JobReaper`` /
``BboxReaper`` orphan-revival sidecars. Includes lease defaults, the
five orphan classes the reaper handles, and operator-side recipes for
detecting + manually re-claiming stuck jobs.

Documentation drift fixes:

  * ``docs/deployment.md`` -- the scaling table claimed worker delivery
    was sharded via Redis consumer groups. That's only true when
    ``FLYDOCS_EDA_ADAPTER=redis``; the default is ``postgres`` with the
    advisory-lock-based competitive consumer. Rewrote both Worker /
    Bbox worker rows and the Redis / Postgres rows.
  * ``docs/troubleshooting.md`` -- added "Stuck jobs" section with one
    SQL snippet per orphan class + the operator override for forcing a
    re-claim, plus the explicit "cancel a RUNNING job" recipe.
  * ``env_template`` -- added five concurrency settings introduced by
    the reaper PR (``FLYDOCS_JOB_RUN_LEASE_S``,
    ``FLYDOCS_BBOX_REFINE_LEASE_S``, ``FLYDOCS_REAPER_SWEEP_INTERVAL_S``,
    ``FLYDOCS_QUEUED_ORPHAN_THRESHOLD_S``,
    ``FLYDOCS_PARTIAL_SUCCEEDED_ORPHAN_THRESHOLD_S``).

Java SDK docs:

  * ``QUICKSTART.md`` -- Spring Boot starter quickstart; fixed an
    existing snippet that called ``doc.fields()`` on a
    ``Map<String,Object>``.
  * ``TUTORIAL.md`` -- two new sections: Spring Boot starter and
    resilience knobs (opt-in retry, pool sizing, AutoCloseable).
    Table of contents updated.
  * ``flydocs-examples/README.md`` -- NEW. 1:1 parity with the Python
    SDK's examples README.

Version bumps to 26.05.02 (CalVer):

  * Python: ``sdks/python/pyproject.toml`` + ``_version.py``.
  * Java: parent + 3 submodule poms via
    ``versions:set -DprocessAllModules=true``; ``USER_AGENT`` constant in
    ``FlydocsClientAsync``; ``<dependency>`` snippets in README +
    QUICKSTART + TUTORIAL.

All test suites green: Python 311 passed (2 LLM smoke tests skipped),
Java reactor 53 passed + 5 live integration vs the running API.
@ancongui ancongui merged commit 9f0cfa0 into main May 19, 2026
8 checks passed
@ancongui ancongui deleted the docs/concurrency-model-and-sdk-26-05-02 branch May 19, 2026 12:35
ancongui added a commit that referenced this pull request May 31, 2026
New canonical reference at ``docs/concurrency.md`` covering the
multi-worker safety story the recent four PRs delivered: atomic state
transitions, per-group ``pg_try_advisory_lock`` in the EDA drain,
idempotency-key collision recovery, and the ``JobReaper`` /
``BboxReaper`` orphan-revival sidecars. Includes lease defaults, the
five orphan classes the reaper handles, and operator-side recipes for
detecting + manually re-claiming stuck jobs.

Documentation drift fixes:

  * ``docs/deployment.md`` -- the scaling table claimed worker delivery
    was sharded via Redis consumer groups. That's only true when
    ``FLYDOCS_EDA_ADAPTER=redis``; the default is ``postgres`` with the
    advisory-lock-based competitive consumer. Rewrote both Worker /
    Bbox worker rows and the Redis / Postgres rows.
  * ``docs/troubleshooting.md`` -- added "Stuck jobs" section with one
    SQL snippet per orphan class + the operator override for forcing a
    re-claim, plus the explicit "cancel a RUNNING job" recipe.
  * ``env_template`` -- added five concurrency settings introduced by
    the reaper PR (``FLYDOCS_JOB_RUN_LEASE_S``,
    ``FLYDOCS_BBOX_REFINE_LEASE_S``, ``FLYDOCS_REAPER_SWEEP_INTERVAL_S``,
    ``FLYDOCS_QUEUED_ORPHAN_THRESHOLD_S``,
    ``FLYDOCS_PARTIAL_SUCCEEDED_ORPHAN_THRESHOLD_S``).

Java SDK docs:

  * ``QUICKSTART.md`` -- Spring Boot starter quickstart; fixed an
    existing snippet that called ``doc.fields()`` on a
    ``Map<String,Object>``.
  * ``TUTORIAL.md`` -- two new sections: Spring Boot starter and
    resilience knobs (opt-in retry, pool sizing, AutoCloseable).
    Table of contents updated.
  * ``flydocs-examples/README.md`` -- NEW. 1:1 parity with the Python
    SDK's examples README.

Version bumps to 26.05.02 (CalVer):

  * Python: ``sdks/python/pyproject.toml`` + ``_version.py``.
  * Java: parent + 3 submodule poms via
    ``versions:set -DprocessAllModules=true``; ``USER_AGENT`` constant in
    ``FlydocsClientAsync``; ``<dependency>`` snippets in README +
    QUICKSTART + TUTORIAL.

All test suites green: Python 311 passed (2 LLM smoke tests skipped),
Java reactor 53 passed + 5 live integration vs the running API.

Co-authored-by: ancongui <andres.contreras@soon.es>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant