tanishqgandhi1908 opened a new pull request, #6799: URL: https://github.com/apache/texera/pull/6799
### What changes were proposed in this PR? Adds the database tables that track **ML models** as a first-class resource in Texera. (umbrella #6494). The `model*` tables mirror the existing `dataset*` tables — their own primary key (`mid`), their own LakeFS repo namespace — and add model-specific attributes (`framework`, `format`): - `model` — the model asset (owner, name, visibility, description, cover image, **framework**, **format**) - `model_user_access` — per-user privilege (reuses `privilege_enum`) - `model_version` — versions of a model (`mvid`, `version_hash`) - `model_upload_session` / `model_upload_session_part` — multipart upload bookkeeping - `model_user_likes` / `model_view_count` — like/view counters The change is **pure schema, with no application code and no behavior change**: - **Fresh installs:** tables added to `sql/texera_ddl.sql` (with matching `DROP TABLE` entries and FK-safe ordering). - **Existing deployments:** a new idempotent migration `sql/updates/30.sql` (all `CREATE TABLE IF NOT EXISTS`, no data backfill), registered as `changeSet id="30"` in `sql/changelog.xml`. - The JOOQ data-access layer is git-ignored and regenerated from the live DB on build, so no generated code is committed. > **Migration ordering note:** this uses `id=30` to sit after #6495's migration `29` (PR #6502, currently in review). These model tables do **not** depend on #6495, so this PR can be reviewed independently. ### Any related issues, documentation, discussions? Closes #6496. ### How was this PR tested? Validated against a throwaway `groonga/pgroonga:4.0.1-debian-15` Postgres: - `sql/texera_ddl.sql` runs end-to-end with no errors; all 7 `model*` tables are created with the expected primary keys, foreign keys (`ON DELETE CASCADE`), unique constraints, and `CHECK` constraints. - `sql/updates/30.sql` applies cleanly on a DB that already has the dataset tables but no model tables, and is idempotent ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (Claude Opus 4.8) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
