File tree 2 files changed +10
-9
lines changed
2 files changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,8 @@ build = "build.rs"
9
9
10
10
[dependencies ]
11
11
# Arrow and DataFusion ecosystem
12
- arrow-array = { version = " 53.0.0" }
12
+ arrow = " 53.0.0"
13
+ arrow-array = " 53.0.0"
13
14
arrow-flight = { version = " 53.0.0" , features = [" tls" ] }
14
15
arrow-ipc = { version = " 53.0.0" , features = [" zstd" ] }
15
16
arrow-json = " 53.0.0"
Original file line number Diff line number Diff line change 20
20
#![ allow( deprecated) ]
21
21
22
22
use anyhow:: anyhow;
23
+ use arrow:: compute:: concat_batches;
23
24
use arrow_array:: RecordBatch ;
24
25
use arrow_json:: reader:: { infer_json_schema_from_iterator, ReaderBuilder } ;
25
26
use arrow_schema:: { DataType , Field , Fields , Schema } ;
@@ -282,14 +283,13 @@ impl EventFormat for Event {
282
283
key. push_str ( & format ! ( "&{k}={v}" ) ) ;
283
284
}
284
285
285
- partitions. insert (
286
- key,
287
- PartitionEvent {
288
- rb,
289
- parsed_timestamp,
290
- custom_partition_values,
291
- } ,
292
- ) ;
286
+ let entry = partitions. entry ( key) . or_insert ( PartitionEvent {
287
+ rb : RecordBatch :: new_empty ( schema. clone ( ) ) ,
288
+ parsed_timestamp,
289
+ custom_partition_values,
290
+ } ) ;
291
+
292
+ entry. rb = concat_batches ( & schema, [ & entry. rb , & rb] ) ?;
293
293
}
294
294
295
295
Ok ( super :: Event {
You can’t perform that action at this time.
0 commit comments