After merging #21469, SharedClusterSnapshotRestoreIT fails on CI regularly [1], though never for me locally. It might be a cleanup issue with the test. I am using this issue to track a fix.
[1] https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+java9-periodic/619/console