Default TypeDB.HTTP adapter, backed by Finch.
Each connection starts and supervises its own Finch instance, named after the connection, so pools are sized per TypeDB server and never shared by accident. The pool is torn down with the connection.
Why this is the default
Measured against a local TypeDB 3.12.1 with 400 requests per run:
| Concurrency | :httpc | Finch |
|---|---|---|
| 16 | 344 req/s, p50 45ms | 1729 req/s, p50 8ms |
| 64 | 247 req/s, p50 263ms | 1773 req/s, p50 23ms |
| 200 | 77 req/s, p50 2477ms | 1981 req/s, p50 19ms |
:httpc does not degrade gracefully: throughput falls as concurrency rises.
TypeDB.HTTP.Httpc is still supported for environments that must run on OTP
alone, and the numbers above are the price.
Options
:size— connections per pool. Defaults to50.:count— pools per host. Defaults to1.:pools— a full Finch:poolsmap, which takes precedence over:sizeand:countwhen you need per-host tuning.:conn_opts—Mint.HTTP.connect/4options, merged into the default pool. TLS options go here astransport_opts.:pool_timeout— how long a request waits for a free connection when the pool is saturated, in ms. Defaults to Finch's own default of5_000.:name— an existing Finch instance to use instead of starting one. The adapter neither starts nor stops it.
The connection's :connect_timeout is applied as transport_opts[:timeout] on
the default pool, which is the only place Mint reads a connect timeout from.
Pass your own conn_opts: [transport_opts: [timeout: …]] to override it, or a
full :pools map to take over pool configuration entirely.
TLS
Finch verifies certificates by default through Mint, which uses the OS trust
store and checks hostnames. To pin a private CA:
http: {TypeDB.HTTP.Finch, conn_opts: [transport_opts: [cacertfile: "/etc/ssl/private-ca.pem"]]}