# Gale v0.1.1 - Table of Contents

> Phoenix adapter for HTTP/1.1, HTTP/2, and HTTP/3 (QUIC). Bandit for TCP, quic_h3 for UDP.

## Pages

- [Gale](readme.md)
- [Publish Gale to Hex.pm and GitHub](publish.md)
- [BLAKE3 vs XXH3 (and FNV-1a)](hash.md)
- [Contributing](contributing.md)
- [Security](security.md)

- Guides
  - [Gale for Phoenix](phoenix.md)
  - [QUIC / HTTP/3 on the BEAM — what to add next to Elixir](ecosystem.md)

- Project
  - [Gale HTTP Benchmark](results.md)
  - [Changelog](changelog.md)
  - [LICENSE](license.md)
  - [Sponsor Gale](funding.md)

## Modules

- [Gale](Gale.md): Drop-in HTTP/1.1 + HTTP/2 + HTTP/3 for Phoenix, Bandit, Finch, Req, Cowboy, and hackney.
- [Gale.Bench.Server](Gale.Bench.Server.md): Fresh Elixir/HTTP server implementations for benchmarking.
Pure Elixir, NIF-accelerated, and comparison against Bandit/Cowboy.

- [Gale.CLI](Gale.CLI.md): Standalone CLI (`gale`) and Mix task (`mix gale`).
- [Gale.Cowboy](Gale.Cowboy.md): Drop-in for `Plug.Cowboy.http/3` / `https/3`. Adds `alt-svc` on the plug.

- [Gale.Plug.Adapter](Gale.Plug.Adapter.md): Plug/Phoenix integration surface for HTTP/3 **advertising**, next to Bandit.
- [Gale.Storage](Gale.Storage.md): Content-addressed blobs: **BLAKE3** identity, **XXH3** fast checksum.
- [Gale.Storage.CID](Gale.Storage.CID.md): S5-style blob CID: `0x5b 0x82 0x1e` + BLAKE3-256 + unsigned LEB128 size.

- [Gale.Storage.S3](Gale.Storage.S3.md): S3 PUT/GET with optional AWS SigV4. BLAKE3 stored as `x-amz-meta-blake3`.
- [Gale.Storage.S5](Gale.Storage.S5.md): S5 blob client. Content-addressed with BLAKE3; HTTP to an S5 node.
- [Gale.Survey](Gale.Survey.md): Runtime probe of BEAM HTTP/QUIC/H3 packages (see `ECOSYSTEM.md`).

- Phoenix
  - [Gale.PhoenixAdapter](Gale.PhoenixAdapter.md): Phoenix endpoint adapter: HTTP/1.1 + HTTP/2 (Bandit) and HTTP/3 (QUIC).
  - [Gale.Plug.AltSvc](Gale.Plug.AltSvc.md): Injects `alt-svc: h3=":port"` on every Plug response.
  - [Gale.Server](Gale.Server.md): Drop-in for `Bandit.start_link/1` / `{Bandit, opts}`.

- Plug
  - [Gale.Plug](Gale.Plug.md): Plug adapter for Gale HTTP/1.1, HTTP/2, and HTTP/3.

- Client
  - [Gale.Finch](Gale.Finch.md): Drop-in for `Finch`. Same `start_link/1` and `request/3`; HTTP/3 when the
request URL uses `https` and `protocols: [:http3]` is in Finch pool config
or request opts.

  - [Gale.HTTP](Gale.HTTP.md): Drop-in HTTP client for Req / Finch / hackney / Mint-style calls.
  - [Gale.Hackney](Gale.Hackney.md): Drop-in for `:hackney`. HTTP/3 is opt-in with `protocols: [:http3 | ...]`
(hackney 4.x) or via `Gale.HTTP`.

  - [Gale.Req](Gale.Req.md): Drop-in for `Req`. `Gale.Req.get/2` is `Req.get/2`. Pass `protocols: [:http3]`
to force HTTP/3 via `Gale.HTTP`.

- Codec
  - [Gale.Elixir](Gale.Elixir.md): Pure-Elixir QPACK static encoder (same rules as the Zig NIF) for benches.

  - [Gale.Native](Gale.Native.md): Zig NIF entry points. Prefer `Gale.qpack_encode/1` and friends.

## Mix Tasks

- [mix gale](Mix.Tasks.Gale.md): Gale CLI. Same as the `gale` escript.
- [mix gale.binary](Mix.Tasks.Gale.Binary.md): Build a Burrito single-file CLI (ERTS inside). Needs zig + xz.
- [mix gale.install](Mix.Tasks.Gale.Install.md): Install gale: Burrito single binary if possible, else escript.
- [mix gale.phoenix](Mix.Tasks.Gale.Phoenix.md): Configures a Phoenix endpoint to use Gale for HTTP/1.1, HTTP/2, and HTTP/3.

