cabloy 5.1.49 → 5.1.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/skills/cabloy-backend-scaffold/SKILL.md +207 -0
- package/.claude/skills/cabloy-backend-scaffold/evals/evals.json +29 -0
- package/.claude/skills/cabloy-backend-scaffold/references/backend-thread-map.md +52 -0
- package/.claude/skills/cabloy-backend-scaffold/references/follow-up-checklist.md +39 -0
- package/.claude/skills/cabloy-contract-loop/SKILL.md +201 -0
- package/.claude/skills/cabloy-contract-loop/evals/evals.json +29 -0
- package/.claude/skills/cabloy-contract-loop/references/contract-loop-map.md +47 -0
- package/.claude/skills/cabloy-contract-loop/references/verification-checklist.md +32 -0
- package/.claude/skills/cabloy-frontend-scaffold/SKILL.md +230 -0
- package/.claude/skills/cabloy-frontend-scaffold/evals/evals.json +35 -0
- package/.claude/skills/cabloy-frontend-scaffold/references/follow-up-checklist.md +41 -0
- package/.claude/skills/cabloy-frontend-scaffold/references/frontend-thread-map.md +54 -0
- package/.claude/skills/cabloy-workflow/SKILL.md +288 -0
- package/.claude/skills/cabloy-workflow/evals/evals.json +35 -0
- package/.claude/skills/cabloy-workflow/references/cli-strategy.md +39 -0
- package/.claude/skills/cabloy-workflow/references/edition-detection.md +29 -0
- package/.github/workflows/docs-pages.yml +54 -0
- package/.gitignore +1 -0
- package/CHANGELOG.md +46 -0
- package/CLAUDE.md +59 -0
- package/README.md +137 -0
- package/cabloy-docs/.vitepress/config.mjs +222 -0
- package/cabloy-docs/.vitepress/public/CNAME +1 -0
- package/cabloy-docs/.vitepress/theme/custom.css +64 -0
- package/cabloy-docs/.vitepress/theme/edition-badges.md +5 -0
- package/cabloy-docs/.vitepress/theme/index.js +5 -0
- package/cabloy-docs/ai/class-placement-rule.md +138 -0
- package/cabloy-docs/ai/cli-for-agents.md +56 -0
- package/cabloy-docs/ai/cli-to-skill-map.md +165 -0
- package/cabloy-docs/ai/docs-skills-rules-mapping.md +167 -0
- package/cabloy-docs/ai/edition-detection.md +30 -0
- package/cabloy-docs/ai/future-skill-roadmap.md +135 -0
- package/cabloy-docs/ai/global-bean-lookup.md +157 -0
- package/cabloy-docs/ai/introduction.md +62 -0
- package/cabloy-docs/ai/playbook-backend-module.md +111 -0
- package/cabloy-docs/ai/playbook-contract-regeneration.md +100 -0
- package/cabloy-docs/ai/playbook-frontend-page.md +99 -0
- package/cabloy-docs/ai/playbook-metadata-refresh.md +67 -0
- package/cabloy-docs/ai/repo-guidance.md +58 -0
- package/cabloy-docs/ai/rules-and-config.md +29 -0
- package/cabloy-docs/ai/skills.md +35 -0
- package/cabloy-docs/ai/verification.md +30 -0
- package/cabloy-docs/backend/aop-overview.md +128 -0
- package/cabloy-docs/backend/auth-guide.md +151 -0
- package/cabloy-docs/backend/backend-essentials.md +128 -0
- package/cabloy-docs/backend/broadcast-guide.md +138 -0
- package/cabloy-docs/backend/cache-guide.md +70 -0
- package/cabloy-docs/backend/captcha-guide.md +162 -0
- package/cabloy-docs/backend/cli.md +173 -0
- package/cabloy-docs/backend/config-guide.md +249 -0
- package/cabloy-docs/backend/controller-aop-guide.md +270 -0
- package/cabloy-docs/backend/controller-guide.md +347 -0
- package/cabloy-docs/backend/crud-workflow.md +118 -0
- package/cabloy-docs/backend/dto-guide.md +161 -0
- package/cabloy-docs/backend/dto-infer-generation.md +153 -0
- package/cabloy-docs/backend/dynamic-datasource-guide.md +70 -0
- package/cabloy-docs/backend/election-guide.md +141 -0
- package/cabloy-docs/backend/entity-guide.md +150 -0
- package/cabloy-docs/backend/error-guide.md +108 -0
- package/cabloy-docs/backend/event-guide.md +183 -0
- package/cabloy-docs/backend/external-aop-guide.md +149 -0
- package/cabloy-docs/backend/field-indexes.md +79 -0
- package/cabloy-docs/backend/foundation.md +281 -0
- package/cabloy-docs/backend/i18n-guide.md +211 -0
- package/cabloy-docs/backend/internal-aop-guide.md +181 -0
- package/cabloy-docs/backend/introduction.md +95 -0
- package/cabloy-docs/backend/jwt-guide.md +276 -0
- package/cabloy-docs/backend/logger-guide.md +223 -0
- package/cabloy-docs/backend/mail-guide.md +189 -0
- package/cabloy-docs/backend/menu-guide.md +80 -0
- package/cabloy-docs/backend/migration-and-changes.md +192 -0
- package/cabloy-docs/backend/model-guide.md +274 -0
- package/cabloy-docs/backend/multi-database-datasource.md +171 -0
- package/cabloy-docs/backend/multi-instance-and-instance-resolution.md +196 -0
- package/cabloy-docs/backend/openapi-guide.md +118 -0
- package/cabloy-docs/backend/orm-aggregate-group-guide.md +210 -0
- package/cabloy-docs/backend/orm-configuration-guide.md +165 -0
- package/cabloy-docs/backend/orm-guide.md +109 -0
- package/cabloy-docs/backend/orm-mutation-guide.md +195 -0
- package/cabloy-docs/backend/orm-select-guide.md +243 -0
- package/cabloy-docs/backend/queue-guide.md +271 -0
- package/cabloy-docs/backend/quickstart.md +141 -0
- package/cabloy-docs/backend/redis-guide.md +70 -0
- package/cabloy-docs/backend/redlock-guide.md +60 -0
- package/cabloy-docs/backend/relations-guide.md +250 -0
- package/cabloy-docs/backend/runtime-and-flavors.md +304 -0
- package/cabloy-docs/backend/schedule-guide.md +81 -0
- package/cabloy-docs/backend/scripts.md +116 -0
- package/cabloy-docs/backend/serialization-guide.md +192 -0
- package/cabloy-docs/backend/service-guide.md +166 -0
- package/cabloy-docs/backend/sharding-guide.md +49 -0
- package/cabloy-docs/backend/startup-guide.md +326 -0
- package/cabloy-docs/backend/transaction-guide.md +82 -0
- package/cabloy-docs/backend/unit-testing.md +209 -0
- package/cabloy-docs/backend/upload-guide.md +160 -0
- package/cabloy-docs/backend/user-access-guide.md +157 -0
- package/cabloy-docs/backend/validation-guide.md +80 -0
- package/cabloy-docs/backend/worker-guide.md +59 -0
- package/cabloy-docs/editions/cabloy-basic.md +25 -0
- package/cabloy-docs/editions/cabloy-start.md +24 -0
- package/cabloy-docs/editions/detection.md +31 -0
- package/cabloy-docs/editions/overview.md +44 -0
- package/cabloy-docs/frontend/api-guide.md +93 -0
- package/cabloy-docs/frontend/api-schema-guide.md +43 -0
- package/cabloy-docs/frontend/app-startup-guide.md +185 -0
- package/cabloy-docs/frontend/cli.md +78 -0
- package/cabloy-docs/frontend/component-guide.md +105 -0
- package/cabloy-docs/frontend/component-props-guide.md +97 -0
- package/cabloy-docs/frontend/component-v-model-guide.md +110 -0
- package/cabloy-docs/frontend/css-in-js-guide.md +151 -0
- package/cabloy-docs/frontend/design-principles.md +55 -0
- package/cabloy-docs/frontend/environment-config-guide.md +250 -0
- package/cabloy-docs/frontend/foundation.md +57 -0
- package/cabloy-docs/frontend/generic-component-guide.md +35 -0
- package/cabloy-docs/frontend/icon-engine-guide.md +88 -0
- package/cabloy-docs/frontend/introduction.md +32 -0
- package/cabloy-docs/frontend/ioc-and-beans.md +211 -0
- package/cabloy-docs/frontend/mock-guide.md +109 -0
- package/cabloy-docs/frontend/model-architecture.md +87 -0
- package/cabloy-docs/frontend/model-state-guide.md +70 -0
- package/cabloy-docs/frontend/module-scope.md +168 -0
- package/cabloy-docs/frontend/modules-and-suites.md +179 -0
- package/cabloy-docs/frontend/navigation-guards-guide.md +68 -0
- package/cabloy-docs/frontend/openapi-sdk-guide.md +102 -0
- package/cabloy-docs/frontend/page-guide.md +223 -0
- package/cabloy-docs/frontend/page-params-guide.md +87 -0
- package/cabloy-docs/frontend/page-query-guide.md +96 -0
- package/cabloy-docs/frontend/page-route-guide.md +147 -0
- package/cabloy-docs/frontend/quickstart.md +201 -0
- package/cabloy-docs/frontend/route-alias-guide.md +61 -0
- package/cabloy-docs/frontend/scripts.md +86 -0
- package/cabloy-docs/frontend/sdk-guide.md +45 -0
- package/cabloy-docs/frontend/server-data.md +74 -0
- package/cabloy-docs/frontend/ssr-client-only.md +40 -0
- package/cabloy-docs/frontend/ssr-env.md +51 -0
- package/cabloy-docs/frontend/ssr-init-data.md +46 -0
- package/cabloy-docs/frontend/ssr-overview.md +48 -0
- package/cabloy-docs/frontend/ssr-seo-meta.md +52 -0
- package/cabloy-docs/frontend/system-startup-guide.md +186 -0
- package/cabloy-docs/frontend/theme-guide.md +154 -0
- package/cabloy-docs/frontend/zod-guide.md +161 -0
- package/cabloy-docs/fullstack/edition-collaboration-differences.md +61 -0
- package/cabloy-docs/fullstack/frontend-metadata-to-backend.md +64 -0
- package/cabloy-docs/fullstack/introduction.md +69 -0
- package/cabloy-docs/fullstack/openapi-to-sdk.md +116 -0
- package/cabloy-docs/fullstack/quickstart.md +86 -0
- package/cabloy-docs/fullstack/vona-zova-integration.md +86 -0
- package/cabloy-docs/index.md +73 -0
- package/cabloy-docs/package.json +16 -0
- package/cabloy-docs/pnpm-lock.yaml +1607 -0
- package/cabloy-docs/reference/backend-directory-structure.md +88 -0
- package/cabloy-docs/reference/cli-reference.md +49 -0
- package/cabloy-docs/reference/glossary.md +38 -0
- package/cabloy-docs/reference/package-map.md +105 -0
- package/cabloy-docs/reference/repo-scripts.md +36 -0
- package/package.json +4 -1
- package/scripts/init.ts +12 -0
- package/scripts/upgrade.ts +31 -3
- package/vona/README.md +3 -3
- package/vona/README.zh-CN.md +4 -4
- package/vona/packages-vona/vona/package.json +1 -1
- package/vona/src/suite-vendor/a-cabloy/modules/a-datasharding/package.json +1 -1
- package/vona/src/suite-vendor/a-cabloy/modules/a-datasharding/src/bean/summerCache.datasourceWrite.ts +2 -2
- package/vona/src/suite-vendor/a-cabloy/package.json +1 -1
- package/vona/src/suite-vendor/a-captcha/modules/a-captcha/package.json +1 -1
- package/vona/src/suite-vendor/a-captcha/modules/a-captcha/src/bean/cacheRedis.captcha.ts +2 -2
- package/vona/src/suite-vendor/a-captcha/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-bean/cli/bean/metadata/generate.ts +5 -6
- package/vona/src/suite-vendor/a-vona/modules/a-bean/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-cache/cli/cacheMem/boilerplate/{{sceneName}}.{{beanName}}.ts_ +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-cache/cli/cacheRedis/boilerplate/{{sceneName}}.{{beanName}}.ts_ +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-cache/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-cache/src/.metadata/index.ts +13 -2
- package/vona/src/suite-vendor/a-vona/modules/a-cache/src/bean/bean.cache.ts +6 -7
- package/vona/src/suite-vendor/a-vona/modules/a-cache/src/{bean/bean.cacheMemBase.ts → service/cacheMemBase_.ts} +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-cache/src/{bean/bean.cacheRedisBase.ts → service/cacheRedisBase_.ts} +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-mailconfirm/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-mailconfirm/src/bean/cacheRedis.emailConfirm.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-mailconfirm/src/bean/cacheRedis.passwordReset.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-openapi/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-openapi/src/bean/summerCache.json.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/cli/databaseDialect/boilerplate/{{sceneName}}.{{beanName}}.ts_ +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/.metadata/index.ts +4 -3
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/bean/bean.database.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/bean/bean.model.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/bean/schedule.softDeletionPrune.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/common/utils.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/index.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_cache.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_meta.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.modelBase.ts +0 -5
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoAggregate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoCreate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoGet.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoGroup.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoMutate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoSelectAndCount.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoUpdate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/index.ts +1 -0
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/modelCacheBase.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/relations.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/relationsDynamic.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/relationsMutate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/relationsStatic.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/cacheEntity_.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/cacheQuery_.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/database.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean/bean.databaseDialectBase.ts → service/databaseDialectBase_.ts} +38 -41
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/db_.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/relations_.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/database.ts +0 -5
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/dto/dtoGet.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/dto/dtoMutate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/dto/dtoSelectAndCount.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/model.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/modelAggr.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/modelCount.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/modelGeneral.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/modelGroup.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/modelIncrement.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relations.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsColumns.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsDef.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsDefDynamic.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsDefMutate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsMutate.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/types/relationsTables.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-ormdialect/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-ormdialect/src/bean/databaseDialect.betterSqlite3.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-ormdialect/src/bean/databaseDialect.mysql.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-ormdialect/src/bean/databaseDialect.pg.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-permission/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-permission/src/bean/bean.permission.ts +109 -40
- package/vona/src/suite-vendor/a-vona/modules/a-permission/src/bean/summerCache.permission.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-startup/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-startup/src/bean/cacheRedis.startupDebounce.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-summer/cli/boilerplate/{{sceneName}}.{{beanName}}.ts_ +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-summer/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-summer/src/.metadata/index.ts +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-summer/src/bean/bean.summer.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-summer/src/service/localMem_.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-summer/src/service/localRedis_.ts +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-summer/src/{bean/bean.summerCacheBase.ts → service/summerCacheBase_.ts} +3 -3
- package/vona/src/suite-vendor/a-vona/modules/a-swagger/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-swagger/src/bean/summerCache.rapidoc.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-swagger/src/bean/summerCache.swagger.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-user/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-user/src/bean/cacheRedis.authToken.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-worker/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-worker/src/bean/cacheRedis.workerAlive.ts +2 -2
- package/vona/src/suite-vendor/a-vona/package.json +1 -1
- package/zova/README.md +4 -4
- package/zova/README.zh-CN.md +4 -4
- package/zova/packages-zova/zova/package.json +2 -2
- package/zova/src/suite/a-demo/modules/demo-basic/src/page/toolTwo/controller.tsx +0 -2
- package/zova/src/suite/a-home/modules/home-base/src/config/locale/en-us.ts +1 -0
- package/zova/src/suite/a-home/modules/home-base/src/config/locale/zh-cn.ts +1 -0
- package/zova/src/suite/a-home/modules/home-base/src/page/errorNotFound/controller.tsx +8 -2
- package/zova/src/suite/a-home/modules/home-layoutweb/src/component/layoutWeb/controller.tsx +1 -1
- package/zova/src/suite/a-home/modules/home-layoutweb/src/component/layoutWeb/render.header.tsx +1 -1
- package/zova/src/suite/a-home/modules/home-layoutweb/src/component/layoutWeb/render.locale.tsx +2 -5
- package/zova/src/suite/a-home/modules/home-layoutweb/src/component/layoutWeb/render.tabs.tsx +1 -4
- package/zova/src/suite-vendor/a-zova/modules/a-router/package.json +1 -1
- package/zova/src/suite-vendor/a-zova/modules/a-router/src/bean/sys.router.ts +28 -6
- package/zova/src/suite-vendor/a-zova/modules/a-router/src/monkeySys.ts +15 -3
- package/zova/src/suite-vendor/a-zova/modules/a-router/src/types/router.ts +1 -0
- package/zova/src/suite-vendor/a-zova/modules/a-routertabs/package.json +1 -1
- package/zova/src/suite-vendor/a-zova/modules/a-routertabs/src/model/tabs.ts +4 -0
- package/zova/src/suite-vendor/a-zova/package.json +3 -3
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_crud.ts +0 -0
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_crud_inner.ts +0 -0
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_crud_table.ts +0 -0
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_knex.ts +0 -0
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_utils.ts +0 -0
- /package/vona/src/suite-vendor/a-vona/modules/a-orm/src/{bean → lib}/bean.model/bean.model_view.ts +0 -0
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# OpenAPI Guide
|
|
2
|
+
|
|
3
|
+
This guide explains how OpenAPI works in Vona within the Cabloy monorepo.
|
|
4
|
+
|
|
5
|
+
## Why OpenAPI matters in Cabloy
|
|
6
|
+
|
|
7
|
+
OpenAPI is one of the main fullstack contract bridges between Vona and Zova.
|
|
8
|
+
|
|
9
|
+
The backend emits machine-readable contract metadata, and the frontend can consume that metadata through generated SDKs, schema-driven behavior, and API tooling.
|
|
10
|
+
|
|
11
|
+
That is why OpenAPI belongs in the core Cabloy knowledge graph rather than in an isolated backend appendix.
|
|
12
|
+
|
|
13
|
+
The same field metadata surface also connects naturally to response serialization; see [Serialization Guide](/backend/serialization-guide).
|
|
14
|
+
|
|
15
|
+
## OpenAPI in the backend contract loop
|
|
16
|
+
|
|
17
|
+
A useful split is:
|
|
18
|
+
|
|
19
|
+
- controllers define request and response contracts
|
|
20
|
+
- DTOs and entities provide schema and metadata surfaces
|
|
21
|
+
- validation contributes runtime constraints and inferred schema
|
|
22
|
+
- OpenAPI emits the machine-readable contract from those backend declarations
|
|
23
|
+
- frontend SDK generation is a downstream consumer of that emitted contract
|
|
24
|
+
|
|
25
|
+
This distinction matters because backend authoring and frontend consumption are related, but not the same step.
|
|
26
|
+
|
|
27
|
+
## Built-in endpoints
|
|
28
|
+
|
|
29
|
+
Several built-in endpoints are available, including:
|
|
30
|
+
|
|
31
|
+
- Swagger UI
|
|
32
|
+
- OpenAPI JSON output
|
|
33
|
+
- versioned OpenAPI JSON output
|
|
34
|
+
- RapiDoc
|
|
35
|
+
|
|
36
|
+
This makes the contract easy to inspect both manually and programmatically.
|
|
37
|
+
|
|
38
|
+
## `bean.openapi`
|
|
39
|
+
|
|
40
|
+
Vona provides a global bean for OpenAPI-related generation tasks.
|
|
41
|
+
|
|
42
|
+
Representative capabilities include generating JSON for:
|
|
43
|
+
|
|
44
|
+
- a specific DTO class
|
|
45
|
+
- multiple DTO classes
|
|
46
|
+
- the entire system
|
|
47
|
+
- a specific controller action
|
|
48
|
+
|
|
49
|
+
This is important because OpenAPI is treated as a first-class framework service, not as an external afterthought.
|
|
50
|
+
|
|
51
|
+
## Validation and OpenAPI are linked
|
|
52
|
+
|
|
53
|
+
A major theme is that the same validation-oriented declaration surface also drives OpenAPI metadata generation.
|
|
54
|
+
|
|
55
|
+
That means:
|
|
56
|
+
|
|
57
|
+
- inferred schemas can become OpenAPI metadata
|
|
58
|
+
- explicit schema rules can become OpenAPI metadata
|
|
59
|
+
- `v` helper extensions can enrich OpenAPI output
|
|
60
|
+
|
|
61
|
+
This tight linkage is one of the reasons the Cabloy contract story can stay productive at scale.
|
|
62
|
+
|
|
63
|
+
## Controllers, DTOs, entities, and examples all contribute
|
|
64
|
+
|
|
65
|
+
OpenAPI output is not owned by one layer only.
|
|
66
|
+
|
|
67
|
+
In practice, the emitted contract can be influenced by:
|
|
68
|
+
|
|
69
|
+
- controller route and action metadata
|
|
70
|
+
- request-parameter decorators
|
|
71
|
+
- response schema declarations and wrapper behavior
|
|
72
|
+
- DTO field metadata and options
|
|
73
|
+
- entity field metadata and options
|
|
74
|
+
- validation rules and helper extensions
|
|
75
|
+
- examples, titles, descriptions, and related metadata
|
|
76
|
+
|
|
77
|
+
That is why contract changes should often be reviewed across several backend pages, not only in one file.
|
|
78
|
+
|
|
79
|
+
## I18n support
|
|
80
|
+
|
|
81
|
+
OpenAPI metadata can also participate in i18n.
|
|
82
|
+
|
|
83
|
+
That is useful because contract descriptions and titles are not only for machines. They are also developer-facing assets. For the broader locale/timezone and localization model behind this, see [I18n Guide](/backend/i18n-guide).
|
|
84
|
+
|
|
85
|
+
## Configuration
|
|
86
|
+
|
|
87
|
+
The OpenAPI behavior is configurable through the `a-openapi` module config.
|
|
88
|
+
|
|
89
|
+
This matters because API contract output is part of the application configuration surface, not a fixed global constant.
|
|
90
|
+
|
|
91
|
+
## Relationship to frontend SDK generation
|
|
92
|
+
|
|
93
|
+
OpenAPI emission on the backend is the backend-contract-loop side of a broader fullstack contract bridge.
|
|
94
|
+
|
|
95
|
+
For the downstream bridge and consumption path, also see:
|
|
96
|
+
|
|
97
|
+
- [Backend OpenAPI to Frontend SDK](/fullstack/openapi-to-sdk)
|
|
98
|
+
- [OpenAPI SDK Guide](/frontend/openapi-sdk-guide)
|
|
99
|
+
|
|
100
|
+
A practical split is:
|
|
101
|
+
|
|
102
|
+
- this page explains backend contract authoring and emission
|
|
103
|
+
- the fullstack page explains the bridge from emitted OpenAPI to generated frontend SDK
|
|
104
|
+
- the frontend page explains how Zova consumes that contract in its own workflows
|
|
105
|
+
|
|
106
|
+
## Implementation checks for backend contract changes
|
|
107
|
+
|
|
108
|
+
When changing backend contracts, ask:
|
|
109
|
+
|
|
110
|
+
1. does this change affect Swagger/OpenAPI output?
|
|
111
|
+
2. do the controller, DTO, entity, and validation layers still agree on the contract?
|
|
112
|
+
3. does the frontend SDK or schema-driven frontend behavior need to be regenerated?
|
|
113
|
+
4. should metadata such as title, description, or examples be improved at the same time?
|
|
114
|
+
5. is this a place where validation and OpenAPI should be edited together rather than separately?
|
|
115
|
+
|
|
116
|
+
That helps keep the backend/frontend contract loop coherent.
|
|
117
|
+
|
|
118
|
+
Upload-oriented endpoints often combine multipart request handling with explicit response metadata such as `@Api.contentType('application/json')`; see [Upload Guide](/backend/upload-guide).
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
# ORM Aggregate and Group Guide
|
|
2
|
+
|
|
3
|
+
## Why aggregate and group matter
|
|
4
|
+
|
|
5
|
+
Many backend queries do not need raw rows only. They need derived results such as counts, sums, averages, grouped totals, or grouped summaries attached to related records.
|
|
6
|
+
|
|
7
|
+
Vona ORM provides aggregate and group operations as typed model-level capabilities rather than forcing every summary query into ad hoc SQL.
|
|
8
|
+
|
|
9
|
+
## `count`
|
|
10
|
+
|
|
11
|
+
The simplest aggregate is `count`.
|
|
12
|
+
|
|
13
|
+
Representative pattern:
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
const total = await this.scope.model.post.count();
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
A count operation can still depend on:
|
|
20
|
+
|
|
21
|
+
- `column`
|
|
22
|
+
- `distinct`
|
|
23
|
+
- `where`
|
|
24
|
+
- `joins`
|
|
25
|
+
|
|
26
|
+
So even the simplest summary query still participates in the wider ORM query model.
|
|
27
|
+
|
|
28
|
+
## `aggregate`
|
|
29
|
+
|
|
30
|
+
Use `aggregate` when the query should return one summary object.
|
|
31
|
+
|
|
32
|
+
Representative pattern:
|
|
33
|
+
|
|
34
|
+
```typescript
|
|
35
|
+
const result = await this.scope.model.post.aggregate({
|
|
36
|
+
aggrs: {
|
|
37
|
+
count: ['*', 'stars'],
|
|
38
|
+
sum: 'stars',
|
|
39
|
+
avg: 'stars',
|
|
40
|
+
min: 'stars',
|
|
41
|
+
max: 'stars',
|
|
42
|
+
},
|
|
43
|
+
});
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
A useful mental model is:
|
|
47
|
+
|
|
48
|
+
- `aggrs` declares which aggregate functions should run
|
|
49
|
+
- Vona infers the returned shape from the aggregate declaration
|
|
50
|
+
- `aggregate` returns one summary object rather than grouped rows
|
|
51
|
+
|
|
52
|
+
Representative parameter areas include:
|
|
53
|
+
|
|
54
|
+
- `aggrs`
|
|
55
|
+
- `distinct`
|
|
56
|
+
- `where`
|
|
57
|
+
- `joins`
|
|
58
|
+
|
|
59
|
+
## `group`
|
|
60
|
+
|
|
61
|
+
Use `group` when the query should return grouped rows instead of one summary object.
|
|
62
|
+
|
|
63
|
+
Representative pattern:
|
|
64
|
+
|
|
65
|
+
```typescript
|
|
66
|
+
const result = await this.scope.model.post.group({
|
|
67
|
+
groups: 'userId',
|
|
68
|
+
aggrs: {
|
|
69
|
+
count: '*',
|
|
70
|
+
sum: 'stars',
|
|
71
|
+
},
|
|
72
|
+
});
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Representative parameter areas include:
|
|
76
|
+
|
|
77
|
+
- `groups`
|
|
78
|
+
- `columns`
|
|
79
|
+
- `aggrs`
|
|
80
|
+
- `distinct`
|
|
81
|
+
- `where`
|
|
82
|
+
- `joins`
|
|
83
|
+
- `limit`
|
|
84
|
+
- `offset`
|
|
85
|
+
- `having`
|
|
86
|
+
- `orders`
|
|
87
|
+
|
|
88
|
+
This matters because grouped results are still part of the structured ORM query language, not a separate unmanaged SQL world.
|
|
89
|
+
|
|
90
|
+
A practical result-shape distinction is:
|
|
91
|
+
|
|
92
|
+
- `aggregate` returns one summary object
|
|
93
|
+
- `group` returns grouped rows keyed by the chosen group columns and aggregate aliases
|
|
94
|
+
|
|
95
|
+
## `having` and grouped ordering
|
|
96
|
+
|
|
97
|
+
Grouped queries often need filtering and ordering on derived fields.
|
|
98
|
+
|
|
99
|
+
Representative pattern:
|
|
100
|
+
|
|
101
|
+
```typescript
|
|
102
|
+
const result = await this.scope.model.post.group({
|
|
103
|
+
groups: 'userId',
|
|
104
|
+
aggrs: {
|
|
105
|
+
count: '*',
|
|
106
|
+
sum: 'stars',
|
|
107
|
+
},
|
|
108
|
+
having: {
|
|
109
|
+
count_all: {
|
|
110
|
+
_gt_: 20,
|
|
111
|
+
},
|
|
112
|
+
sum_stars: {
|
|
113
|
+
_gt_: 30,
|
|
114
|
+
_lt_: 50,
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
orders: [['count_all', 'desc']],
|
|
118
|
+
});
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
This is one of the reasons aggregate/group deserves dedicated documentation instead of being hidden inside a basic select page.
|
|
122
|
+
|
|
123
|
+
A practical alias rule is:
|
|
124
|
+
|
|
125
|
+
- aggregate aliases such as `count_all` and `sum_stars` become the names used in `having` and grouped ordering
|
|
126
|
+
|
|
127
|
+
That is also why grouped or summary outputs often deserve explicit DTO treatment once they become stable API contracts.
|
|
128
|
+
|
|
129
|
+
## Aggregate and group on relations
|
|
130
|
+
|
|
131
|
+
Aggregate and group are not limited to top-level model queries. They can also participate in relations.
|
|
132
|
+
|
|
133
|
+
### Dynamic relation example
|
|
134
|
+
|
|
135
|
+
Representative aggregate-on-relation pattern:
|
|
136
|
+
|
|
137
|
+
```typescript
|
|
138
|
+
const users = await this.scope.model.user.select({
|
|
139
|
+
with: {
|
|
140
|
+
posts: $relationDynamic.hasMany('test-vona:post', 'userId', {
|
|
141
|
+
aggrs: {
|
|
142
|
+
count: '*',
|
|
143
|
+
sum: 'stars',
|
|
144
|
+
},
|
|
145
|
+
}),
|
|
146
|
+
},
|
|
147
|
+
});
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
Representative group-on-relation pattern:
|
|
151
|
+
|
|
152
|
+
```typescript
|
|
153
|
+
const users = await this.scope.model.user.select({
|
|
154
|
+
with: {
|
|
155
|
+
posts: $relationDynamic.hasMany('test-vona:post', 'userId', {
|
|
156
|
+
groups: 'id',
|
|
157
|
+
aggrs: {
|
|
158
|
+
count: '*',
|
|
159
|
+
sum: 'stars',
|
|
160
|
+
},
|
|
161
|
+
}),
|
|
162
|
+
},
|
|
163
|
+
});
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### Static relation example
|
|
167
|
+
|
|
168
|
+
Representative static relation pattern:
|
|
169
|
+
|
|
170
|
+
```typescript
|
|
171
|
+
@Model({
|
|
172
|
+
entity: EntityUser,
|
|
173
|
+
relations: {
|
|
174
|
+
posts: $relation.hasMany('test-vona:post', 'userId', {
|
|
175
|
+
aggrs: {
|
|
176
|
+
count: '*',
|
|
177
|
+
sum: 'stars',
|
|
178
|
+
},
|
|
179
|
+
}),
|
|
180
|
+
},
|
|
181
|
+
})
|
|
182
|
+
class ModelUserStats {}
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
That means summary-shaped relations can still be expressed through model metadata instead of living outside the ORM relation system.
|
|
186
|
+
|
|
187
|
+
## Relationship to select and relations
|
|
188
|
+
|
|
189
|
+
Read this guide together with:
|
|
190
|
+
|
|
191
|
+
- [ORM Select Guide](/backend/orm-select-guide)
|
|
192
|
+
- [Relations Guide](/backend/relations-guide)
|
|
193
|
+
- [DTO Infer and Generation](/backend/dto-infer-generation)
|
|
194
|
+
|
|
195
|
+
A practical split is:
|
|
196
|
+
|
|
197
|
+
- use the select guide for row-oriented query structure and operators
|
|
198
|
+
- use this guide when the result shape is aggregate- or group-oriented
|
|
199
|
+
- use the relations guide when the summary is attached through relation metadata or dynamic relations
|
|
200
|
+
|
|
201
|
+
## Implementation checks for aggregate and grouped query changes
|
|
202
|
+
|
|
203
|
+
When editing summary-oriented backend queries, ask:
|
|
204
|
+
|
|
205
|
+
1. is this a row-oriented select, a one-object aggregate, or a grouped result set?
|
|
206
|
+
2. should the summary live at the top level or inside a relation?
|
|
207
|
+
3. do `having` and derived-field ordering belong in the group definition?
|
|
208
|
+
4. should DTO inference or OpenAPI output reflect the summary shape explicitly?
|
|
209
|
+
|
|
210
|
+
That helps AI keep statistical and reporting queries aligned with Vona’s typed ORM model.
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
# ORM Configuration Guide
|
|
2
|
+
|
|
3
|
+
## Why ORM configuration matters
|
|
4
|
+
|
|
5
|
+
Vona ORM is not only shaped by model code. It is also shaped by framework-level configuration in the `a-orm` module.
|
|
6
|
+
|
|
7
|
+
That matters because ORM behavior depends on more than query syntax alone:
|
|
8
|
+
|
|
9
|
+
- table identity strategy
|
|
10
|
+
- model defaults
|
|
11
|
+
- soft-deletion cleanup
|
|
12
|
+
- supported database dialects
|
|
13
|
+
- two-layer cache behavior
|
|
14
|
+
|
|
15
|
+
## Configure the `a-orm` module
|
|
16
|
+
|
|
17
|
+
ORM configuration lives under `config.modules['a-orm']`.
|
|
18
|
+
|
|
19
|
+
Representative pattern:
|
|
20
|
+
|
|
21
|
+
```typescript
|
|
22
|
+
config.modules = {
|
|
23
|
+
'a-orm': {
|
|
24
|
+
table: {
|
|
25
|
+
identityType: 'bigint',
|
|
26
|
+
},
|
|
27
|
+
softDeletionPrune: {
|
|
28
|
+
enable: true,
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
This is the main backend-level control surface for framework-wide ORM behavior.
|
|
35
|
+
|
|
36
|
+
## Main configuration areas
|
|
37
|
+
|
|
38
|
+
The most important ORM config areas are:
|
|
39
|
+
|
|
40
|
+
- `table`
|
|
41
|
+
- `model`
|
|
42
|
+
- `softDeletionPrune`
|
|
43
|
+
- `dialects`
|
|
44
|
+
- `summer`
|
|
45
|
+
|
|
46
|
+
A representative framework config shape is:
|
|
47
|
+
|
|
48
|
+
```typescript
|
|
49
|
+
config.modules = {
|
|
50
|
+
'a-orm': {
|
|
51
|
+
table: {
|
|
52
|
+
identityType: 'bigint',
|
|
53
|
+
},
|
|
54
|
+
model: {
|
|
55
|
+
disableDeleted: false,
|
|
56
|
+
disableInstance: false,
|
|
57
|
+
disableCreateTime: false,
|
|
58
|
+
disableUpdateTime: false,
|
|
59
|
+
},
|
|
60
|
+
softDeletionPrune: {
|
|
61
|
+
enable: true,
|
|
62
|
+
expired: 14 * 24 * 3600 * 1000,
|
|
63
|
+
},
|
|
64
|
+
dialects: {
|
|
65
|
+
mysql: 'a-ormdialect.databaseDialect.mysql',
|
|
66
|
+
mysql2: 'a-ormdialect.databaseDialect.mysql3',
|
|
67
|
+
pg: 'a-ormdialect.databaseDialect.pg',
|
|
68
|
+
},
|
|
69
|
+
summer: {
|
|
70
|
+
enable: true,
|
|
71
|
+
presetDefault: 'redis',
|
|
72
|
+
redis: {
|
|
73
|
+
client: 'model',
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
};
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## `table.identityType`
|
|
81
|
+
|
|
82
|
+
`table.identityType` controls the type of the primary `id` field, such as:
|
|
83
|
+
|
|
84
|
+
- `number`
|
|
85
|
+
- `bigint`
|
|
86
|
+
|
|
87
|
+
This matters because identity shape propagates into entity typing, DTO typing, and model-facing contracts.
|
|
88
|
+
|
|
89
|
+
## `model` defaults
|
|
90
|
+
|
|
91
|
+
The `model` block provides broad defaults for ORM behavior.
|
|
92
|
+
|
|
93
|
+
Representative concerns include:
|
|
94
|
+
|
|
95
|
+
- `disableDeleted`
|
|
96
|
+
- `disableInstance`
|
|
97
|
+
- `disableCreateTime`
|
|
98
|
+
- `disableUpdateTime`
|
|
99
|
+
|
|
100
|
+
A useful ownership rule is:
|
|
101
|
+
|
|
102
|
+
- model config establishes framework-wide defaults
|
|
103
|
+
- model metadata can specialize a specific model
|
|
104
|
+
- method options can still override behavior at the usage site when needed
|
|
105
|
+
|
|
106
|
+
That is why ORM behavior should be understood as layered configuration rather than as one fixed decorator-only setting.
|
|
107
|
+
|
|
108
|
+
## `softDeletionPrune`
|
|
109
|
+
|
|
110
|
+
Soft deletion is not only about marking a row as deleted. It also has a cleanup lifecycle.
|
|
111
|
+
|
|
112
|
+
The `softDeletionPrune` block controls:
|
|
113
|
+
|
|
114
|
+
- whether prune is enabled
|
|
115
|
+
- how long deleted data is retained before prune
|
|
116
|
+
|
|
117
|
+
This matters because teams often need a deliberate retention window for recoverability, audits, or operational cleanup.
|
|
118
|
+
|
|
119
|
+
## `dialects`
|
|
120
|
+
|
|
121
|
+
The `dialects` block defines the supported database dialect adapters.
|
|
122
|
+
|
|
123
|
+
This is important because ORM behavior is framework-level and must remain portable across different backend database engines rather than assuming one hardcoded SQL target.
|
|
124
|
+
|
|
125
|
+
## `summer` and two-layer cache behavior
|
|
126
|
+
|
|
127
|
+
The `summer` block controls two-layer cache behavior for ORM workloads.
|
|
128
|
+
|
|
129
|
+
Representative concerns include:
|
|
130
|
+
|
|
131
|
+
- whether cache is enabled
|
|
132
|
+
- which preset is the default
|
|
133
|
+
- which Redis client should back the model cache path
|
|
134
|
+
|
|
135
|
+
This matters because ORM query behavior, cache behavior, and invalidation expectations are part of one data-system design.
|
|
136
|
+
|
|
137
|
+
For surrounding cache concepts, also see [Cache Guide](/backend/cache-guide).
|
|
138
|
+
|
|
139
|
+
## Relationship to model and query behavior
|
|
140
|
+
|
|
141
|
+
Read this guide together with:
|
|
142
|
+
|
|
143
|
+
- [ORM Guide](/backend/orm-guide)
|
|
144
|
+
- [Model Guide](/backend/model-guide)
|
|
145
|
+
- [ORM Select Guide](/backend/orm-select-guide)
|
|
146
|
+
- [ORM Mutation Guide](/backend/orm-mutation-guide)
|
|
147
|
+
- [Cache Guide](/backend/cache-guide)
|
|
148
|
+
- [Multi-Database and Datasource Guide](/backend/multi-database-datasource)
|
|
149
|
+
|
|
150
|
+
A practical split is:
|
|
151
|
+
|
|
152
|
+
- ORM configuration defines framework-wide defaults and infrastructure behavior
|
|
153
|
+
- model metadata defines model-local behavior
|
|
154
|
+
- select/mutation calls decide the per-operation query and write shape
|
|
155
|
+
|
|
156
|
+
## Implementation checks for ORM configuration changes
|
|
157
|
+
|
|
158
|
+
When editing ORM-sensitive backend code, ask:
|
|
159
|
+
|
|
160
|
+
1. is this behavior controlled by app-level ORM config, model metadata, or a usage-site option?
|
|
161
|
+
2. does the change affect identity type, soft deletion, or timestamp behavior?
|
|
162
|
+
3. does the cache path depend on `summer` settings?
|
|
163
|
+
4. does a database-engine assumption actually belong in the dialect layer instead?
|
|
164
|
+
|
|
165
|
+
That helps AI keep ORM behavior aligned with Vona’s layered configuration model.
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
# ORM Guide
|
|
2
|
+
|
|
3
|
+
## Why Vona ORM matters
|
|
4
|
+
|
|
5
|
+
Vona ORM is an intuitive and powerful ORM engine built around TypeScript, strong typing, and dynamic DTO inference.
|
|
6
|
+
|
|
7
|
+
For the Cabloy docs, the most important takeaway is that Vona ORM is not just a thin query wrapper. It is a framework-level data system that connects:
|
|
8
|
+
|
|
9
|
+
- models and entities
|
|
10
|
+
- query behavior
|
|
11
|
+
- mutation behavior
|
|
12
|
+
- relationships
|
|
13
|
+
- caching
|
|
14
|
+
- multi-datasource support
|
|
15
|
+
- transactions
|
|
16
|
+
- DTO inference and generation
|
|
17
|
+
- frontend integration through OpenAPI and generated contracts
|
|
18
|
+
|
|
19
|
+
## Core capabilities
|
|
20
|
+
|
|
21
|
+
Its core ORM capabilities include:
|
|
22
|
+
|
|
23
|
+
- multiple databases and multiple datasources
|
|
24
|
+
- dynamic datasource support
|
|
25
|
+
- sharded databases and tables
|
|
26
|
+
- read-write separation
|
|
27
|
+
- dynamic DTO inference and generation
|
|
28
|
+
- aggregate and grouping queries
|
|
29
|
+
- static and dynamic relationships
|
|
30
|
+
- query cache and entity cache
|
|
31
|
+
- transaction and transaction-propagation support
|
|
32
|
+
- transaction compensation for data and cache consistency
|
|
33
|
+
|
|
34
|
+
## Recommended ORM reading path
|
|
35
|
+
|
|
36
|
+
Use this page as the ORM overview, then move into the deeper leaves in roughly this order:
|
|
37
|
+
|
|
38
|
+
1. [Model Guide](/backend/model-guide)
|
|
39
|
+
2. [Entity Guide](/backend/entity-guide)
|
|
40
|
+
3. [ORM Configuration Guide](/backend/orm-configuration-guide)
|
|
41
|
+
4. [ORM Select Guide](/backend/orm-select-guide)
|
|
42
|
+
5. [ORM Mutation Guide](/backend/orm-mutation-guide)
|
|
43
|
+
6. [Relations Guide](/backend/relations-guide)
|
|
44
|
+
7. [ORM Aggregate and Group Guide](/backend/orm-aggregate-group-guide)
|
|
45
|
+
8. [DTO Guide](/backend/dto-guide)
|
|
46
|
+
9. [DTO Infer and Generation](/backend/dto-infer-generation)
|
|
47
|
+
10. [Transaction Guide](/backend/transaction-guide)
|
|
48
|
+
11. [Cache Guide](/backend/cache-guide)
|
|
49
|
+
12. [Multi-Database and Datasource Guide](/backend/multi-database-datasource)
|
|
50
|
+
13. [Dynamic Datasource Guide](/backend/dynamic-datasource-guide)
|
|
51
|
+
14. [Sharding Guide](/backend/sharding-guide)
|
|
52
|
+
|
|
53
|
+
Use [Dynamic Datasource Guide](/backend/dynamic-datasource-guide) as a backend-facing pointer page into deeper Cabloy datasource architecture, not as a parallel full ORM tutorial.
|
|
54
|
+
|
|
55
|
+
This keeps the overview page focused while pushing depth into the pages that own each concern.
|
|
56
|
+
|
|
57
|
+
## The main ORM concern clusters
|
|
58
|
+
|
|
59
|
+
A useful mental model is to treat Vona ORM as several connected concern clusters:
|
|
60
|
+
|
|
61
|
+
### Structure cluster
|
|
62
|
+
|
|
63
|
+
- entities define persistence-facing fields
|
|
64
|
+
- models define data behavior and relationships
|
|
65
|
+
- ORM config defines framework-wide defaults
|
|
66
|
+
|
|
67
|
+
### Query cluster
|
|
68
|
+
|
|
69
|
+
- select operations shape row-oriented reads
|
|
70
|
+
- aggregate/group operations shape summary-oriented reads
|
|
71
|
+
- static and dynamic relations shape cross-model retrieval
|
|
72
|
+
|
|
73
|
+
### Write cluster
|
|
74
|
+
|
|
75
|
+
- insert/update/delete express explicit write intent
|
|
76
|
+
- mutate/mutateBulk provide higher-level write inference
|
|
77
|
+
- relation-aware writes support nested CRUD workflows
|
|
78
|
+
|
|
79
|
+
### Infrastructure cluster
|
|
80
|
+
|
|
81
|
+
- transactions protect consistency
|
|
82
|
+
- cache affects query and entity behavior
|
|
83
|
+
- datasource selection affects routing, isolation, and scale
|
|
84
|
+
- sharding and advanced topology move the ORM into larger-system architecture
|
|
85
|
+
|
|
86
|
+
## Relationship to fullstack contracts
|
|
87
|
+
|
|
88
|
+
ORM is closely connected to DTO inference, OpenAPI, and frontend-facing contract generation.
|
|
89
|
+
|
|
90
|
+
That means backend data modeling is not an isolated persistence concern. It also shapes:
|
|
91
|
+
|
|
92
|
+
- controller contracts
|
|
93
|
+
- generated SDKs
|
|
94
|
+
- relation-aware DTOs
|
|
95
|
+
- aggregate/group result contracts
|
|
96
|
+
|
|
97
|
+
## Implementation checks for ORM changes
|
|
98
|
+
|
|
99
|
+
Vona ORM should be treated as a knowledge hub rather than as an implementation detail.
|
|
100
|
+
|
|
101
|
+
When changing backend data logic, ask:
|
|
102
|
+
|
|
103
|
+
1. is this a model/entity/DTO problem rather than a raw SQL problem?
|
|
104
|
+
2. does the change affect query shape, mutation semantics, relation behavior, or summary shape?
|
|
105
|
+
3. does the change affect caching, transactions, or datasource behavior?
|
|
106
|
+
4. should DTO inference or OpenAPI generation be updated as a consequence?
|
|
107
|
+
5. does frontend integration depend on the ORM-facing contract shape?
|
|
108
|
+
|
|
109
|
+
That perspective produces more Cabloy-native results.
|