فهرست منبع

refactor: added some more logging to maybe figure out station issue

Kristian Vos 5 سال پیش
والد
کامیت
2d4df6e1ab
2فایلهای تغییر یافته به همراه3 افزوده شده و 1 حذف شده
  1. 2 1
      backend/logic/notifications.js
  2. 1 0
      backend/logic/stations.js

+ 2 - 1
backend/logic/notifications.js

@@ -89,8 +89,9 @@ module.exports = class extends coreClass {
 			});
 
 			this.sub.on('pmessage', (pattern, channel, expiredKey) => {
-				this.logger.stationIssue(`PMESSAGE - Pattern: ${pattern}; Channel: ${channel}; ExpiredKey: ${expiredKey}`);
+				this.logger.stationIssue(`PMESSAGE1 - Pattern: ${pattern}; Channel: ${channel}; ExpiredKey: ${expiredKey}`);
 				subscriptions.forEach((sub) => {
+					this.logger.stationIssue(`PMESSAGE2 - Sub name: ${sub.name}; Calls cb: ${!(sub.name !== expiredKey)}`);
 					if (sub.name !== expiredKey) return;
 					sub.cb();
 				});

+ 1 - 0
backend/logic/stations.js

@@ -329,6 +329,7 @@ module.exports = class extends coreClass {
 		this.logger.info("STATION_SKIP", `Skipping station ${stationId}.`, false);
 		return async (cb) => {
 			try { await this._validateHook(); } catch { return; }
+			this.logger.stationIssue(`SKIP_STATION_CB - Station ID: ${stationId}.`);
 
 			if (typeof cb !== 'function') cb = ()=>{};