We're migrating from the production-stack router to this project and really happy with how lightweight and performant it is. One thing we're missing though is file-based configuration.
The production-stack router supports a --dynamic-config-yaml flag that lets you pass a YAML config file with worker URLs, routing policy, model mappings, etc. This is really useful in production — especially with Docker Swarm configs or Kubernetes ConfigMaps — because it keeps the compose/deployment files clean and the router config versionable on its own.
With the current CLI-only approach, all configuration has to live inline in the container command, which gets unwieldy as the number of workers and options grows.
Since RouterConfig already derives Deserialize, it seems like adding a --config <path> flag that reads and deserializes a JSON/YAML file would be a fairly small change. We'd be happy to contribute a PR for this if you're open to it.
We're migrating from the production-stack router to this project and really happy with how lightweight and performant it is. One thing we're missing though is file-based configuration.
The production-stack router supports a
--dynamic-config-yamlflag that lets you pass a YAML config file with worker URLs, routing policy, model mappings, etc. This is really useful in production — especially with Docker Swarm configs or Kubernetes ConfigMaps — because it keeps the compose/deployment files clean and the router config versionable on its own.With the current CLI-only approach, all configuration has to live inline in the container command, which gets unwieldy as the number of workers and options grows.
Since
RouterConfigalready derivesDeserialize, it seems like adding a--config <path>flag that reads and deserializes a JSON/YAML file would be a fairly small change. We'd be happy to contribute a PR for this if you're open to it.