cockroachdb / cockroachdb/cockroach
mmaprototype: audit error cases from normalize constraints
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
**Describe the problem**
We should also look at the different cases where we return an error during the normalization and make sure we know what the caller is expected to do in each case and document contract in span config when needed.
We should update the comment in https://github.com/cockroachdb/cockroach/blob/master/pkg/roachpb/span_config.proto#L215-L218 to reflect what we say in [https://github.com/cockroachdb/cockroach/blob/57e9dc89f989448ce5912151b37e7bf866e48d26/pkg/kv/kvserver/allocator/mmaprototype/constraint.go#L7[…]790](https://github.com/cockroachdb/cockroach/blob/57e9dc89f989448ce5912151b37e7bf866e48d26/pkg/kv/kvserver/allocator/mmaprototype/constraint.go#L788-L790).
We should also look at what checks can be performed at the zone config validation level to surface an error immediately. https://github.com/cockroachdb/cockroach/blob/c68c559859be738efead9971f5e11f62a8c69d06/pkg/config/zonepb/zone_test.go#L28-L258.
Epic CRDB-56265
Jira issue: CRDB-57376
Contributor guide
Assessment
This issue has not been assessed yet.