nexusLIMS.exporters.strategies#
Export strategies for multi-destination export.
This module implements different strategies for exporting to multiple destinations with different success criteria:
all: All destinations must succeed
first_success: Stop after first success
best_effort: Try all, succeed if any succeed
Module Contents#
Functions#
Execute export strategy. |
API#
- nexusLIMS.exporters.strategies.execute_strategy(strategy: ExportStrategy, destinations: list[ExportDestination], context: ExportContext) list[ExportResult][source]#
Execute export strategy.
Exports to multiple destinations according to the specified strategy, accumulating results in context.previous_results to enable inter-destination dependencies.
- Parameters:
strategy – Export strategy to use
destinations – List of destinations (should be sorted by priority)
context – Export context (will be mutated to add previous_results)
- Returns:
Results from each destination that was attempted
- Return type: