Ship the bundle's own Doctrine migrations, so apps don't generate them
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 35/100
Hướng nghiên cứu
Start by reading the bundle's Doctrine entity mappings and the existing migration configuration to identify the tables and migration entry points involved. The proposal leaves baseline strategy, adoption by existing apps, supported database platforms, and ordering unresolved, so those decisions need to be settled before implementation. Done means the bundle ships migrations for its mapped schema and apps can adopt them without regenerating those migrations locally.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Proposal
The bundle ships Doctrine migrations for its own schema: every table its entities map. Apps then receive them with composer update, through doctrine_migrations.migrations_paths with a bundle namespace.
Why
Almost every table in a CWA app belongs to the bundle's entities. Today each app generates migrations for them itself (doctrine:migrations:diff after updating the bundle), and the template's downstream sites copy the template's generated files. That causes three problems:
- Data migrations aren't shared:
diffonly produces schema changes, so a backfill the bundle needs has to be copied by hand. - Sites drift: each app's generated SQL can differ slightly from the next.
- Every bundle schema change needs a template release and a copy step in every downstream site.
If the bundle shipped them, the template would only need migrations for its own entities (today just the Redis watch state). It would also make squashing the template's history at beta simpler: https://github.com/components-web-app/components-web-app/issues/192
Questions for the bundle
- One baseline at the bundle's beta, then incremental migrations?
- How existing apps take over: their databases already have these tables from their own generated migrations. They'd mark the bundle's baseline as done (
doctrine:migrations:version --add) once, after checkingdiffis clean. - Database platforms: PostgreSQL first? The bundle already lists PostgreSQL, MySQL, MariaDB and SQLite for route-security rules.
- Ordering between bundle migrations and an app's own (Doctrine sorts by version across namespaces).
- Ngôn ngữ chính
- PHP
- Star
- 32
- Fork
- 8
- Merge trung bình
- 1 giờ 1 phút
- Pull request đã merge (30 ngày)
- 193
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của components-web-app/api-components-bundle
-
Real-time co-editing: presence and selection events for admins over MercureCó thể đã có người làm @silverbackdan đã nhận hôm nay. Đang mởenhancement
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 20/100
components-web-app/api-components-bundle#559 · 4 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 30/100
components-web-app/api-components-bundle#333 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
components-web-app/api-components-bundle#325 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
components-web-app/api-components-bundle#259 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
components-web-app/api-components-bundle#186 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của components-web-app/api-components-bundle
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
MagnaCapax/PMSS#1142 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
bug 🐛
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
netalertx/NetAlertX#1856 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Bug Status: Needs Triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
feature good first issue html mcv php
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
lorisleiva/laravel-docker#166 ·