We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0236741 + 89c8ff7 commit ea5c0c7Copy full SHA for ea5c0c7
src/utils/kafka.js
@@ -24,7 +24,21 @@ class Kafka {
24
}
25
26
send(message) {
27
- return this.producer.send({ topic: config.TOPIC, message: { value: message } });
+ const data = JSON.stringify({
28
+ topic: config.TOPIC,
29
+ originator: 'topcoder-x-ui',
30
+ timestamp: (new Date()).toISOString(),
31
+ 'mime-type': 'application/json',
32
+ payload: {
33
+ value: message,
34
+ },
35
+ });
36
+ return this.producer.send({
37
38
+ message: {
39
+ value: data,
40
41
42
43
44
0 commit comments