class documentation
class MiddlewareSafeOperationHandler(OperationHandler[
Known subclasses: nexusrpc.handler._core._EnsuredAwaitableOperationHandler
An OperationHandler where start and cancel
can be awaited by an async runtime. It can produce a result synchronously by returning
StartOperationResultSync or asynchronously by returning StartOperationResultAsync
in the same fashion that OperationHandler does.
Warning
This API is experimental and may change in the future.
overrides
nexusrpc.handler.OperationHandler.canceloverridden in
nexusrpc.handler._core._EnsuredAwaitableOperationHandlerCancel an in progress operation identified by the given token.
@abstractmethod
async def start(self, ctx: StartOperationContext, input: Any) -> StartOperationResultSync[ Any] | StartOperationResultAsync:
¶
overrides
nexusrpc.handler.OperationHandler.startoverridden in
nexusrpc.handler._core._EnsuredAwaitableOperationHandlerStart the operation and return it's result or an async token.
