Skip to content

Commit 9371b9d

Browse files
author
dapeng
committed
记录脏数据
1 parent 28ae888 commit 9371b9d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

hbase/hbase-sink/src/main/java/com/dtstack/flink/sql/sink/hbase/HbaseOutputFormat.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,12 +166,13 @@ public void writeRecord(Tuple2 tuple2) {
166166
protected void dealInsert(Row record) {
167167
Put put = getPutByRow(record);
168168
if (put == null || put.isEmpty()) {
169+
outDirtyRecords.inc();
169170
return;
170171
}
171172

172173
try {
173174
table.put(put);
174-
} catch (IOException e) {
175+
} catch (Exception e) {
175176
if (outDirtyRecords.getCount() % DIRTY_PRINT_FREQUENCY == 0 || LOG.isDebugEnabled()) {
176177
LOG.error("record insert failed ..{}", record.toString());
177178
LOG.error("", e);

0 commit comments

Comments
 (0)