Skip to content

Add Falcon cluster service environment - #356

Merged
samuel-williams-shopify merged 24 commits into
mainfrom
add-falcon-cluster-env
Jul 31, 2026
Merged

Add Falcon cluster service environment#356
samuel-williams-shopify merged 24 commits into
mainfrom
add-falcon-cluster-env

Conversation

@samuel-williams-shopify

@samuel-williams-shopify samuel-williams-shopify commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add Falcon::Environment::Cluster and Falcon::Service::Cluster for workers that bind independently inside their execution context.
  • Add the immutable Falcon::Listener runtime abstraction for both regular servers and cluster workers.
  • Expose each listener's name, scheme, supported wire-protocol names, bound endpoint, and every concrete socket address.
  • Use one shared listener for Falcon::Service::Server and one worker-owned listener per Falcon::Service::Cluster worker.
  • Invoke prepare_worker!(instance, listener:) after binding and before running either server mode.
  • Keep listener ownership explicit so regular servers close during service shutdown and cluster workers close during worker shutdown.
  • Add a Docker Compose example running a two-worker cluster on ephemeral TCP ports behind Envoy using xDS/EDS.

The evaluator remains lazy configuration state; live bound sockets are passed explicitly through the worker lifecycle hook. Integrations serialize the listener's scheme and protocol capabilities into their own discovery model without depending on Async::HTTP implementation constants.

Released dependencies

  • async-http v0.97.0
  • async-service-supervisor v0.18.0
  • async-grpc-xds v0.1.0
  • async-service-supervisor-envoy v0.0.1

Companion PRs

Testing

  • bundle exec bake test (109 tests, 475 assertions)
  • bundle exec rubocop (198 files, no offenses)
  • bundle exec bake decode:index:coverage lib (204/204 definitions)
  • Cluster integration test confirms both independently bound worker ports remain reachable.
  • Docker Compose was previously verified end-to-end through Envoy; the direct cluster lifecycle test was rerun after the listener refactor.

Assisted-By: devx/379cb815-bd96-4979-b667-b34037489b71
Assisted-By: devx/379cb815-bd96-4979-b667-b34037489b71
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
Assisted-By: devx/56c5beec-347d-4712-9cc7-ea033e4d2a8a
@samuel-williams-shopify
samuel-williams-shopify merged commit 4cae0c8 into main Jul 31, 2026
75 checks passed
@samuel-williams-shopify
samuel-williams-shopify deleted the add-falcon-cluster-env branch July 31, 2026 09:45
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