DEV Community

Discussion on: Your thoughts on Creating a New User

Collapse
 
_bigblind profile image
Frederik 👨‍💻➡️🌐 Creemers • Edited

One thing you see more and more in cases like this is a publish/subscribe system of events, so different parts of your site can react to things that happen. For example, your main route handler might take care of storing the user's data and then emit a signup event that other parts of the system can then take action on.

You might have a billing subsystem that creates the user's subscription and charges them for the first time, and an emails subsystem that takes care of sending the welcome email.

This might be implemented within your codebase using a signals module built into the web framework you use, or you can use an external application like Redis pubsub or Apache Kafka

Collapse
 
jpwilliams profile image
Jack Williams

We wrote remit as a nice wrapper around RabbitMQ for exactly this purpose.

Collapse
 
jessachandler profile image
Jess Chandler

I'll check it out. Thanks!

Collapse
 
jessachandler profile image
Jess Chandler

Interesting. Thanks for sharing your thoughts!