Skip to content

[catalog] split builtin.rs into per-schema submodule files#36478

Merged
mtabebe merged 1 commit intoMaterializeInc:mainfrom
mtabebe:ma/split-builtins
May 8, 2026
Merged

[catalog] split builtin.rs into per-schema submodule files#36478
mtabebe merged 1 commit intoMaterializeInc:mainfrom
mtabebe:ma/split-builtins

Conversation

@mtabebe
Copy link
Copy Markdown
Contributor

@mtabebe mtabebe commented May 8, 2026

builtin.rs had grown to 18k lines, making it difficult to navigate. (#36406 (comment))

Split the builtin item definitions into five submodule files under src/catalog/src/builtin/, organized by schema:

  • pg_catalog.rs TYPE_* consts + pg_catalog views
  • mz_catalog.rs mz_catalog tables/views/sources
  • mz_internal.rs mz_internal views/tables/sources/indexes
  • mz_introspection.rs mz_introspection logs/views
  • information_schema.rs information_schema views

builtin.rs now holds: type/trait/struct definitions, shared helper consts, roles/clusters, BUILTINS_STATIC, the BUILTINS pub mod, and lookup tables.

builtin.rs had grown to 18k lines, making it difficult to navigate.
(MaterializeInc#36406 (comment))
Split the builtin item definitions into five submodule files under
src/catalog/src/builtin/, organized by schema:

- pg_catalog.rs         TYPE_* consts + pg_catalog views
- mz_catalog.rs         mz_catalog tables/views/sources
- mz_internal.rs        mz_internal views/tables/sources/indexes
- mz_introspection.rs   mz_introspection logs/views
- information_schema.rs information_schema views

builtin.rs now holds: type/trait/struct definitions, shared helper consts,
roles/clusters, BUILTINS_STATIC, the BUILTINS pub mod, and lookup tables.
@mtabebe mtabebe force-pushed the ma/split-builtins branch from b86a262 to 709a9ac Compare May 8, 2026 17:32
@mtabebe mtabebe marked this pull request as ready for review May 8, 2026 17:54
@mtabebe mtabebe requested review from a team as code owners May 8, 2026 17:54
@mtabebe mtabebe requested a review from antiguru May 8, 2026 17:54
Copy link
Copy Markdown
Member

@antiguru antiguru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great!

@mtabebe mtabebe merged commit 36df04b into MaterializeInc:main May 8, 2026
119 checks passed
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.

2 participants