fix path params

This commit is contained in:
CHIEFSOFT\ameye
2024-07-06 15:57:17 -04:00
parent 91ffd9c499
commit 4a6112c585
2 changed files with 10 additions and 3 deletions
+9 -3
View File
@@ -1,14 +1,20 @@
// import { Kafka } from "kafkajs";
const dotenv = require('dotenv');
const env = dotenv.config();
//console.log("ENVVVVV ", env);
const {Kafka} = require('kafkajs');
const kafkaServer = process.env.KAFKA_SERVER;
const kafkaBroker1 = process.env.WRENCHJOB_KAFKA_BROKER01;
console.log("kafkaBroker1", kafkaBroker1);
const kafka = new Kafka({
clientId: "wallet-kafka",
brokers: ['10.10.10.120:9092'],
brokers: [kafkaBroker1],
});
class KafkaConfig {
constructor() {
constructor() {
this.producer = kafka.producer();
this.consumer = kafka.consumer({ groupId: "test-group" });
}
+1
View File
@@ -15,6 +15,7 @@
"axios": "^0.24.0",
"body-parser": "^1.19.0",
"cors": "^2.8.5",
"dotenv": "^16.4.5",
"cookie-parser": "^1.4.6",
"express": "^4.17.1",
"kafkajs": "^2.2.4",