HBASE-21507 Compaction failed when execute AbstractMultiFileWriter.beforeShipped() method
Signed-off-by: zhangduo <zhangduo@apache.org> Signed-off-by: Anoop Sam John <anoop.hbase@gmail.com>
This commit is contained in:
parent
34e1d744f7
commit
3133d43859
|
@ -21,12 +21,10 @@ import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.apache.hadoop.fs.Path;
|
import org.apache.hadoop.fs.Path;
|
||||||
import org.apache.yetus.audience.InterfaceAudience;
|
import org.apache.yetus.audience.InterfaceAudience;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.apache.hadoop.hbase.regionserver.CellSink;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base class for cell sink that separates the provided cells into multiple files.
|
* Base class for cell sink that separates the provided cells into multiple files.
|
||||||
|
@ -119,10 +117,13 @@ public abstract class AbstractMultiFileWriter implements CellSink, ShipperListen
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void beforeShipped() throws IOException {
|
public void beforeShipped() throws IOException {
|
||||||
if (this.writers() != null) {
|
Collection<StoreFileWriter> writers = writers();
|
||||||
for (StoreFileWriter writer : writers()) {
|
if (writers != null) {
|
||||||
|
for (StoreFileWriter writer : writers) {
|
||||||
|
if (writer != null) {
|
||||||
writer.beforeShipped();
|
writer.beforeShipped();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue