--
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi ManuelYou are right. In a single endpoint, all handlers for a given message type are executed in a single transaction context. But with NServiceBus nothing prevents you from using more than one endpoint. In fact, if you were to use a single endpoint/queue for all the denormalizers, you would not need NSB in the first place.In your case you should probably Publish the domain event via NServiceBus. On the other side you would have a number of endpoints, each subscribed for these domain events. Each endpoint can host a number of handlers, based on their requirements e.g. if on the read side you have a document DB, a SQL DB and a SMTP server, even though you might have 10s of handlers, you might need only three endpoints. This way if SQL is down, handlers that don't use it can continue to work and you don't pay the cost of physically separate deployment for each and every handler.Szymon
śr., 17.08.2016 o 21:05 użytkownik Manuel Pallier <manuel....@beko.at> napisał:
Helpful information to include--Product name: NServiceBusVersion: 5.2.14Stacktrace: -Description:
Hi,
I'm currently modifying an in-development application based on the CQRS and ES patterns to use NServiceBus (based on MSMQ). Right now NServiceBus is used for the communication between clients and the server, to send commands and publish events (e.g. for change notification). Next I'd like to replace the in-memory message bus on the server. This bus is used to publish the domain events (that have been saved in the event store) to the event handlers (e.g. de-normalizers).
Just replacing my in-memory bus with NServiceBus publish/subscribe is easy. But I'd also like to make all event handlers independent so that one can fail and all others still commit their changes. Example: The event 'CustomerCreatedEvent' is saved in the event store. Multiple classes handle the event. If 'CustomerEmailNotifier' throws an exception, 'CustomerReadModelGenerator' should still be executed (and commited). Later, 'CustomerEmailNotifier' should be retried, just like it would happen if it was the only handler of the event.
As far as I understand the documentation, this use case is not how NServiceBus works by default. Instead, all handlers are processed in a single transaction scope. But unless I misunderstand CQRS, domain event handlers should be independent of each other, right? So how do I implement this CQRS domain event publishing with NServiceBus?
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
Hi,
Thanks for your help. This sounds like a good solution. But how do I then manage my event subscriptions? For one endpoint I'd just subscribe to all implementations of my 'IEvent' interface. But when I then have multiple endpoints, I need to subscribe the correct events to the correct endpoints. Do I need to create different marker interfaces or are there better ways?
Am Donnerstag, 18. August 2016 05:45:55 UTC+2 schrieb Szymon Pobiega:Hi ManuelYou are right. In a single endpoint, all handlers for a given message type are executed in a single transaction context. But with NServiceBus nothing prevents you from using more than one endpoint. In fact, if you were to use a single endpoint/queue for all the denormalizers, you would not need NSB in the first place.In your case you should probably Publish the domain event via NServiceBus. On the other side you would have a number of endpoints, each subscribed for these domain events. Each endpoint can host a number of handlers, based on their requirements e.g. if on the read side you have a document DB, a SQL DB and a SMTP server, even though you might have 10s of handlers, you might need only three endpoints. This way if SQL is down, handlers that don't use it can continue to work and you don't pay the cost of physically separate deployment for each and every handler.Szymonśr., 17.08.2016 o 21:05 użytkownik Manuel Pallier <manuel....@beko.at> napisał:
Helpful information to include--Product name: NServiceBusVersion: 5.2.14Stacktrace: -Description:
Hi,
I'm currently modifying an in-development application based on the CQRS and ES patterns to use NServiceBus (based on MSMQ). Right now NServiceBus is used for the communication between clients and the server, to send commands and publish events (e.g. for change notification). Next I'd like to replace the in-memory message bus on the server. This bus is used to publish the domain events (that have been saved in the event store) to the event handlers (e.g. de-normalizers).
Just replacing my in-memory bus with NServiceBus publish/subscribe is easy. But I'd also like to make all event handlers independent so that one can fail and all others still commit their changes. Example: The event 'CustomerCreatedEvent' is saved in the event store. Multiple classes handle the event. If 'CustomerEmailNotifier' throws an exception, 'CustomerReadModelGenerator' should still be executed (and commited). Later, 'CustomerEmailNotifier' should be retried, just like it would happen if it was the only handler of the event.
As far as I understand the documentation, this use case is not how NServiceBus works by default. Instead, all handlers are processed in a single transaction scope. But unless I misunderstand CQRS, domain event handlers should be independent of each other, right? So how do I implement this CQRS domain event publishing with NServiceBus?
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
HiIn most cases NServiceBus automatic subscriptions should handle everything. NSB automatically subscribes to event E when it finds a handler for it in the loaded assemblies and (in case of MSMQ) there is proper routing configuration in the MessageEndpointMappings section http://docs.particular.net/nservicebus/messaging/message-owner. So each of your subscriber endpoint should point to the publisher and the subscriptions will be automatically created on startup.
Szymon
czw., 18.08.2016 o 14:25 użytkownik Manuel Pallier <manuel....@beko.at> napisał:
Hi,
Thanks for your help. This sounds like a good solution. But how do I then manage my event subscriptions? For one endpoint I'd just subscribe to all implementations of my 'IEvent' interface. But when I then have multiple endpoints, I need to subscribe the correct events to the correct endpoints. Do I need to create different marker interfaces or are there better ways?
Am Donnerstag, 18. August 2016 05:45:55 UTC+2 schrieb Szymon Pobiega:Hi ManuelYou are right. In a single endpoint, all handlers for a given message type are executed in a single transaction context. But with NServiceBus nothing prevents you from using more than one endpoint. In fact, if you were to use a single endpoint/queue for all the denormalizers, you would not need NSB in the first place.In your case you should probably Publish the domain event via NServiceBus. On the other side you would have a number of endpoints, each subscribed for these domain events. Each endpoint can host a number of handlers, based on their requirements e.g. if on the read side you have a document DB, a SQL DB and a SMTP server, even though you might have 10s of handlers, you might need only three endpoints. This way if SQL is down, handlers that don't use it can continue to work and you don't pay the cost of physically separate deployment for each and every handler.Szymonśr., 17.08.2016 o 21:05 użytkownik Manuel Pallier <manuel....@beko.at> napisał:
Helpful information to include--Product name: NServiceBusVersion: 5.2.14Stacktrace: -Description:
Hi,
I'm currently modifying an in-development application based on the CQRS and ES patterns to use NServiceBus (based on MSMQ). Right now NServiceBus is used for the communication between clients and the server, to send commands and publish events (e.g. for change notification). Next I'd like to replace the in-memory message bus on the server. This bus is used to publish the domain events (that have been saved in the event store) to the event handlers (e.g. de-normalizers).
Just replacing my in-memory bus with NServiceBus publish/subscribe is easy. But I'd also like to make all event handlers independent so that one can fail and all others still commit their changes. Example: The event 'CustomerCreatedEvent' is saved in the event store. Multiple classes handle the event. If 'CustomerEmailNotifier' throws an exception, 'CustomerReadModelGenerator' should still be executed (and commited). Later, 'CustomerEmailNotifier' should be retried, just like it would happen if it was the only handler of the event.
As far as I understand the documentation, this use case is not how NServiceBus works by default. Instead, all handlers are processed in a single transaction scope. But unless I misunderstand CQRS, domain event handlers should be independent of each other, right? So how do I implement this CQRS domain event publishing with NServiceBus?
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/cf43a92d-d8e6-4e9d-a7ed-910007419c2c%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/cf43a92d-d8e6-4e9d-a7ed-910007419c2c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/1eacc850-bc57-4292-8314-98d00fdbb4f1%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/cf43a92d-d8e6-4e9d-a7ed-910007419c2c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/cf43a92d-d8e6-4e9d-a7ed-910007419c2c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/1eacc850-bc57-4292-8314-98d00fdbb4f1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftw...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/975f0871-a62f-4a4f-9104-0956cebdbcca%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.--
Visit this group at https://groups.google.com/group/particularsoftware.
To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/056cf5aa-bfa0-4532-a885-5f7bb4d6b856%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/0a467301-f08c-4cfd-8113-d71d190a34f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/cf43a92d-d8e6-4e9d-a7ed-910007419c2c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.
To post to this group, send email to particula...@googlegroups.com.
Visit this group at https://groups.google.com/group/particularsoftware.
--To view this discussion on the web visit https://groups.google.com/d/msgid/particularsoftware/1eacc850-bc57-4292-8314-98d00fdbb4f1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Particular Software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to particularsoftware+unsub...@googlegroups.com.