What are te pro's and con's when putting data first in Kafka and then in a database, or the other way?
An example: A user does a REST (POST) call to store let's say products. Normally i would pick up this call in the backend and save the body to a database (after validation and all..). Is it a best practice to pick up this call and store de data in Kafka fist and then save it to the database (in this case, the database is a kafka consumer).
Or is it better to save it in the database first, then send it to kafka?
Thanks