Skip to content

Releases

v1.4.12

Choose a tag to compare

@jghoman jghoman released this 17 Nov 23:17
7f52423

Server release: org-marked namespace containment, configured namespaces for relayed readers, and the warn-mode catalog listing fix.

  • Migrations: one small one, V37. It adds the nullable column hog_namespace.contained_org and a CHECK constraint on it, with a 5 s lock_timeout. hog_namespace has one row per namespace, so this is quick.
  • Upgrading: no config change needed. The new features stay off until configured, and nothing changes for existing namespaces.

Server

  • Org-marked namespace containment (#640).
    • A containment mark can carry an org, which must be a canonical lowercase UUID:
      {"field": "team_id", "value": 9400, "org": "<org uuid>"}
      The namespace then owns <data_path>/org_id=<org>/team_id=9400/ instead of <data_path>/data/<namespace>/.
    • Containment: the namespace's tables register files only under that prefix, and no other table in the catalog registers there. Table-creation write paths, scoped upload claims and compaction outputs all follow the prefix.
    • Org check for scoped callers: a scoped token whose org doesn't match the mark gets the same 404 as for a missing namespace. This applies at the namespace gate, on writes and upload claims, in the listing, and on every store grant. Tenant and operator callers are unchanged.
    • Changing a mark: a mark can be changed or cleared until the namespace holds anything; after that it is permanent.
    • Backends: PostgreSQL only. hoglite refuses an org mark with a 422.
    • Capability: org-marked-containment-v1.
  • Configured namespaces for relayed readers (#641).
    • A Host serves every team's team_<id> import namespace from one source catalog, by pattern, read-only. Nothing is configured per team.
    • Configured through HOGLAKE_SERVED_NAMESPACES_FILE (a team family, with predicate_field: team_id).
    • A scoped caller is served when all of these hold:
      • its token reads the catalog;
      • it holds the schema, through a remote_schemas family entry such as {"team": ["read"]} or a per-name entry;
      • its prd.team_id holds the id, or *;
      • its org equals the namespace's mark.
    • Everyone else gets the 404 of a missing namespace.
  • Catalog listing under warn (#647).
    • An anonymous GET /v1/catalogs under HOGLAKE_AUTH_MODE=warn now lists the default PostgreSQL backend's catalogs, as it does under off. It returned [] before, which left the web UI empty.
    • The per-catalog totals are omitted for the anonymous caller, as /v1/info omits instance totals.
    • Each request is still counted once as a warn refusal.

Docs / CI

  • AGENT.md describes Gigahog CD as Kargo rather than charts state files (#644).
  • The codec wheel jobs are named so that a skipped check reads cleanly (#646).

Operators

  • V37: transactional, 5 s lock timeout, metadata-only column add.
  • HOGLAKE_SERVED_NAMESPACES_FILE: new and optional.
  • Under warn: an unauthenticated caller can now list the default backend's catalog names. Everything else was already readable by name.

v1.4.11

Choose a tag to compare

@jghoman jghoman released this 17 Nov 19:45
2390b27

Server, pyhoglake, millrace and webui release.

  • Atomic partition replacement. A new commit route ends whole live data files of a table and appends their replacements in one snapshot. The changefeed records it as table_replaced.
  • Auth wave 2. The server now has a session-profile token contract, off by default. Every catalog store a handler gets is checked against the token and bound to it. Route values are read from the path only.
  • Remote schemas, Client side. A namespace name can be served read-only from another hoglake deployment, optionally under a local alias.
  • Hoglite maintenance. Manual compaction now runs through the executor PostgreSQL uses, and per-catalog maintenance status and run history work on hoglite.
  • Migrations: V36 (V36__replacement_changes.sql). It widens the hog_snapshot_change.kind CHECK and adds hog_commit_receipt.ended_files. Details are under Operators.
  • Upgrading: no config change is needed, and every new setting defaults to off. Before rolling out, check the caveats under Operators:
    • V36 holds an ACCESS EXCLUSIVE lock on hog_snapshot_change while it validates;
    • with the default HOGLAKE_AUTH_SESSION_PROFILE=off, a token that carries a session-profile claim is now refused;
    • a handler can no longer reach a catalog or namespace the token does not grant, and under warn a scoped caller is refused for this;
    • a query parameter named like a route value is no longer read or relayed.

Server

  • Atomic partition replacement (#571, #631):
    • POST /v1/catalogs/{catalog}/commit/replacements/prepared, advertised as the new capability atomic-partition-replacement-v1. A server that does not support it answers 404, so it never ignores file_ends and publishes only the appends.
    • The body is a CommitRequest plus file_ends (new schema TableFileEnds). Each entry gives namespace, table, a required expected_table_uuid, and exactly one of partitions (tuples in the partition_values encoding) or all_files: true.
      • A year, month, day, hour or bucket value must be a base-10 integer string (20401, not 2025-11-10); anything else is a 422.
      • A tuple that matches no live file ends nothing and is not an error. A table may appear in only one entry.
    • Required fields: idempotency_key, read_snapshot, author and message. deletes or require_unchanged_tables: true is a 400. appends may be empty.
    • Under the commit lock the server checks, in order:
      • the table incarnation (409 table_recreated);
      • the conflict window;
      • the partition spec (409 partition_spec_mismatch while a live file has another spec; all_files is exempt).
    • It then ends each matching live file together with its live deletion vector, and applies the appends.
    • Conflict window:
      • all_files: the table must be unchanged since read_snapshot.
      • partitions: only the target tuples must be unchanged. Any DDL on the table also conflicts, but appends to other partitions do not.
      • Compaction never conflicts. A compaction group planned against an ended file skips that file.
    • Files appended by the same request are never ended by it. An appended path that the catalog already records, live or ended, is a 422.
    • Nothing is deleted at commit. Ended files go through normal retention, expiry and cleanup.
    • CommitResult and GET /commit/receipts/{operation} gain ended_files, which is also returned on replay. It is omitted on other endpoints and on receipts written before V36.
    • Change kind table_replaced: recorded beside table_deleted_from when a replacement ended at least one file of the table. changes() answers 409 reconciliation_required for a window that crosses one, as it does for a truncate. The barrier sits on the change row, so it holds at the retention floor as well.
    • Implemented on PostgreSQL and hoglite. The existing commit routes reject file_ends.
    • Containment order fix (#631): on PostgreSQL, the recorded-path check now runs after the namespace containment checks. A path under another contained namespace is refused with containment_violation, whether or not that path is recorded. Hoglite already checked in this order.
  • Session profile (#622):
    • The profile's contract is in docs/auth.md ("Session profile with embedded storage credentials"). It is PROPOSED and experimental.
    • Its claims are profile, version, purpose, primary_catalog, remote_schemas (read only, at most 16) and aws (an STS-shaped credential, with exp ≤ aws.expires_at). sid, generation, session_deadline and grants are optional.
    • The server only validates the shape, records remote_schemas and forwards the bytes. It never uses the credentials.
    • New HOGLAKE_AUTH_SESSION_PROFILE=off|on (default off). Any other value fails boot.
      • With off, a token that carries profile, aws, primary_catalog or remote_schemas is refused with the new reason profile_not_enabled. It is no longer read as a plain metadata token.
      • With on, the profile is validated, and an operator token may not carry it.
    • New metric hoglake_auth_session_profile_total{outcome="accepted"|"refused_disabled"|"refused_invalid"}.
    • Contract vectors: contract-vectors.json gains tenant_session_profile_disabled. The new file session-profile-vectors.json holds the profile's vectors; all are mutation vectors until an issuer mints the profile.
  • Store entitlement (#627, #629):
    • CatalogStoreSelector applies the auth plugin's catalog and scope check to whatever catalog name the handler passes it. Refusals:
      • 404 worded as a missing catalog;
      • 403 for a missing scope;
      • 401 with no caller.
    • Modes follow the plugin:
      • off checks nothing;
      • warn counts, audits and lets the request through, except for a scoped caller, which is refused as under enforce.
    • Each request adds at most one refusal to hoglake_auth_requests_total. The audit line carries at=store. There is no new label.
    • The handler now gets a per-request view of the catalog store and of each sub-backend, bound to the token (#629):
      • every caller: any catalog other than the resolved one is refused;
      • scoped callers: any namespace the token does not allow is refused, whether it comes from the path, the body or an id (table creations, file ids, lookup cursors);
      • scoped callers: operations that name no namespace are refused, except renewing and abandoning the caller's own upload claims.
    • A disallowed namespace answers the 404 of a missing namespace. An id that belongs to one answers the 404 of a missing id. A scoped table-creation status read in a disallowed namespace now answers 404 for the operation.
    • The namespace gate, the scoped-write checks and the listing filter are unchanged and still decide first. A consistent request costs no extra lookup.
    • Not covered: /v1/maintenance/status, /v1/maintenance/runs, /v1/database/health and GET /v1/mounts. The route table refuses scoped callers on these. docs/auth-tenancy.md lists them.
  • Path-only route values (#625):
    • Handlers read {catalog}, {namespace}, {table}, {operation}, {upload} and the other route values from the matched path only, as the route table and gates do. Before this, they read them from merged parameters that included the query string.
    • The mount relay (MountHostClient) no longer forwards a query parameter named catalog, namespace or table, in any letter case.
    • Documented query parameters are unchanged.
  • Remote schemas (#628, #630):
    • A HOGLAKE_MOUNT_HOSTS_FILE entry with "match": {"type": "namespace", "name": NAME} serves the namespace NAME of every catalog on this server read-only, relayed to another hoglake (the Host). kind must be hoglake and auth must be forward.
    • Access:
      • Served only to a scoped caller whose token grants read on the catalog and whose remote_schemas claim allows the schema. The catalog must exist locally.
      • Anyone else gets the 404 of a missing namespace, and nothing is sent to the Host.
    • Relayed routes: get namespace, list tables, get table and scan, with the caller's Authorization header. Every other route on the schema answers 501 mount_operation_unavailable for a read and 403 read_only_catalog for a write.
    • GET …/namespaces adds {"name", "remote": true} for each schema the token allows, without calling the Host. On the wire, Namespace.namespace_id is now optional: it is absent exactly when remote is true. A local entry is unchanged.
    • NAME is reserved (it is added to the reserved namespaces). A local namespace with that name, or a case variant of it, is hidden from every path, body, id, query parameter and upload prefix, but not removed.
    • Boot refuses a namespace entry in these cases:
      • HOGLAKE_AUTH_SESSION_PROFILE is not on;
      • its URL is not https and the entry does not set "allow_insecure_http": true. An entry that opts in is logged.
    • Alias (#630): an entry-level "remote_name" sets the schema's name on the Host (default NAME).
      • The remote_schemas claim and the relayed path use remote_name.
      • The answers' name and the table's namespace are rewritten back to NAME within max_response_bytes.
      • Two namespace entries with the same Host name are refused at boot.
      • An aliased answer refused after its first bytes are sent is cut mid-transfer.
    • allow_insecure_http and remote_name are refused on events and catalog entries. A server with no namespace entry behaves as before.
    • The Host side is not built.
  • Hoglite maintenance (#623, #624, #626):
    • #623 extracts CompactionExecutor and a CompactionStorage seam from CompactionService. PostgreSQL behaviour is unchanged.
    • POST …/maintenance/compact now works on hoglite through the same executor (#624):
      • the executor owns VARIANT layout...
Read more

pyhoglake-variant-codec 0.1.1

Choose a tag to compare

@github-actions github-actions released this 17 Nov 00:33
5a243a0

pyhoglake 1.4.12

Choose a tag to compare

@github-actions github-actions released this 17 Nov 23:27
7f52423

pyhoglake 1.4.11

Choose a tag to compare

@github-actions github-actions released this 17 Nov 19:55
2390b27

v1.4.10

Choose a tag to compare

@jghoman jghoman released this 13 Nov 22:54
cec7d9f

Server, pyhoglake, millrace and webui release.

  • VARIANT shredding declarations can change. A new alter op, set_variant_shredding, replaces or clears a declaration. With HOGLAKE_COMPACTION_VARIANT on, compaction now rewrites a group of mixed VARIANT layouts per layout instead of refusing it.
  • Auth wave 1. hoglake owns its token contract and depends on no issuer. It accepts RS256 and the OAuth scope claim, can be its own issuer (HOGLAKE_AUTH_MODE=local), forwards verified JWTs to hoglite, and gets storage for its own jobs through a credential provider. millrace and the webui now present credentials.
  • Hoglite maintenance. Options, expiry, cleanup, manual requeue and retirement now run on hoglite. Each is manual and per catalog; none has a background loop.
  • Migrations: none. The newest migration is still V35.
  • Upgrading: an existing deployment needs no config change. Every new setting defaults to the previous behaviour. Before rolling out, check the caveats under Operators: the auth client metric label changes, an aud array with a non-string entry is now refused, a millrace pod with two credential sources set exits, and VARIANT compaction needs extra heap headroom.

Server

  • set_variant_shredding (#580):
    • {"op": "set_variant_shredding", "name": <column>, "shredding": <declaration> | null} on POST …/tables/{t}/alter, on PostgreSQL and hoglite. null or absent clears the declaration, and the column then has no type_params.
    • The declaration is validated as at create_table / add_column: grammar, 1000 fields and arrays, 1024 bytes of path names, depth 16, top-level variant only. A refusal is a 422 with the same messages.
    • A change commits a DDL snapshot. A writer holding an older read gets 409 ddl_since_read_snapshot and re-reads, then writes the new layout. The column keeps its field ID, and earlier snapshots still show the old declaration.
    • An equal declaration is a no-op: it writes no snapshot or row and refuses no in-flight writer. Equality ignores key order and number spelling, and a stored absent, {} or {"shredding": null} counts as no declaration. A request made only of no-ops answers 200 at the unmoved head, with the sampler's totals.
    • The declaration is a target for writers and compaction, not a rule on files. Files keep the layout their footer records.
    • New capability mutable-variant-shredding-v1. A server without it answers 400 unknown alter op.
  • VARIANT compaction by layout (#580, #614), with HOGLAKE_COMPACTION_VARIANT on. server/README.md's VARIANT compaction section has the details.
    • Per-layout split. A group whose inputs hold more than one VARIANT layout is no longer refused:
      • The service reads each input's footer once and hands it on to the rewrite, up to 16 MiB of serialized footer bytes per group.
      • It partitions the inputs by how their layouts deviate from the declaration. Each partition that still meets the group-size rule is rewritten in its own layout, the declared layout first.
      • Nothing is re-shredded: old-layout files compact among themselves.
      • DuckDB-written files are excluded on their own, and partitions too small to compact are left alone.
      • Only a field that is no VARIANT group, or one with a REPEATED node outside a LIST or MAP, still refuses its group as unconvertible_schema.
    • Catalog-scoped probe. The footer probe reads through the catalog's own storage session, as the rewrite does.
    • Layout memory. A per-process map from (catalog, data file) to the declaration and deviation fingerprints, capped at 250k entries. The planner packs known-deviating files only with files that deviate the same way, and drops known DuckDB files.
      • Compaction outputs are entered at commit.
      • DDL on the table, such as set_variant_shredding or adding, dropping or renaming a variant column, makes the table's entries stale, so each file is probed once more.
      • The map is empty after a restart.
    • Borrowing. A remembered remainder that is short of files can borrow idle never-probed files to complete a group:
      • one loan per bucket per sweep, at most minInputFiles − 1 files, prefixes only;
      • the search is bounded to the first fan-in of idle files and the eight largest stranded populations;
      • a loan is made only if every admitted main group keeps its files.
      • #614 lets a loan draw from main groups that the budget refuses, and counts a failed loan's file once.
    • Shape admission. Each deviating layout's shape (node count, nestedness, output leaves) is remembered, at most 4096 shapes, LRU.
      • A sorted group of that layout is admitted against the sorted budgets with its own shape, from metadata alone.
      • A layout the budgets refuse is probed once. After that it is refused from metadata as spill_budget_exceeded / merge_budget_exceeded.
      • Raising HOGLAKE_COMPACTION_SORTED_HEAP_BYTES / HOGLAKE_COMPACTION_SPILL_BYTES admits it on the next plan.
      • Chunk sizing and the re-admission of each part use that part's own layout.
    • Claims. A split group's claim is narrowed to the inputs it compacted, so files left behind can be planned again at once.
    • Run limit. A probe that rewrites nothing is charged against HOGLAKE_COMPACTION_MAX_GROUPS_PER_RUN. A group split into N parts uses N attempts, so the last wave of a sweep can overrun the limit by at most (layouts − 1) × HOGLAKE_COMPACTION_PARALLEL_GROUPS. Groups without VARIANT columns behave as before.
    • New ledger counter layout_probe_only, also in the CompactionResult API.
    • Metrics:
      • hoglake_compaction_variant_layout_mismatch_total{reason="split"|"duckdb"|"layout"}. split is expected for as long as old-layout files remain after a declaration change.
      • hoglake_compaction_variant_layout_outputs_total{layout="declared"|"other"}.
      • hoglake_compaction_variant_layout_files_left_total.
      • hoglake_compaction_skipped_total{reason="layout_probe_only"}.
    • The docs now map the ledger's spill_budget_exceeded / merge_budget_exceeded to hoglake_compaction_skipped_total{reason="spill_budget"|"merge_budget"} (#614).
  • Token verification (#575, #576, #577):
    • docs/auth.md is the canonical auth document. hoglake is a resource server: it issues no tokens on the request path and calls no issuer. docs/auth-tenancy.md is now design history (#575).
    • alg may be ES256 or RS256, and the JWKS may mix EC P-256 and RSA keys (#576):
      • A kid must select a key of the type its alg needs.
      • RSA keys under 2048 bits and JWKs whose alg contradicts their kty are refused at load.
      • Entries for other purposes, such as use other than sig or an encryption alg, are skipped.
    • Catalog grants may come from the OAuth scope claim, as space-separated hoglake:<catalog>:<scope> values (#576):
      • Non-hoglake: values are ignored.
      • A malformed hoglake: value refuses the token (invalid_token).
      • A token carrying both cat and scope must have them agree.
    • Contract vectors are generated in hoglake (just server contract-vectors), with an expect verdict per vector (#577).
    • ten is optional: a token without it is a tenant token. A token without ten that carries prd is refused. Scoped and operator tokens still need ten (#577).
    • New HOGLAKE_AUTH_SCOPED_MAX_LIFETIME_SECONDS (default 900) (#577).
    • New HOGLAKE_AUTH_CLIENT_CLASSES (default empty), up to 16 lowercase User-Agent product tokens, each with its own client label. The built-in map no longer names an issuer, and Go-http-client is now labelled go (#577).
  • Local issuer (#595):
    • HOGLAKE_AUTH_MODE=local behaves like enforce, but trusts only the public half of HOGLAKE_AUTH_SIGNING_KEY, an env-only base64url EC P-256 JWK.
      • HOGLAKE_AUTH_ISSUER defaults to hoglake in this mode.
      • Boot fails if a JWKS file or URL is also set, if the key is missing, or if the key is set under another mode.
      • The key is redacted in config dumps.
    • GET /.well-known/jwks.json (public) serves the key's public half. In every other mode it answers 404.
    • hoglake-server token keygen prints HOGLAKE_AUTH_SIGNING_KEY=<value>.
    • hoglake-server token mint signs a token offline. Flags: --catalog <name>[=<scope>], --scope, --operator, --org, --sub, --client, --ttl (default 24h). It does not mint scoped (prd) tokens. Also available as just server token ….
    • HOGLAKE_PUBLIC_PORT, HOGLAKE_BACKENDS_FILE and HOGLAKE_MOUNT_HOSTS_FILE accept local wherever they accepted warn / enforce.
  • JWT forwarding to hoglite (#589):
    • Only the current request's verified JWT is forwarded to the hoglite backend. Each request gets its own client wrapper, and transport, routing pins and breakers are shared.
    • A hoglite 401 or 403 maps to 401 invalid_token or 403 forbidden ("backend refused request authority").
    • Deleting a hoglite catalog requires an operator token (403 otherwise), checked before any write fence. Tenants are provisioned and deleted only by catalog-bound operator requests.
    • Table-creation receipt status reads are now read-only.
    • An aud array with a non-string entry is now refused as malformed. It used to be ignored.
    • Hoglite redirects are not followed, and an owner hint must be a DNS label.
  • Storage credentials for the server's own jobs (#594, #597, #600):
    • New HOGLAKE_STORAGE_PROVIDER=ambient|static|broker. Unset keeps the old rule: static when both HOGLAKE_S3_ACCESS_KEY and HOGLAKE_S3_SECRET_KEY are set, ambient otherwise. An inconsistent explicit choice fails boot and names the variable.
    • broker exchanges client credentials and is configured with:
      • HOGLAKE_STORAGE_BROKER_TOKEN_URL;
      • HOGLAKE_STORAGE_BROKER_CLIENT_ID and HOGLAKE_STORAGE_BROKER_CLIENT_SECRET;
      • HOGLAKE_STORAGE_BROKER_AUDIENCE (default hoglake).
    • ...
Read more

pyhoglake 1.4.10

Choose a tag to compare

@github-actions github-actions released this 13 Nov 23:03
cec7d9f

v1.4.9

Choose a tag to compare

@jghoman jghoman released this 10 Nov 21:01
a84a05d

Server, pyhoglake and hedgerow release.

  • pyhoglake now writes object-prefix (<field>=<value>/) tables itself, and its VARIANT writes cost less per file.
  • The server routes catalog requests per request through a CatalogStore seam. This wires the hoglite backend behind JWT routing claims, lets the server boot without PostgreSQL, and adds the mount series, dark behind a switch.
  • Migrations: two small ones, V34 and V35.
  • Upgrading: an existing PostgreSQL deployment needs no config change. Mounts stay off unless an operator turns on hog_mount_switch, and requests without a routing claim behave as before.

Server

  • Catalog seam and hoglite routing (#546, #547):
    • The core catalog routes go through a CatalogStore seam.
    • A verified JWT rtg claim (b backend kind, be allowlisted backend ID, t tenant) routes a catalog's requests to that backend.
    • A request without a routing claim uses the configured default backend (HOGLAKE_DEFAULT_BACKEND, HOGLAKE_BACKENDS_FILE). hoglite can't be the default.
    • On hoglite, uploads, table creations, alters, views and partition backends are selected per request. Maintenance and publications are PostgreSQL-only and answer a typed 501.
  • Boot without PostgreSQL (#554):
    • With HOGLAKE_DEFAULT_BACKEND=none, startup opens no pool and runs no migration.
    • The first request routed to PostgreSQL (HOGLAKE_POSTGRES_BACKEND_ID) opens the pool and migrates. A failure there answers 503 backend_unavailable, and a later request can retry.
    • postgres stays the default, with the same eager startup.
  • Mounts, dark behind hog_mount_switch (#555, #556, #557, #558, #559, #561, #562):
    • A mount is a read-only catalog name, <orgID>-events, over a table in this instance's PostgreSQL catalogs. It serves only verified ten: scoped callers whose cat names it.
    • Dispatch happens before placement:
      • a non-read route answers 403 read_only_catalog;
      • POST /v1/catalogs refuses the reserved name shape with 422, whatever the switch says;
      • refusals are counted per mount and in the gate's auth outcome.
    • The operator API is PUT /v1/mounts/{name}, writable only by the subject HOGLAKE_MOUNT_WRITER_SUBJECT names. Each write is a CAS on its revision and is audited as mount_write.
    • A mount compiles its read scope, appears in its scoped readers' catalog listing, and serves the scoped export (read) routes.
    • A mount can be served by another hoglake, which proxies the reads (HOGLAKE_MOUNT_HOSTS_FILE).
    • Other settings: HOGLAKE_MOUNT_ALLOWLIST, HOGLAKE_MOUNT_SOURCE_*, and the scan bounds HOGLAKE_MOUNT_SCAN_DEADLINE_MS, HOGLAKE_MOUNT_SCAN_FILE_BUDGET and HOGLAKE_MOUNT_SCAN_MAX_CONCURRENT.

pyhoglake / hedgerow

  • Object-prefix writes (#563):
    • While TableInfo.object_prefix_field is set, Table.append, prepare_append_tables and prepare_append_files write each file under <data_path>/data/<ns>/<table>/<field>=<value>/. Each file's own footer must prove the value before anything is uploaded. Until now, such a table refused every commit from these writers.
    • A null, non-canonical or out-of-range prefix value, or a layout the client can't place under, raises ValidationError before any encode.
    • New footer_stats_min_bytes= (default DEFAULT_FOOTER_STATS_MIN_BYTES, 1 MiB) on the three writers. With deferred_stats=True on such a table, a smaller file registers the prefix field's stats only (provided at commit), and a larger file registers every stat.
    • New ops.set_object_prefix_field(name).
    • expected_table_info also compares object_prefix_field.
    • Tables without the option are unchanged. Payloads and object bytes are pinned against 1.4.8 by tests/vectors/write_golden.json.
    • append streams its uploads again on tables without variant columns.
  • Faster VARIANT writes (#564):
    • The fixed per-file cost of a shredded VARIANT write_part drops from about 7 ms to about 4.4 ms. Output bytes are unchanged.
    • 100k whale-shaped rows, native codec: −18% per row at 500 groups, −34% at 2000.
    • Compiled plans, stamped footers and schema comparisons are kept in a bounded, locked LRU.
    • VariantReport.encoded_by ("rust" / "python") records which codec produced the storage. The writer skips its second structure check only for Rust output.
    • compile_plan checks a declaration's size before walking it. A caller-built DAG or cycle is now refused promptly; on main this used to take time exponential in its depth.
  • Variant codec: unchanged; the variant-codec extra still pins pyhoglake-variant-codec 0.1.0.

Bench

  • A standalone CostBench runner and a nine-worker NVMe profile (#548).

Operators

  • Migrations V34–V35: both are small and transactional, with a 5 s lock timeout.
    • V34 adds the one-row hog_mount_switch (off).
    • V35 adds the empty hog_mount table.
  • Mounts: off until UPDATE hog_mount_switch SET enabled = true;, a mount row and HOGLAKE_MOUNT_ALLOWLIST are all in place.
  • Defaults: HOGLAKE_DEFAULT_BACKEND defaults to postgres, unchanged.

pyhoglake 1.4.9

Choose a tag to compare

@github-actions github-actions released this 10 Nov 21:07
a84a05d

v1.4.8

Choose a tag to compare

@jghoman jghoman released this 06 Nov 01:05
c908c35

Server, pyhoglake and hedgerow release. It adds the object-prefix table layout, per-tenant authorization (off by default), VARIANT writes from pyhoglake with a Rust codec, and commit-lock metrics. Five migrations (V29–V33): two build indexes concurrently on hog_data_file. Auth stays off unless configured, so an existing deployment needs no config change.

Server

  • Object-prefix layout (#480, #481, #483, #491, #496, #479):
    • A table can name an integer field with set_object_prefix_field. Allowed only on an empty table, and it can't be unset.
    • Every data and delete file then lives under …/data/<ns>/<table>/<field>=<value>/, enforced at commit (422 object_prefix_violation).
    • The hydrator checks each file's prefix against its footer and quarantines mismatches (V30, V31).
    • Compaction compacts under each group's prefix.
    • Commits read the newest live prefix column, not its history.
    • Retired partition specs are kept through expiry.
  • Authorization (HOGLAKE_AUTH_MODE, default off) (#460, #475, #526, #538, #539, #540, #542):
    • Per-tenant catalog authorization at the HTTP boundary under warn / enforce.
    • A public API listener (HOGLAKE_PUBLIC_PORT, default off) always enforces and refuses operator tokens.
    • /metrics on an infra listener with no auth (HOGLAKE_METRICS_PORT, default off).
    • ten: scoped tokens, parsed strictly and refused on catalog routes.
    • Namespace containment (V33): a namespace that owns its prefix. Scoped callers read, and write only to, their own contained namespaces.
  • Commit-lock metrics (#441): waiters, holders and hold time per catalog and path.
  • Bounded exact partition inspection (#482, #485). V32 adds the delete-file snapshot lookup index and drops an unused aggregate query.
  • Compaction of VARIANT columns (#466): copies them in their declared layout, behind HOGLAKE_COMPACTION_VARIANT (default off).
  • hoglite catalog adapter (#534): added but not wired; nothing constructs it.
  • Fixes:
    • HOGLAKE_S3_PATH_STYLE is parsed with boolEnv (#532).
    • Unknown ledger task names pass through the runs feeds (#508).
    • PROBE-ALLCAT sweeps its own database (#470).

pyhoglake / hedgerow

  • VARIANT writes:
    • Table.append and Table.prepare_append_tables write top-level variant columns in the layout of each column's type_params.shredding.
    • They take variant_on_invalid= ("raise", the default, or "null", refused for a NOT NULL variant column) and variant_report=.
    • A variant column's values come as pa.json_() text, the null type (all SQL NULL), or storage in its declaration's write form; a plain string is refused.
    • columns_to_arrow_schema and column_to_arrow_field take variant= ("json", "storage" or "read"; the default still refuses), and the "json" form carries variant_field's marker.
    • prepare_append_tables no longer refuses a variant destination, and the _hog* check stops at a variant column's own name.
    • Caveats:
      • Read-back through the Trino connector is not yet verified by a harness.
      • Compaction skips tables with a variant column unless the server sets HOGLAKE_COMPACTION_VARIANT. It then also skips any group holding a file in another layout or written by DuckDB (#70).
      • DuckDB's own Parquet reader folds a Variant null into SQL NULL, and the hoglake DuckDB extension refuses a variant table at bind (#87).
      • The files of a partitioned variant append are all in memory before the first upload.
    • (#453, #464)
  • Public writer core (#465):
    • pyhoglake.write_part(table, columns, *, write_options, ...) writes one partition group as a PreparedPart (body, size, footer_size, metadata).
    • Its registration(uri, columns, *, stats, partition_values=None) returns the FileRegistration dict. registration also takes stats_field_ids= (only those fields' stats).
    • append and prepare_append_tables are built on it, with the same bytes for a table with no variant column.
    • Table.append now checks the footer of every file it writes.
    • timestamp_s below the top level (in a struct, list or map) is accepted by prepare_append_tables and prepare_append_files, which used to refuse it.
  • Object prefix (client side) (#497):
    • TableInfo carries object_prefix_field, and pyhoglake.object_prefix builds and checks an object-prefix table's paths and stats from its TableInfo, as the server does.
    • A commit refused with 422 object_prefix_violation raises ObjectPrefixViolationError (re_prepare=True, a ValidationError) where it used to raise a plain ValidationError.
    • Table.append and prepare_append_* don't place files, so on such a table they are always refused.
  • Other:
    • Prepared appends accept map columns, and the retention read takes a lock (#461).
    • pyhoglake, hedgerow and duckdb-client send bearer tokens (#472).
  • Variant codec: pyhoglake-variant-codec 0.1.0 provides encode, shredding, decode, verify and structure_fault in Rust (#519, #520, #521, #527, #531). The variant-codec extra pins it exactly.

millrace (ships per commit via Kargo, listed for reference)

  • Writes object-prefix tables under each file's team prefix (#513, #528).
  • MILLRACE_STAGE_REPIN_FROM (#514); the flush commits counter is labelled with its destination (#515).
  • MILLRACE_VARIANT_SOURCES (#468).
  • VARIANT codec metrics (#529, #530, #533).
  • LZ4-framed record values are decompressed; a corrupt frame drops as undecodable_lz4, one that decompresses past 32 MiB as oversized_lz4 (#541).
  • Decimals a column can't hold are dropped (#469).

Operators

  • Migrations V29–V33:
    • V29 (hog_table_layout), V30 (a prefix_quarantined column with a constant default) and V33 (namespace containment columns) are small and run in a transaction with a 5 s lock timeout.
    • V31 and V32 build indexes on hog_data_file CONCURRENTLY, outside a transaction. On large catalogs (prod-us gigahog) expect them to take minutes. Promote outside peak compaction.
  • Auth, the public listener and the infra metrics listener are all off unless configured.
  • HOGLAKE_COMPACTION_VARIANT stays off unless set.

Dependencies

  • Dependabot groups for actions, cargo, Python and npm.