FeatureHub Edge: SDK-facing streaming (SSE) and REST feature API
100K+
Edge is the SDK-facing FeatureHub server. This image is published as featurehub/edge. It serves feature state
to SDKs through:
Edge keeps almost no state. It knows only which clients are connected and which environments they listen to. It gets feature data from the Dacha cache and receives feature updates over the async layer (NATS, Kafka or Google Pub/Sub). It never connects to the database, so you can scale it out freely. Run at least two instances in production. See Architecture – Edge (Streaming+REST).
Edge is part of the scalable streaming deployment
(Option 2a),
together with mr and dacha2.
For REST only, backed by the database, see edge-rest.
Full documentation: https://docs.featurehub.io
With Dacha2 (recommended):
docker run -p 8553:8553 --user 999:999 \
-e dacha1.enabled=false -e dacha2.enabled=true \
-e dacha.url.default=http://dacha2:8902 \
-e nats.urls=nats://nats:4222 \
featurehub/edge:latest
| Port | Purpose |
|---|---|
8553 | Edge SDK API, SSE and REST (server.port) |
8701 | Prometheus metrics and health checks (monitor.port) |
You can set any configuration property as an environment variable with the same name and case. You can also mount
/etc/app-config/application.properties and /etc/app-config/secrets.properties. See
Run configuration.
| Property | Description |
|---|---|
dacha1.enabled, dacha2.enabled | Which cache to use. For Dacha2, set dacha1.enabled=false and dacha2.enabled=true. See Async options. |
dacha.url.default | URL of the Dacha2 service. Required for Dacha2. |
nats.urls | NATS servers. For Kafka or Google Pub/Sub, see Async options. |
jersey.cors.headers | CORS headers allowed for browser SDKs. |
edge.sse.drop-after-seconds | How long (default 30) an SSE client stays connected before it is disconnected. 0 keeps connections open. |
edge.sse.heartbeat-period | Interval for heartbeat events on SSE connections (default 0, off). |
edge.dacha.delay-slots | Random reconnect delay window when Dacha is not ready, to prevent reconnect storms. |
edge.cache-control.header | Override Cache-Control on GET (polling) responses. |
update.pool-size, listen.pool-size | Thread pools for incoming updates and incoming listen requests. |
See Edge (all) Config and Edge (Streaming) Config.
/health/liveness and /health/readiness: see Health and Liveness checks/metrics: see Edge metricsLicense: Apache 2 with Commons Clause.
Content type
Image
Digest
sha256:1e9469855…
Size
158.3 MB
Last updated
4 months ago
docker pull featurehub/edge