-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automation logging updates #10626
Automation logging updates #10626
Conversation
// An error occurred. | ||
console.error(...getLogParams(eventType, BullEvent.ERROR, { error })) | ||
}) | ||
|
||
if (process.env.NODE_DEBUG?.includes("bull")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm planning on turning off bull
debug logging by default (after investigation) to bring down logging costs, hence the stalled
and error
logs above being promoted to logging by default
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Would be good after getting this merged to pull it back to development as some of the types changes will have implications for sync automations - theres a few changes around Job
types already!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small comment, but LGTM
@@ -104,6 +104,22 @@ async function newContext(updates: ContextMap, task: any) { | |||
return Context.run(context, task) | |||
} | |||
|
|||
export async function doInAutomationContext( | |||
appId: string, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use an object as a parameter to make it more verbose in its usage?
export async function doInAutomationContext(params: {
appId: string,
automationId: string,
task: any
})
+1 to this, some of the stuff you've done around the triggers and automation thread code overlap quite heavily with some work I was doing for sync automations. LGTM though! |
Description
Updates to logging for better pino integration to aid debugging via datadog.
Additionally add some better type definitions around bull jobs specific to automations.