Skip to content

Bind each metric and dimension to its column on the REST path too - #2414

Open
shangyian wants to merge 1 commit into
mainfrom
preagg-rest-inline-columns
Open

Bind each metric and dimension to its column on the REST path too#2414
shangyian wants to merge 1 commit into
mainfrom
preagg-rest-inline-columns

Conversation

@shangyian

Copy link
Copy Markdown
Collaborator

No description provided.

POST /preaggs/register took the retired four-field shape -- metrics and
dimensions as lists, with the columns in separate measure_columns and
dimension_columns maps -- while the kind: preagg YAML spec had moved to
declaring each reference together with the physical column that holds it.
One concept spelled two ways depending on which surface you reached for.

The request body now takes the same two maps, and both models enforce the
same three rules from models/preagg_binding: the retired fields are
refused, a list where a map belongs is refused, and a key whose column is
empty is refused. Each rejection says what was found, what to write
instead, and shows the whole shape in the syntax that surface is authored
in, so an existing file or API client can be fixed from the message.

Since the references are now the map keys on both paths,
register_external_preaggregations takes the maps rather than lists plus
bindings, which removes the check for a bound dimension that isn't in the
grain -- unrepresentable now. Binding every dimension explicitly also
means every dimension column is type-checked, which is what the YAML path
already did.
@netlify

netlify Bot commented Aug 12, 2026

Copy link
Copy Markdown

Deploy Preview for thriving-cassata-78ae72 ready!

Name Link
🔨 Latest commit 3623eea
🔍 Latest deploy log https://app.netlify.com/projects/thriving-cassata-78ae72/deploys/6a7c8f1319ee9200080ca062
😎 Deploy Preview https://deploy-preview-2414--thriving-cassata-78ae72.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant