From 25e619a4f6a2e709b3e29bd38926979ab21454d1 Mon Sep 17 00:00:00 2001 From: Benjamin Brauner <11899021@auf.bundeswehr.de> Date: Thu, 29 Feb 2024 10:36:16 +0100 Subject: [PATCH] update function redis.createClient to use redis host+port from config/settings.json otherwise redis use default host (localhost) and default port (6379) ) --- bbb-export-annotations/master.js | 6 ++++-- bbb-export-annotations/workers/collector.js | 6 ++++-- bbb-export-annotations/workers/notifier.js | 6 ++++-- bbb-export-annotations/workers/process.js | 7 +++++-- 4 files changed, 17 insertions(+), 8 deletions(-) diff --git a/bbb-export-annotations/master.js b/bbb-export-annotations/master.js index b412a7180a..4c9f892ad8 100644 --- a/bbb-export-annotations/master.js +++ b/bbb-export-annotations/master.js @@ -11,9 +11,11 @@ logger.info('Running bbb-export-annotations'); (async () => { const client = redis.createClient({ - host: config.redis.host, - port: config.redis.port, password: config.redis.password, + socket: { + host: config.redis.host, + port: config.redis.port + } }); await client.connect(); diff --git a/bbb-export-annotations/workers/collector.js b/bbb-export-annotations/workers/collector.js index 8448363da8..362d3bfb91 100644 --- a/bbb-export-annotations/workers/collector.js +++ b/bbb-export-annotations/workers/collector.js @@ -25,9 +25,11 @@ const jobType = exportJob.jobType; async function collectAnnotationsFromRedis() { const client = redis.createClient({ - host: config.redis.host, - port: config.redis.port, password: config.redis.password, + socket: { + host: config.redis.host, + port: config.redis.port + } }); client.on('error', (err) => logger.info('Redis Client Error', err)); diff --git a/bbb-export-annotations/workers/notifier.js b/bbb-export-annotations/workers/notifier.js index d42c8cc1e5..b05c14c6a8 100644 --- a/bbb-export-annotations/workers/notifier.js +++ b/bbb-export-annotations/workers/notifier.js @@ -20,9 +20,11 @@ const exportJob = JSON.parse(job); * sending a message through Redis PubSub */ async function notifyMeetingActor() { const client = redis.createClient({ - host: config.redis.host, - port: config.redis.port, password: config.redis.password, + socket: { + host: config.redis.host, + port: config.redis.port + } }); await client.connect(); diff --git a/bbb-export-annotations/workers/process.js b/bbb-export-annotations/workers/process.js index f8ce932c46..86ab5757ea 100644 --- a/bbb-export-annotations/workers/process.js +++ b/bbb-export-annotations/workers/process.js @@ -794,9 +794,11 @@ function overlay_annotations(svg, currentSlideAnnotations) { // Process the presentation pages and annotations into a PDF file async function process_presentation_annotations() { const client = redis.createClient({ - host: config.redis.host, - port: config.redis.port, password: config.redis.password, + socket: { + host: config.redis.host, + port: config.redis.port + } }); await client.connect(); @@ -873,6 +875,7 @@ async function process_presentation_annotations() { SVGfile, '--output-width', to_px(slideWidth), '--output-height', to_px(slideHeight), + '-u', '-o', PDFfile, ];