null check for writer if not initialized yet during syncrunner run
This commit is contained in:
parent
8191fbdd7d
commit
72932ad0df
|
@ -594,9 +594,11 @@ public class FSHLog extends AbstractFSWAL<Writer> {
|
||||||
long start = System.nanoTime();
|
long start = System.nanoTime();
|
||||||
Throwable lastException = null;
|
Throwable lastException = null;
|
||||||
try {
|
try {
|
||||||
TraceUtil.addTimelineAnnotation("syncing writer");
|
if(writer != null) {
|
||||||
writer.sync(sf.isForceSync());
|
TraceUtil.addTimelineAnnotation("syncing writer");
|
||||||
TraceUtil.addTimelineAnnotation("writer synced");
|
writer.sync(sf.isForceSync());
|
||||||
|
TraceUtil.addTimelineAnnotation("writer synced");
|
||||||
|
}
|
||||||
currentSequence = updateHighestSyncedSequence(currentSequence);
|
currentSequence = updateHighestSyncedSequence(currentSequence);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOG.error("Error syncing, request close of WAL", e);
|
LOG.error("Error syncing, request close of WAL", e);
|
||||||
|
|
Loading…
Reference in New Issue