cockroachdb / cockroachdb/cockroach
opt: apply external statement hints to routines inlined during normalization
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
Inline hint injection applies only to deferred routine body builds, which retry without hints on failure. Routines inlined during normalization (`ConvertUDFToSubquery`) are not hinted: an injection failure there surfaces via panic long after the rule ran, so a **fallback** requires replanning the enclosing statement, plus hint-dep staleness tracking for cached memos and a tighter `errorDueToInjectedHint` filter.
Part of #162627.
Epic: CRDB-66266
Contributor guide
Research direction
Start by tracing ConvertUDFToSubquery and the normalization path where routines are inlined. Then examine the existing deferred routine hint injection, replanning behavior, cached memo dependencies, and errorDueToInjectedHint filter. Done means inline routines receive external statement hints safely, failures trigger the required enclosing-statement fallback, and hint-dependency staleness is handled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100