Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e361191
commit 9366a04
Showing
3 changed files
with
83 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
// Licensed to the Apache Software Foundation (ASF) under one | ||
// or more contributor license agreements. See the NOTICE file | ||
// distributed with this work for additional information | ||
// regarding copyright ownership. The ASF licenses this file | ||
// to you under the Apache License, Version 2.0 (the | ||
// "License"); you may not use this file except in compliance | ||
// with the License. You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, | ||
// software distributed under the License is distributed on an | ||
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
// KIND, either express or implied. See the License for the | ||
// specific language governing permissions and limitations | ||
// under the License. | ||
|
||
/// EXPERIMENTAL: A less restrictive version of RecordBatch that can | ||
/// reduce wire overhead for small messages | ||
|
||
include "Schema.fbs"; | ||
|
||
namespace org.apache.arrow.flatbuf; | ||
|
||
/// ---------------------------------------------------------------------- | ||
/// Data structures to represent a bag of columns (a collection of | ||
/// possibly differing length Arrow arrays) | ||
|
||
/// A range of top level field nodes, identified by their ordering in the | ||
/// schema. The offsets are zero-indexed, but only top level field nodes are | ||
/// counted; it is impossible to refer to a child node anywhere in the schema. | ||
struct FieldNodeRange { | ||
/// The starting offset (inclusive) | ||
start: long; | ||
|
||
/// The ending offset (exclusive) | ||
end: long; | ||
} | ||
|
||
/// A data header describing the shared memory layout of a "bag" of "columns". | ||
/// It is similar to a RecordBatch but not every top level node is required | ||
/// to be included in the wire payload. | ||
table ColumnBag { | ||
/// If not provided, all nodes are included and this payload is identical | ||
/// to a RecordBatch. Otherwise the reader needs to skip top level FieldNodes | ||
/// (and the parallel Buffers) that were not included. Note that ranges must | ||
/// be listed in strictly increasing order and be non-overlapping. | ||
includedNodes: [FieldNodeRange]; | ||
|
||
/// Nodes correspond to the pre-ordered flattened logical schema | ||
nodes: [FieldNode]; | ||
|
||
/// Buffers correspond to the pre-ordered flattened buffer tree | ||
/// | ||
/// The number of buffers appended to this list depends on the schema. For | ||
/// example, most primitive arrays will have 2 buffers, 1 for the validity | ||
/// bitmap and 1 for the values. For struct arrays, there will only be a | ||
/// single buffer for the validity (nulls) bitmap | ||
buffers: [Buffer]; | ||
|
||
/// Optional compression of the message body | ||
compression: BodyCompression; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters