update kafka messaging

This commit is contained in:
Brian Cao 2022-08-25 11:07:47 -07:00
parent 9fea2fc77c
commit 46b4b98d40
6 changed files with 31 additions and 15 deletions

View file

@ -6,7 +6,7 @@ import {
runAnalyticsQuery,
runQuery,
} from 'lib/db';
import { kafkaProducer, getDateFormatKafka } from 'lib/kafka';
import { sendKafkaMessage, getDateFormatKafka } from 'lib/db/kafka';
import { getSessionByUuid } from 'queries';
export async function createSession(...args) {
@ -73,7 +73,7 @@ async function kafkaQuery(
country: country ? country : null,
};
await kafkaProducer(params, 'session');
await sendKafkaMessage(params, 'session');
return getSessionByUuid(session_uuid);
}