Deploy DuckDB Applications and Extensions
Deploy either a loadable extension for an existing DuckDB host or an embedded application with its own database engine. Both need compatible native dependencies. Check the platform and DuckDB requirements for the destination before building a release artifact.
Loadable Extensions
An extension registers its functions against the database passed to its initializer. Those registrations belong to the running database instance; they are not saved in a database file. Tables provide durable state; module globals last only as long as the host process.
The extension requires matching Codon runtime libraries, but not Python. A loaded library remains in use for the lifetime of its host process, so replacement requires a host restart rather than overwriting the active file.
Embedded Deployment
Build the application from the client tutorial:
exaloop --with duckdb build -release -o application application.codon
Deploy the compiled application, installed plugin directory, and matching Codon runtime libraries. Keep their runtime-library search paths valid. The installed plugin includes DuckDB's license. No Python DuckDB wheel is needed.
Check compatibility for supported platforms and database versions before deploying.
Next Steps
- Check native library requirements before moving an application to another host.
- Prepare a production deployment with a repeatable package and rollback procedure.