macro_rules! run_async {
($logic_fn:expr, $hub:expr) => { ... };
}
Expand description
Executes asynchronously a given logic function without transaction control.
This macro sets up local data sources, runs the provided closure,
and then cleans up the DataHub
’s session resources. It does not
perform commit or rollback operations.
§Parameters
logic_fn
: A closure that encapsulates the business logic to be executed. It takes a mutable reference toDataHub
as an argument.hub
: A hub struct instance for data input/output operations.
§Returns
Result<(), Err>
: The result of the logic function’s execution, or an error if executinglogic_fn
fails.