smiroslav commented on PR #1204: URL: https://github.com/apache/jackrabbit-oak/pull/1204#issuecomment-1808411734
> I am wondering what happens if: > > * instance 1 loses the lease > * instance 2 gets it and writes happily > * instance 1 waits in `checkWritingAllowed()` > * instance 2 terminates > * instance 1 gets the lease and writes everything it had queued up > Or is that not a possible scenario? @ahanikel that should not be possible In the test below, I have tried to renew the lease after it has expired and in the meantime, new lease created (and expired as well) ``` $ az storage blob lease acquire --account-name smiljani -b repo.lock -c oak --lease-duration 15 "803fedca-09cd-4c43-b026-58297c12c66a" $ az storage blob lease renew --account-name smiljani -b repo.lock -c oak --lease-id 803fedca-09cd-4c43-b026-58297c12c66a "803fedca-09cd-4c43-b026-58297c12c66a" $ az storage blob lease acquire --account-name smiljani -b repo.lock -c oak --lease-duration 15 "9edaa378-934c-4843-b4b1-595763b62772" $ az storage blob lease renew --account-name smiljani -b repo.lock -c oak --lease-id 803fedca-09cd-4c43-b026-58297c12c66a The lease ID specified did not match the lease ID for the blob. RequestId:0f20142b-701e-0080-7547-164489000000 Time:2023-11-13T15:39:35.6274726Z ErrorCode:LeaseIdMismatchWithLeaseOperation ``` -- 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]
