NestJS · Senior · Question 17 of 75

How do you get reliable event publishing from a Nest service that also writes to the database?

Explanation

Emitting outside the transaction can lose or duplicate events if either step fails.

Further reading

Problem with a question

NestJS · Senior · question 17

Test yourself

Take the NestJS · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz