-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Open
Labels
type/enhancementThe issue or PR belongs to an enhancement.The issue or PR belongs to an enhancement.
Description
Enhancement
Currently the context usage is a bit of messy. One problem is #56017 and I think a better context usage and cancellation will solve it. After a simple review of current DDL code, I think there should to 2 types of context:
- the context of a DDL job. All job execution logic should use this context. And another goroutine polling the job state should cancel the context if it's not
JobStateRunning. - the context of DDL module. Job rollingback, canceling, cleanup, scheduling, execution and other module-level action should use this context. It's canceled when the parent context is canceled which means domain is closing.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type/enhancementThe issue or PR belongs to an enhancement.The issue or PR belongs to an enhancement.