Commit 27e0449
committed
fix(restore_test): refresh permissions between table creation
TestRestoreFullChangingMethodIntegration behaved flaky recently.
Even though a few initial restore table could succeed, it could
fail on the last one on permissions' error.
In this test, we drop and re-create the tables constantly.
This also drops their permissions configuration.
The test worked because the same user also re-created those
tables and was granted all their permissions by default.
It might be that such permissions are not instantly
propagated to all other nodes and depending on which node
the alter schema query is routed to, the test might fail.
To fix that, we could either make an explicit raft read barrier
on all nodes, or just re-apply the needed permissions,
as explicit permissions changes also result in raft read barrier
being performed underneath. I chose the second approach,
because it requires only a single API call and is more explicit
in terms of what permissions are expected from the restore user
instead of relying on the default permissions granted on schema restore.1 parent 664af2d commit 27e0449
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
278 | 278 | | |
279 | 279 | | |
280 | 280 | | |
281 | | - | |
282 | 281 | | |
283 | 282 | | |
284 | 283 | | |
| |||
305 | 304 | | |
306 | 305 | | |
307 | 306 | | |
| 307 | + | |
308 | 308 | | |
309 | 309 | | |
310 | 310 | | |
| |||
0 commit comments