tju-yxq opened a new pull request, #2527:
URL: https://github.com/apache/rocketmq-dashboard/pull/2527

   ## Summary
   
   The documented demo-data scripts still used the table and ID contracts from 
before the numeric-schema refactor. In particular, the instance loader failed 
on the current schema because it referenced `rmq_topic` and `rmq_group`.
   
   This change:
   
   - turns the instance and ACL files into explicit development-only data 
loaders rather than schema migrations;
   - lets MySQL allocate numeric IDs;
   - resolves topic and consumer-group `instance_id` values through the stable 
instance name;
   - writes to `rmq_instance_topic` and `rmq_instance_group`;
   - keeps repeated imports idempotent without replacing existing ACL 
credentials or logically matching rules;
   - aligns the alert compatibility helper with numeric IDs and `gmt_create` / 
`gmt_modified`;
   - documents the import order and production warning;
   - adds a schema-backed test that runs all three helpers twice and checks row 
counts, numeric IDs, and orphaned metadata.
   
   The deployment/configuration change is 372 additions and 211 deletions 
before tests, so the size comes from replacing the obsolete SQL contract rather 
than test padding.
   
   Closes #2526.
   
   ## Verification
   
   - Reproduced the old instance script failure against MySQL 8.0: error 1146 
for missing `rmq_topic`.
   - Loaded the canonical schema into MySQL 8.0, ran the new instance and ACL 
scripts twice, and verified:
     - 5 instances
     - 19 topics
     - 17 consumer groups
     - 13 ACL rules
     - 8 ACL users
     - 0 orphaned topic/group `instance_id` values
     - numeric auto-increment IDs
   - Ran the alert helper twice against an empty MySQL 8.0 database and 
verified canonical numeric/timestamp columns.
   - `mvn -Dtest=DemoDataSqlCompatibilityTest test`: 2 tests passed, Checkstyle 
0 violations.
   - `mvn test`: 1,528 tests passed, Checkstyle 0 violations.
   - `git diff --check` passed.
   


-- 
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]

Reply via email to