Productionising LangGraph
Deploy a LangGraph agent: API worker vs queue consumer vs scheduled job on one Postgres, stream modes per consumer, bounding steps and tokens, and testing routers without a model.
Last updated
After this section you can
- Deploy one compiled graph as an API worker, a queue consumer and a scheduled job
- Pick a stream mode per consumer instead of streaming everything
- Bound steps, tokens and wall clock, and choose a durability mode
- Test routers and gates without calling a model
- Run the graph async, which is what a real server needs
Productionising LangGraph
The compiled graph is a library object. Everything that makes it production — where it runs, what stops it, what you can see — is configuration around it.
Nothing about a graph is a server. Put the same compiled object behind an HTTP handler, a queue consumer and a cron job, point all three at one Postgres, and a run started by a request can be finished by a worker three days later.