Hooks and events
Hooks are lifecycle callbacks used by extensions and observability integrations. Keep hooks short, deterministic, and failure-aware; a diagnostic hook must not change transaction results.
Separate the event registry from hook dispatch and from extension capability discovery. This keeps startup validation and runtime failure handling independently testable.
Procedural language handlers
amphi_ext::LanguageHandler dispatches persistent scalar functions through compile_scalar and
anonymous blocks such as DO through compile_inline. The language package owns parsing,
checking, compilation, and runtime. The host supplies generic SQL, transaction/savepoint,
cancellation, and notice services through LanguageInlineHost. The embedding application
registers the native provider through EngineOptions::extension_providers; CREATE EXTENSION
records installation in the catalog but does not load a package dynamically. See the
procedural language host contract.
Arrays of extension types use the shared generic ArrayOps implementation, but receive their
own OID and an explicit element-to-array relation in the catalog. The extension registry must
provide that OID; the core does not derive it from the type name.