|
|
Go to the documentation of this file. 1 #ifndef FWCore_Framework_ProductResolvers_h
2 #define FWCore_Framework_ProductResolvers_h
27 class MergeableRunProductMetadata;
28 class ProductProvenanceRetriever;
30 class ModuleCallingContext;
63 void setProduct(std::unique_ptr<WrapperBase> edp)
const;
68 template <
bool callResolver,
typename FUNC>
115 bool skipCurrentProcess,
117 ModuleCallingContext
const* mcc)
const override;
119 Principal
const& principal,
120 bool skipCurrentProcess,
123 ModuleCallingContext
const* mcc)
const override;
127 MergeableRunProductMetadata
const* mergeableRunProductMetadata)
const override;
148 void putProduct_(std::unique_ptr<WrapperBase> edp)
const override;
163 bool skipCurrentProcess,
168 bool skipCurrentProcess,
174 void putProduct_(std::unique_ptr<WrapperBase> edp)
const override;
191 bool skipCurrentProcess,
196 bool skipCurrentProcess,
218 realProduct_.connectTo(iOther, iParentPrincipal);
223 bool skipCurrentProcess,
226 return realProduct_.resolveProduct(principal, skipCurrentProcess, sra, mcc);
230 bool skipCurrentProcess,
234 realProduct_.prefetchAsync(waitTask, principal, skipCurrentProcess,
token, sra, mcc);
241 return realProduct_.productWasFetchedAndIsValid(iSkipCurrentProcess);
244 void putProduct_(std::unique_ptr<WrapperBase> edp)
const override;
260 std::shared_ptr<BranchDescription const>
bd_;
279 void unsafe_setWrapperAndProvenance()
const;
286 return realProduct_.productWasFetchedAndIsValid(iSkipCurrentProcess);
324 bool skipCurrentProcess,
329 bool skipCurrentProcess,
333 void putProduct_(std::unique_ptr<WrapperBase> edp)
const final;
355 bool skipCurrentProcess,
360 bool skipCurrentProcess,
364 void putProduct_(std::unique_ptr<WrapperBase> edp)
const final;
373 :
ProductResolverBase(), realProduct_(nullptr), bd_(
bd), provRetriever_(nullptr), parentPrincipal_(nullptr) {}
376 realProduct_ = &iOther;
377 parentPrincipal_ = iParentPrincipal;
382 bool skipCurrentProcess,
385 skipCurrentProcess =
false;
386 return realProduct_->resolveProduct(*parentPrincipal_, skipCurrentProcess, sra, mcc);
390 bool skipCurrentProcess,
394 skipCurrentProcess =
false;
395 realProduct_->prefetchAsync(waitTask, *parentPrincipal_, skipCurrentProcess,
token, sra, mcc);
399 return realProduct_->unscheduledWasNotRun();
400 throwNullRealProduct();
407 iSkipCurrentProcess =
false;
408 return realProduct_->productWasFetchedAndIsValid(iSkipCurrentProcess);
411 void putProduct_(std::unique_ptr<WrapperBase> edp)
const override;
423 void throwNullRealProduct()
const;
426 std::shared_ptr<BranchDescription const>
bd_;
435 std::vector<bool>
const& ambiguous,
440 void tryPrefetchResolverAsync(
unsigned int iProcessingIndex,
442 bool skipCurrentProcess,
447 bool dataValidFromResolver(
unsigned int iProcessingIndex,
449 bool iSkipCurrentProcess)
const;
451 void prefetchFailed(
unsigned int iProcessingIndex,
453 bool iSkipCurrentProcess,
454 std::exception_ptr iExceptPtr)
const;
457 unsigned int unsetIndexValue()
const;
459 bool skipCurrentProcess,
464 bool skipCurrentProcess,
490 bool skipCurrentProcess,
517 bool skipCurrentProcess,
522 bool skipCurrentProcess,
SwitchAliasProductResolver(std::shared_ptr< BranchDescription const > bd, DataManagingOrAliasProductResolver &realProduct)
Provenance const * provenance() const
DataManagingOrAliasProductResolver()
std::string const & resolvedModuleLabel_() const final
bool productWasFetchedAndIsValid_(bool iSkipCurrentProcess) const final
ParentProcessProductResolver(std::shared_ptr< BranchDescription const > bd)
ProducedProductResolver(std::shared_ptr< BranchDescription const > bd, ProductStatus iDefaultStatus)
void resetBranchDescription_(std::shared_ptr< BranchDescription const > bd) override
unsigned int ProductResolverIndex
DataManagingProductResolver(std::shared_ptr< BranchDescription const > bd, ProductStatus iDefaultStatus)
void connectTo(ProductResolverBase const &iOther, Principal const *iParentPrincipal) final
std::vector< ProductResolverIndex > matchingHolders_
std::shared_ptr< BranchDescription const > bd_
bool singleProduct_() const final
deep_tau::DeepTauBase::BasicDiscriminator bd
bool productResolved_() const final
std::vector< bool > ambiguous_
ProducedProductResolver::ProductStatus ProductStatus
ProductProvenance const * productProvenance() const
std::atomic< unsigned int > lastSkipCurrentCheckIndex_
WaitingTaskList waitingTasks_
PuttableProductResolver(std::shared_ptr< BranchDescription const > bd)
std::atomic< ProductStatus > theStatus_
virtual void putProduct_(std::unique_ptr< WrapperBase > edp) const =0
void prefetchAsync_(WaitingTask *waitTask, Principal const &principal, bool skipCurrentProcess, ServiceToken const &token, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const override
bool unscheduledWasNotRun_() const final
void setMergeableRunProductMetadataInProductData(MergeableRunProductMetadata const *)
ProductProvenanceRetriever const * provRetriever_
void prefetchAsync_(WaitingTask *waitTask, Principal const &principal, bool skipCurrentProcess, ServiceToken const &token, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const override
ProductResolverBase const * realProduct_
std::atomic< unsigned int > lastCheckIndex_
const ProductStatus defaultStatus_
ProductStatus defaultStatus() const
bool productWasFetchedAndIsValid_(bool iSkipCurrentProcess) const final
WaitingTaskList & waitingTasks() const
Provenance const & provenance() const
bool productWasFetchedAndIsValid_(bool iSkipCurrentProcess) const final
bool productUnavailable() const
std::shared_ptr< BranchDescription const > bd_
std::atomic< bool > skippingPrefetchRequested_
bool productWasFetchedAndIsValid_(bool iSkipCurrentProcess) const override
bool productResolved_() const final
Provenance const * provenance_() const final
void resetBranchDescription(std::shared_ptr< BranchDescription const > bd)
void setProduct(std::unique_ptr< WrapperBase > edp) const
Principal const * parentPrincipal_
bool productUnavailable_() const final
ProducedProductResolver::ProductStatus ProductStatus
bool unscheduledWasNotRun() const
void mergeProduct(std::unique_ptr< WrapperBase > edp, MergeableRunProductMetadata const *) const
virtual bool unscheduledWasNotRun_() const =0
Resolution resolveProductImpl(FUNC resolver) const
bool productUnavailable_() const final
DataManagingOrAliasProductResolver const & realProduct() const
WaitingTaskList waitingTasks_
ProducedProductResolver::ProductStatus ProductStatus
UnscheduledAuxiliary const * aux_
void throwProductDeletedException() const
ProductResolverIndex realResolverIndex_
virtual ProductData const & getProductData() const =0
Resolution resolveProduct_(Principal const &principal, bool skipCurrentProcess, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const override
void setProductProvenanceRetriever_(ProductProvenanceRetriever const *provRetriever) final
bool unscheduledWasNotRun_() const override
DataManagingOrAliasProductResolver & realProduct_
bool unscheduledWasNotRun_() const override
BranchDescription const & branchDescription_() const override
virtual void setMergeableRunProductMetadata_(MergeableRunProductMetadata const *)
Provenance const * provenance_() const final
std::atomic< bool > prefetchRequested_
bool unscheduledWasNotRun_() const override
void connectTo(ProductResolverBase const &iOther, Principal const *iParentPrincipal) final
std::atomic< bool > prefetchRequested_
bool unscheduledWasNotRun_() const final
SingleChoiceNoProcessProductResolver(ProductResolverIndex iChoice)
void setProductID_(ProductID const &pid) final
void resetProductData_(bool deleteEarly) override=0
ProducedProductResolver::ProductStatus ProductStatus
void resetBranchDescription_(std::shared_ptr< BranchDescription const > bd) override
Resolution resolveProduct_(Principal const &principal, bool skipCurrentProcess, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const override
bool productWasDeleted_() const override
WaitingTaskList m_waitingTasks
void putOrMergeProduct_(std::unique_ptr< WrapperBase > prod, MergeableRunProductMetadata const *mergeableRunProductMetadata) const final
bool productUnavailable_() const override
WaitingTaskList waitingTasks_
std::string const & resolvedModuleLabel_() const final
std::string const & moduleLabel() const
void resetProductData_(bool deleteEarly) override
virtual void retrieveAndMerge_(Principal const &principal, MergeableRunProductMetadata const *mergeableRunProductMetadata) const
bool singleProduct_() const final
virtual void prefetchAsync_(WaitingTask *waitTask, Principal const &principal, bool skipCurrentProcess, ServiceToken const &token, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const =0
std::unique_ptr< T, impl::DeviceDeleter > unique_ptr
bool productUnavailable_() const override
BranchDescription const & branchDescription_() const final
void checkType(WrapperBase const &prod) const
ProductStatus status() const
std::string const & resolvedModuleLabel_() const override
virtual Resolution resolveProduct_(Principal const &principal, bool skipCurrentProcess, SharedResourcesAcquirer *sra, ModuleCallingContext const *mcc) const =0
ProductData const & getProductData() const final
AliasProductResolver(std::shared_ptr< BranchDescription const > bd, DataManagingOrAliasProductResolver &realProduct)
WaitingTaskList skippingWaitingTasks_
void resetBranchDescription_(std::shared_ptr< BranchDescription const > bd) final
std::string const & resolvedModuleLabel_() const override
ProductData const & getProductData() const final
Provenance const * provenance_() const final
BranchDescription const & branchDescription_() const override
std::shared_ptr< BranchDescription const > const & branchDescription() const
BranchDescription const & branchDescription_() const final
void setFailedStatus() const
ProductData const & getProductData() const final
virtual void setupUnscheduled(UnscheduledConfigurator const &)
bool productWasDeleted_() const override
std::atomic< bool > prefetchRequested_
void resetBranchDescription_(std::shared_ptr< BranchDescription const > bd) final
std::atomic< bool > & prefetchRequested() const
DataManagingOrAliasProductResolver & realProduct_
void connectTo(ProductResolverBase const &, Principal const *) final
UnscheduledProductResolver(std::shared_ptr< BranchDescription const > bd)
bool productResolved_() const final
ProductProvenance const * productProvenancePtr_() const final
Provenance const * provenance_() const final
bool unscheduledWasNotRun_() const override
ProductProvenance const * productProvenancePtr_() const final
bool productWasDeleted_() const final
virtual bool isFromCurrentProcess() const =0
std::atomic< bool > prefetchRequested_