Current section
Files
Jump to
Current section
Files
src/finch@otp.erl
-module(finch@otp).
-compile([no_auto_import, nowarn_unused_vars]).
-export_type([unix_socket_path/0, unix_socket_specifier/0, pool_specifier/0, pool_protocol/0, pool_option/0, instance_option/0, on_start/0]).
-type unix_socket_path() :: {local, binary()}.
-type unix_socket_specifier() :: {http, unix_socket_path()} |
{https, unix_socket_path()}.
-type pool_specifier() :: default |
{url, gleam@uri:uri()} |
{unix_socket, unix_socket_specifier()}.
-type pool_protocol() :: http1 | http2.
-type pool_option() :: {protocol, pool_protocol()} |
{size, integer()} |
{count, integer()} |
{max_idle_time, finch@timeout:timeout_()} |
{conn_opts, list({gleam@erlang@atom:atom_(), gleam@dynamic:dynamic()})} |
{pool_max_idle_time, finch@timeout:timeout_()} |
{conn_max_idle_time, finch@timeout:timeout_()}.
-type instance_option() :: {name, gleam@erlang@atom:atom_()} |
{pools, gleam@map:map_(pool_specifier(), list(pool_option()))}.
-type on_start() :: {ok, gleam@erlang@process:pid_()} |
ignore |
{error, gleam@dynamic:dynamic()}.