This is an automated email from the ASF dual-hosted git repository.
symat pushed a commit to branch branch-3.5
in repository https://gitbox.apache.org/repos/asf/zookeeper.git
The following commit(s) were added to refs/heads/branch-3.5 by this push:
new 35f7a8e ZOOKEEPER-3739: Remove use of
com.sun.nio.file.SensitivityWatchEventModifier
35f7a8e is described below
commit 35f7a8e037d2f3b5e699f4c6ce1da869b8fe6b3f
Author: Christopher Tubbs <[email protected]>
AuthorDate: Tue Apr 28 20:44:59 2020 +0000
ZOOKEEPER-3739: Remove use of com.sun.nio.file.SensitivityWatchEventModifier
3.5 backport of #1269
Author: Christopher Tubbs <[email protected]>
Reviewers: Andor Molnar <[email protected]>, Enrico Olivelli
<[email protected]>, Mate Szalay-Beko <[email protected]>
Closes #1340 from anmolnar/ZOOKEEPER-3215_35
---
pom.xml | 22 +++++++++++++++++++++-
.../apache/zookeeper/common/FileChangeWatcher.java | 5 +----
2 files changed, 22 insertions(+), 5 deletions(-)
diff --git a/pom.xml b/pom.xml
index ef926c0..bb737ab 100755
--- a/pom.xml
+++ b/pom.xml
@@ -259,6 +259,26 @@
<activeByDefault>true</activeByDefault>
</activation>
</profile>
+ <profile>
+ <id>m2e</id>
+ <activation>
+ <property>
+ <name>m2e.version</name>
+ </property>
+ </activation>
+ <properties>
+ <maven.compiler.release>8</maven.compiler.release>
+ </properties>
+ </profile>
+ <profile>
+ <id>jdk-release-flag</id>
+ <activation>
+ <jdk>[9,)</jdk>
+ </activation>
+ <properties>
+ <maven.compiler.release>8</maven.compiler.release>
+ </properties>
+ </profile>
</profiles>
<properties>
@@ -457,7 +477,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
- <version>3.8.0</version>
+ <version>3.8.1</version>
<configuration>
<showWarnings>true</showWarnings>
<compilerArgs>
diff --git
a/zookeeper-server/src/main/java/org/apache/zookeeper/common/FileChangeWatcher.java
b/zookeeper-server/src/main/java/org/apache/zookeeper/common/FileChangeWatcher.java
index 8b49be9..2857063 100644
---
a/zookeeper-server/src/main/java/org/apache/zookeeper/common/FileChangeWatcher.java
+++
b/zookeeper-server/src/main/java/org/apache/zookeeper/common/FileChangeWatcher.java
@@ -18,11 +18,9 @@
package org.apache.zookeeper.common;
-import com.sun.nio.file.SensitivityWatchEventModifier;
import org.apache.zookeeper.server.ZooKeeperThread;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-
import java.io.IOException;
import java.nio.file.ClosedWatchServiceException;
import java.nio.file.FileSystem;
@@ -78,8 +76,7 @@ public final class FileChangeWatcher {
StandardWatchEventKinds.ENTRY_CREATE,
StandardWatchEventKinds.ENTRY_DELETE,
StandardWatchEventKinds.ENTRY_MODIFY,
- StandardWatchEventKinds.OVERFLOW},
- SensitivityWatchEventModifier.HIGH);
+ StandardWatchEventKinds.OVERFLOW});
state = State.NEW;
this.watcherThread = new WatcherThread(watchService, callback);
this.watcherThread.setDaemon(true);