You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2019/10/31 17:37:21 UTC
[hbase] branch branch-2 updated (87b4cfa -> 5521057)
This is an automated email from the ASF dual-hosted git repository.
stack pushed a change to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git.
from 87b4cfa Revert "HBASE-23191 EOFE log spam (#733)"
new 97644e2 Revert "Revert "HBASE-23191 EOFE log spam (#733)"" Reapply. Reverted wrong commit.
new 5521057 Revert "HBASE-22917 Proc-WAL roll fails saying someone else has already created log (#544)"
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../procedure2/store/wal/WALProcedureStore.java | 36 +++-------------------
.../hbase/regionserver/wal/ProtobufLogReader.java | 2 +-
2 files changed, 6 insertions(+), 32 deletions(-)
[hbase] 01/02: Revert "Revert "HBASE-23191 EOFE log spam (#733)""
Reapply. Reverted wrong commit.
Posted by st...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
stack pushed a commit to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git
commit 97644e20bb580d307dbd97b901719a7827b22476
Author: stack <st...@apache.org>
AuthorDate: Thu Oct 31 10:35:39 2019 -0700
Revert "Revert "HBASE-23191 EOFE log spam (#733)""
Reapply. Reverted wrong commit.
This reverts commit 87b4cfabdaeac6e1b04ad724b9db1dcd03c00633.
---
.../org/apache/hadoop/hbase/regionserver/wal/ProtobufLogReader.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/ProtobufLogReader.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/ProtobufLogReader.java
index f2be93e..96be61c 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/ProtobufLogReader.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/wal/ProtobufLogReader.java
@@ -418,7 +418,7 @@ public class ProtobufLogReader extends ReaderBase {
"current position and original position match at {}", originalPosition);
seekOnFs(0);
} else {
- LOG.info("Reached the end of file at position {}", originalPosition);
+ LOG.debug("Reached the end of file at position {}", originalPosition);
}
} else {
// Else restore our position to original location in hope that next time through we will
[hbase] 02/02: Revert "HBASE-22917 Proc-WAL roll fails saying
someone else has already created log (#544)"
Posted by st...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
stack pushed a commit to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git
commit 55210571c2bee63a26dc9e63811d198276b0f6e4
Author: stack <st...@apache.org>
AuthorDate: Thu Oct 31 10:37:08 2019 -0700
Revert "HBASE-22917 Proc-WAL roll fails saying someone else has already created log (#544)"
This reverts commit 834f7bf97008d4b4825ee18b92715809f9764c1a.
---
.../procedure2/store/wal/WALProcedureStore.java | 36 +++-------------------
1 file changed, 5 insertions(+), 31 deletions(-)
diff --git a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java
index 7e5a038..ae1088a 100644
--- a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java
+++ b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java
@@ -421,10 +421,9 @@ public class WALProcedureStore extends ProcedureStoreBase {
}
// Create new state-log
- long newFlushLogId = flushLogId + 1;
- if (!rollWriter(newFlushLogId)) {
+ if (!rollWriter(flushLogId + 1)) {
// someone else has already created this log
- LOG.debug("Someone else has already created log {}. Retrying.", newFlushLogId);
+ LOG.debug("Someone else has already created log {}. Retrying.", flushLogId);
continue;
}
@@ -1043,9 +1042,8 @@ public class WALProcedureStore extends ProcedureStoreBase {
}
// Create new state-log
- long newFlushLogId = flushLogId + 1;
- if (!rollWriter(newFlushLogId)) {
- LOG.warn("someone else has already created log {}", newFlushLogId);
+ if (!rollWriter(flushLogId + 1)) {
+ LOG.warn("someone else has already created log {}", flushLogId);
return false;
}
@@ -1102,8 +1100,7 @@ public class WALProcedureStore extends ProcedureStoreBase {
startPos = newStream.getPos();
} catch (IOException ioe) {
LOG.warn("Encountered exception writing header", ioe);
- // Close and delete the incomplete file
- closeAndDeleteIncompleteFile(newStream, newLogFile);
+ newStream.close();
return false;
}
@@ -1168,29 +1165,6 @@ public class WALProcedureStore extends ProcedureStoreBase {
stream = null;
}
- private void closeAndDeleteIncompleteFile(FSDataOutputStream newStream, Path newLogFile) {
- // Close the FS
- try {
- newStream.close();
- } catch (IOException e) {
- LOG.error("Exception occured while closing the file {}", newLogFile, e);
- }
-
- // Delete the incomplete file
- try {
- if (!fs.delete(newLogFile, false)) {
- LOG.warn(
- "Failed to delete the log file {}, increasing the log id by 1 for the next roll attempt",
- newLogFile);
- flushLogId++;
- }
- } catch (IOException e) {
- LOG.warn("Exception occured while deleting the file {}", newLogFile, e);
- flushLogId++;
- LOG.info("Increased the log id to {}", flushLogId);
- }
- }
-
// ==========================================================================
// Log Files cleaner helpers
// ==========================================================================