request-response

NServiceBus 6 callback client never gets a callback when the request handler fails

|▌冷眼眸甩不掉的悲伤 提交于 2021-02-10 20:14:02
问题 Using NServiceBus 6's Callback feature I have found no way to alert the client that the request handler failed. The request handler will go through all the recoverability steps, and eventually put the message into the error queue. Meanwhile, the client just sits there waiting for its reply. // Client code (e.g. in an MVC Controller) var message = new FooRequest(); var response = await endpoint.Request<FooReponse>(message); // Handler code public class FooRequestHandler : IHandleMessages

Net Core: Wrap DTO in Response Pattern in Dynamic Variable Way

感情迁移 提交于 2019-12-13 07:46:53
问题 Software requirements is asking all DTOs contain their own Response Class. So developers basically wrap Product DTO in Base Response class. We have whole list of class areas, requiring hundreds of classes for Product, Sales, Customer, etc all doing same thing, per below. Client does not want to wrap as BaseResponse<Product> or BaseResponse<IEnumerable<ProductDto> since it is nested/unreadable. Is there method to wrap/create variable classes and readable, without manually writing 100s of class