You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
📝 Todo : ** use a Document-Oriented db like MongoDb to store the command **
Description:
We shouldn't wait for the result necessarily, as we can just fire and forget.
Code Snippet:
// ---------------------------------------------------------------------------------------------------------------------// Imports// ---------------------------------------------------------------------------------------------------------------------usingInfiniLore.Server.Contracts.Services.CQRS;usingMediatR;namespaceInfiniLore.Server.Services.CQRS.PipelineBehaviours.Behaviours;// ---------------------------------------------------------------------------------------------------------------------// Code// ---------------------------------------------------------------------------------------------------------------------publicclassStoreCommandsBehaviour<TRequest,TResponse>:IPipelineBehavior<TRequest,TResponse>whereTRequest:IRequest<TResponse>,ICqrsCommandwhereTResponse:notnull{publicasyncTask<TResponse>Handle(TRequestrequest,RequestHandlerDelegate<TResponse>next,CancellationTokencancellationToken){// TODO use a Document-Oriented db like MongoDb to store the command// We shouldn't wait for the result necessarily, as we can just fire and forget.// Continue as normalTResponseresponse=awaitnext();returnresponse;}}
📝 Todo : ** use a Document-Oriented db like MongoDb to store the command **
Description:
We shouldn't wait for the result necessarily, as we can just fire and forget.
Code Snippet:
File:
infinilore.cs/src/server/InfiniLore.Server.Services.CQRS.PipelineBehaviours/Behaviours/StoreCommandsBehaviour.cs
Lines 17 to 18 in b3d4afb
The text was updated successfully, but these errors were encountered: