@Override public FixedLengthSliceInput get() { Slice buffer = lazyBufferLoader.loadNestedDiskRangeBuffer(diskRange); return new BasicSliceInput(buffer); } }
private static OrcInputStream orcInputStreamFor(String source, byte[] bytes) { return new OrcInputStream(new OrcDataSourceId(source), new BasicSliceInput(Slices.wrappedBuffer(bytes)), Optional.empty(), newSimpleAggregatedMemoryContext(), bytes.length); }
PutObjectRequest putObjectRequest = new PutObjectRequest(config.getEventStoreBulkS3Bucket(), key, new SafeSliceInputStream(new BasicSliceInput(buffer.slice())), objectMetadata); putObjectRequest.getRequestClientOptions().setReadLimit(bulkSize);
/** * Creates a slice input backed by this slice. Any changes to this slice * will be immediately visible to the slice input. */ public BasicSliceInput getInput() { return new BasicSliceInput(this); }
/** * Creates a slice input backed by this slice. Any changes to this slice * will be immediately visible to the slice input. */ public BasicSliceInput getInput() { return new BasicSliceInput(this); }
@Override protected SliceInput createSliceInput(Slice slice) { return new BasicSliceInput(slice); }
@Override public FixedLengthSliceInput get() { Slice buffer = lazyBufferLoader.loadNestedDiskRangeBuffer(diskRange); return new BasicSliceInput(buffer); } }
@Override public FixedLengthSliceInput get() { Slice buffer = lazyBufferLoader.loadNestedDiskRangeBuffer(diskRange); return new BasicSliceInput(buffer); } }
@Override public FixedLengthSliceInput get() { Slice buffer = lazyBufferLoader.loadNestedDiskRangeBuffer(diskRange); return new BasicSliceInput(buffer); } }
@Override protected SliceInput createSliceInput(Slice slice) { return new BasicSliceInput(slice); }
private static OrcInputStream orcInputStreamFor(String source, byte[] bytes) { return new OrcInputStream(new OrcDataSourceId(source), new BasicSliceInput(Slices.wrappedBuffer(bytes)), Optional.empty(), newSimpleAggregatedMemoryContext(), bytes.length); }
private static OrcInputStream orcInputStreamFor(String source, byte[] bytes) { return new OrcInputStream(new OrcDataSourceId(source), new BasicSliceInput(Slices.wrappedBuffer(bytes)), Optional.empty(), newSimpleAggregatedMemoryContext(), bytes.length); }
private static OrcInputStream orcInputStreamFor(String source, byte[] bytes) { return new OrcInputStream(new OrcDataSourceId(source), new BasicSliceInput(Slices.wrappedBuffer(bytes)), Optional.empty(), newSimpleAggregatedMemoryContext(), bytes.length); }
@Test public void testRetainedSize() { Slice slice = Slices.allocate(1024); SliceInput input = new BasicSliceInput(slice); assertEquals(input.getRetainedSize(), ClassLayout.parseClass(BasicSliceInput.class).instanceSize() + slice.getRetainedSize()); } }
@Test public void testRetainedSize() { Slice slice = Slices.allocate(1024); SliceInput input = new BasicSliceInput(slice); assertEquals(input.getRetainedSize(), ClassLayout.parseClass(BasicSliceInput.class).instanceSize() + slice.getRetainedSize()); } }