CreateNewMerchant
v0.0.2

Holds information about the merchant.
When firing this event make sure you set the `correlation-id` in the headers. Our schemas have standard metadata make sure you read and follow it.

Details

This event can be triggered multiple times per customer. Everytime the customer adds an item to their shopping cart this event will be triggered.

We have a frontend application that allows users to buy things from our store. This front end interacts directly with the Basket Service to add items to the cart. The Basket Service will raise the events.

Consumer / Producer Diagram

How to trigger event

1var kafka = require('kafka-node'),
2  Consumer = kafka.Consumer,
3  client = new kafka.KafkaClient(),
4  consumer = new Consumer(
5    client,
6    [
7      { topic: 't', partition: 0 },
8      { topic: 'CreateNewMerchant', partition: 1 },
9    ],
10    {
11      autoCommit: false,
12    }
13  );
14
15consumer.on('message', function (message) {
16  console.log(message);
17});
18
Last updated on 2023/10/23