The Confidence Flag Resolver implemented in Rust, plus example hosts and a Cloudflare Worker build. This workspace compiles the core resolver to native and WebAssembly and demonstrates how to call it from Go, Node.js, Python, and Java.
confidence-resolver: Core resolver crateconfidence-cloudflare-resolver: Cloudflare Worker-compatible WASM targetwasm-msg: Minimal WASM messaging layer shared by hostswasm/python-host: Python host example calling the resolver. Only intended to be an example and used for integration tests.data/: Sample local development data (e.g., resolver state)
Option 1: Docker only
- Docker - Everything runs in containers, no other tools needed
Option 2: Local development
- Rust toolchain (automatically installed via
rust-toolchain.toml) - For Python host example: Python 3
# With Docker (reproducible, no setup needed)
docker build . # Build, test, lint everything
make # Same, using Makefile
# E2E tests require Confidence credentials passed as Docker secret
# Create openfeature-provider/js/.env.test with your credentials, then:
docker build \
--secret id=js_e2e_test_env,src=openfeature-provider/js/.env.test \
.
# With local tools (fast iteration)
make test # Run tests
make lint # Run linting
make build # Build WASM
# Run Python host example
make run-pythonThere is a Python host implementation in the wasm/python-host folder.
It is used for integration tests, but you can manually run it:
make run-python-hostBuild the Cloudflare-compatible resolver (WASM):
make cloudflareYou can then integrate with Wrangler using confidence-cloudflare-resolver/wrangler.toml.
Small local benchmarks exist for Go and Node.js to validate end-to-end wiring. They are a work-in-progress and do not produce meaningful or representative performance numbers yet.
Run with Docker (streams all logs, cleans up containers afterward):
# Go benchmark
make go-bench
# Node.js benchmark
make js-benchNotes:
- Each target starts a dedicated mock server container and a one-shot bench container, then tears everything down.
- Use
docker compose up ... go-benchor... js-benchto run them individually without Make.
See LICENSE for details.