@Override public synchronized void close() throws IOException { super.close(); DataOutputStream out = fs.create(new Path(dir, BLOOM_FILE_NAME), true); try { bloomFilter.write(out); out.flush(); out.close(); out = null; } finally { IOUtils.closeStream(out); } }
@Override public synchronized void close() throws IOException { super.close(); DataOutputStream out = fs.create(new Path(dir, BLOOM_FILE_NAME), true); bloomFilter.write(out); out.flush(); out.close(); }
public void close() { try { for (MapFile.Writer w : writers) { w.close(); } } catch (Exception e) { throw new RuntimeException(e); } finally { isClosed.set(true); } } }
@Override public synchronized void close() throws IOException { super.close(); DataOutputStream out = fs.create(new Path(dir, BLOOM_FILE_NAME), true); try { bloomFilter.write(out); out.flush(); out.close(); out = null; } finally { IOUtils.closeStream(out); } }
public void close(TaskAttemptContext context) throws IOException { out.close(); } };
public void close(TaskAttemptContext context) throws IOException { out.close(); } };
private static void createMapFile(Configuration conf, FileSystem fs, Path path, CompressionCodec codec, CompressionType type, int records) throws IOException { MapFile.Writer writer = new MapFile.Writer(conf, path, MapFile.Writer.keyClass(Text.class), MapFile.Writer.valueClass(Text.class), MapFile.Writer.compression(type, codec)); Text key = new Text(); for (int j = 0; j < records; j++) { key.set(String.format("%03d", j)); writer.append(key, key); } writer.close(); }
public void close(TaskAttemptContext context) throws IOException { out.close(); } };
public void close(TaskAttemptContext context) throws IOException { out.close(); } };
private void close() throws IOException { for (int i = 0; i < inReaders.length; i++) { IOUtils.closeStream(inReaders[i]); inReaders[i] = null; } if (outWriter != null) { outWriter.close(); outWriter = null; } } }
public void close() throws IOException { if (reader != null) { reader.close(); } if (writer != null) { writer.close(); } }
@Override public synchronized void close() throws IOException { super.close(); DataOutputStream out = fs.create(new Path(dir, BLOOM_FILE_NAME), true); try { bloomFilter.write(out); out.flush(); out.close(); out = null; } finally { IOUtils.closeStream(out); } }
public void close(TaskAttemptContext context) throws IOException { out.close(); } };
@Override public synchronized void close() throws IOException { super.close(); DataOutputStream out = fs.create(new Path(dir, BLOOM_FILE_NAME), true); try { bloomFilter.write(out); out.flush(); out.close(); out = null; } finally { IOUtils.closeStream(out); } }
private void close() throws IOException { for (int i = 0; i < inReaders.length; i++) { IOUtils.closeStream(inReaders[i]); inReaders[i] = null; } if (outWriter != null) { outWriter.close(); outWriter = null; } } }
private void close() throws IOException { for (int i = 0; i < inReaders.length; i++) { IOUtils.closeStream(inReaders[i]); inReaders[i] = null; } if (outWriter != null) { outWriter.close(); outWriter = null; } } }
private void prepareReader() throws IOException { if (writer != null) { writer.close(); writer = null; } if (reader == null) { reader = new MapFile.Reader(fs, qualifiedDirName.toString(), conf); } }
private void close() throws IOException { for (int i = 0; i < inReaders.length; i++) { IOUtils.closeStream(inReaders[i]); inReaders[i] = null; } if (outWriter != null) { outWriter.close(); outWriter = null; } } }
private void close() throws IOException { for (int i = 0; i < inReaders.length; i++) { IOUtils.closeStream(inReaders[i]); inReaders[i] = null; } if (outWriter != null) { outWriter.close(); outWriter = null; } } }