yuqi1129 opened a new pull request, #11815: URL: https://github.com/apache/gravitino/pull/11815
### What changes were proposed in this pull request? This PR updates the built-in IdP MySQL soft-delete timestamp expression to include millisecond precision for: - IdP user metadata - IdP group metadata - IdP user-group relation metadata It also adds provider-level regression tests to make sure these soft-delete SQL statements keep the millisecond component. ### Why are the changes needed? The IdP metadata tables use unique keys that include `deleted_at`, for example `(user_name, deleted_at)` on `idp_user_meta`. The previous MySQL expression used only: ```sql UNIX_TIMESTAMP() * 1000.0 ``` In practice this can produce second-level effective values such as `...000`. If tests or clients delete, recreate, and delete the same IdP user/group/relation within the same second, the second soft delete can hit a duplicate key error. This caused the observed flaky `IdpRESTApiIT` failure in `IdP Basic Test`. Fix: N/A ### Does this PR introduce _any_ user-facing change? No. This only changes internal relational metadata soft-delete timestamp precision for the built-in IdP plugin. ### How was this patch tested? - `env SKIP_DOCKER_TESTS=true ./gradlew :plugins:idp-basic:test -PskipITs -PskipDockerTests=true` - `./gradlew :plugins:idp-basic:test -PtestMode=embedded -PjdbcBackend=mysql -PskipDockerTests=false --tests org.apache.gravitino.idp.integration.test.IdpRESTApiIT` - `./gradlew :plugins:idp-basic:spotlessApply` - `git diff --check` -- 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]
