Commit b227def 1 parent 53f5c78 commit b227def Copy full SHA for b227def
File tree 2 files changed +12
-2
lines changed
2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -512,8 +512,17 @@ void TileDBVCFDataset::open(
512
512
if (prefetch_data_array_fragment_info)
513
513
preload_data_array_fragment_info ();
514
514
515
- data_array_ = open_data_array (TILEDB_READ);
516
- vcf_header_array_ = open_vcf_array (TILEDB_READ);
515
+ // Open the data and vcf_header arrays in parallel
516
+ auto data_array_async = std::async (std::launch::async, [this ]() {
517
+ data_array_ = open_data_array (TILEDB_READ);
518
+ });
519
+ auto vcf_header_array_async = std::async (std::launch::async, [this ]() {
520
+ vcf_header_array_ = open_vcf_array (TILEDB_READ);
521
+ });
522
+
523
+ // Block until the arrays are open, log and rethrow any exceptions
524
+ TRY_CATCH_THROW (vcf_header_array_async.get ());
525
+ TRY_CATCH_THROW (data_array_async.get ());
517
526
read_metadata ();
518
527
519
528
// We support V2, V3 and V4 (current) formats.
Original file line number Diff line number Diff line change 30
30
#ifndef TILEDB_VCF_ATTR_DATATYPE_H
31
31
#define TILEDB_VCF_ATTR_DATATYPE_H
32
32
33
+ #include < cstdint>
33
34
#include < stdexcept>
34
35
#include < string>
35
36
You can’t perform that action at this time.
0 commit comments