chore(mon_dir): refactored

This commit is contained in:
dancingCycle 2021-12-01 09:18:46 -05:00
parent e95f283e8c
commit 7bfc152906
1 changed files with 1 additions and 4 deletions

View File

@ -11,8 +11,6 @@ public class Main {
private static final String FOLDER = "/opt/npm";
private static final String FILE = "/opt/npm/NetPeerManager.log";
public static void main(String[] args) throws IOException,
InterruptedException {
LOG.trace("app started...");
@ -24,7 +22,6 @@ public class Main {
WatchService watchService = FileSystems.getDefault().newWatchService();
//register a Path instance for events using a WatchService instance
//TODO You cannot watch a file this way! java.nio.file.NotDirectoryException
folderPath.register(watchService, StandardWatchEventKinds.ENTRY_CREATE,
StandardWatchEventKinds.ENTRY_MODIFY,
StandardWatchEventKinds.ENTRY_DELETE);
@ -57,4 +54,4 @@ public class Main {
LOG.trace("app done.");
}
}
}