mirror of
https://github.com/Febbweiss/logstash-forwarder-java.git
synced 2026-03-05 06:35:44 +00:00
Solve problem with sincedb.
This commit is contained in:
@@ -49,12 +49,6 @@ public class FileWatcher {
|
|||||||
private String sincedbFile = null;
|
private String sincedbFile = null;
|
||||||
|
|
||||||
public FileWatcher() {
|
public FileWatcher() {
|
||||||
try {
|
|
||||||
logger.debug("Loading saved states");
|
|
||||||
savedStates = Registrar.readStateFromJson(sincedbFile);
|
|
||||||
} catch(Exception e) {
|
|
||||||
logger.warn("Could not load saved states : " + e.getMessage(), e);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void initialize() throws IOException {
|
public void initialize() throws IOException {
|
||||||
@@ -366,6 +360,12 @@ public class FileWatcher {
|
|||||||
|
|
||||||
public void setSincedb(String sincedbFile) {
|
public void setSincedb(String sincedbFile) {
|
||||||
this.sincedbFile = sincedbFile;
|
this.sincedbFile = sincedbFile;
|
||||||
|
try {
|
||||||
|
logger.debug("Loading saved states");
|
||||||
|
savedStates = Registrar.readStateFromJson(sincedbFile);
|
||||||
|
} catch(Exception e) {
|
||||||
|
logger.warn("Could not load saved states : " + e.getMessage(), e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user