feat: add unknown integration log

This commit is contained in:
moonrailgun 2024-09-09 21:29:12 +08:00
parent ae3f5fce2d
commit d2afa54301

View File

@ -143,6 +143,8 @@ export const feedIntegrationRouter = router({
} }
} }
logUnknownIntegration('github', input);
return 'Not supported yet'; return 'Not supported yet';
}), }),
tencentCloudAlarm: publicProcedure tencentCloudAlarm: publicProcedure
@ -233,6 +235,8 @@ export const feedIntegrationRouter = router({
return 'ok'; return 'ok';
} }
logUnknownIntegration('tencentCloudAlarm', input);
return 'Not supported yet'; return 'Not supported yet';
}), }),
sentry: publicProcedure sentry: publicProcedure
@ -300,6 +304,8 @@ export const feedIntegrationRouter = router({
return 'ok'; return 'ok';
} }
logUnknownIntegration('sentry', input);
return 'Not supported yet'; return 'Not supported yet';
}), }),
}); });
@ -314,3 +320,7 @@ export function buildFeedPublicOpenapi(meta: OpenApiMetaInfo): OpenApiMeta {
}, },
}; };
} }
function logUnknownIntegration(source: string, input: any) {
logger.info(`[Feed Unknown Integration] ${source}: ${JSON.stringify(input)}`);
}