| 308 | }; |
| 309 | |
| 310 | ThreadResult<RangeResult> DLTransaction::readBlobGranulesFinish( |
| 311 | ThreadFuture<Standalone<VectorRef<BlobGranuleChunkRef>>> startFuture, |
| 312 | const KeyRangeRef& keyRange, |
| 313 | Version beginVersion, |
| 314 | Version readVersion, |
| 315 | ReadBlobGranuleContext granuleContext) { |
| 316 | if (!api->transactionReadBlobGranulesFinish) { |
| 317 | return unsupported_operation(); |
| 318 | } |
| 319 | |
| 320 | // convert back to fdb future for API |
| 321 | FdbCApi::FDBFuture* f = (FdbCApi::FDBFuture*)(startFuture.extractPtr()); |
| 322 | |
| 323 | // FIXME: better way to convert here? |
| 324 | FdbCApi::FDBReadBlobGranuleContext context; |
| 325 | context.userContext = granuleContext.userContext; |
| 326 | context.start_load_f = granuleContext.start_load_f; |
| 327 | context.get_load_f = granuleContext.get_load_f; |
| 328 | context.free_load_f = granuleContext.free_load_f; |
| 329 | context.debugNoMaterialize = granuleContext.debugNoMaterialize; |
| 330 | context.granuleParallelism = granuleContext.granuleParallelism; |
| 331 | |
| 332 | FdbCApi::FDBResult* r = api->transactionReadBlobGranulesFinish(tr, |
| 333 | f, |
| 334 | keyRange.begin.begin(), |
| 335 | keyRange.begin.size(), |
| 336 | keyRange.end.begin(), |
| 337 | keyRange.end.size(), |
| 338 | beginVersion, |
| 339 | readVersion, |
| 340 | &context); |
| 341 | |
| 342 | return ThreadResult<RangeResult>((ThreadSingleAssignmentVar<RangeResult>*)(r)); |
| 343 | }; |
| 344 | |
| 345 | ThreadFuture<Standalone<VectorRef<BlobGranuleSummaryRef>>> |
| 346 | DLTransaction::summarizeBlobGranules(const KeyRangeRef& keyRange, Optional<Version> summaryVersion, int rangeLimit) { |
no test coverage detected