private void unregister(FileWatchRegisterKey watchRegisterKey) {
            if (!currWatchEventMap.containsKey(watchRegisterKey)) {
                return;
            }
            final FileWatchEvent fileWatchEvent = currWatchEventMap.remove(watchRegisterKey);
            final boolean existsDirWatcher = currWatchEventMap.values().stream().anyMatch(
                    value -> value.dirPath().equals(fileWatchEvent.dirPath()));
            if (!existsDirWatcher) {
                fileWatchEvent.cancel();
            }
            if (currWatchEventMap.isEmpty()) {
                restartableThread.stop();
            }
        }
Unregisters a {@link FileWatchRegisterKey}. The {@code callback} won't be invoked anymore when the
contents of the file for the {@code filePath} is changed. If no paths are watched by the
{@link WatchService}, then the background thread is stopped.
@param watchRegisterKey the key for which the {@link WatchService} will stop watching.
core/src/main/java/com/linecorp/armeria/client/endpoint/FileWatcherRegistry.java