dengliming opened a new pull request, #7249: URL: https://github.com/apache/shenyu/pull/7249
## Summary - Wrap single upstream create/update in a transaction, rolling database changes back when synchronization throws. - Move batch create/update into one transactional service call instead of separate controller-level writes. - Write the whole batch before synchronizing, refreshing each affected handler once. - Add H2 regression tests for failed create, failed update, mid-batch insert failure and synchronization failure; verify controller delegation. Fixes #6698 ## Validation - `./mvnw -pl shenyu-admin -am -DskipTests=false -Dcheckstyle.skip=false -Dtest=DiscoveryUpstreamServiceTest,DiscoveryUpstreamControllerTest,UpstreamWriteIntegrationTest -DfailIfNoTests=false test` (Java 17): passed, including Checkstyle. This provides database atomicity on exceptions, not a distributed transaction with discovery providers. An external provider that partially applies changes before throwing still requires reconciliation. -- 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]
