rebase: update kubernetes to 1.28.0 in main

updating kubernetes to 1.28.0
in the main repo.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
Madhu Rajanna
2023-08-17 07:15:28 +02:00
committed by mergify[bot]
parent b2fdc269c3
commit ff3e84ad67
706 changed files with 45252 additions and 16346 deletions

View File

@ -18,11 +18,13 @@ import "fmt"
type options struct {
maxRecursionDepth int
errorReportingLimit int
errorRecoveryTokenLookaheadLimit int
errorRecoveryLimit int
expressionSizeCodePointLimit int
macros map[string]Macro
populateMacroCalls bool
enableOptionalSyntax bool
}
// Option configures the behavior of the parser.
@ -45,7 +47,7 @@ func MaxRecursionDepth(limit int) Option {
// successfully resume. In some pathological cases, the parser can look through quite a large set of input which
// in turn generates a lot of back-tracking and performance degredation.
//
// The limit must be > 1, and is recommended to be less than the default of 256.
// The limit must be >= 1, and is recommended to be less than the default of 256.
func ErrorRecoveryLookaheadTokenLimit(limit int) Option {
return func(opts *options) error {
if limit < 1 {
@ -67,6 +69,19 @@ func ErrorRecoveryLimit(limit int) Option {
}
}
// ErrorReportingLimit limits the number of syntax error reports before terminating parsing.
//
// The limit must be at least 1. If unset, the limit will be 100.
func ErrorReportingLimit(limit int) Option {
return func(opts *options) error {
if limit < 1 {
return fmt.Errorf("error reporting limit must be at least 1: %d", limit)
}
opts.errorReportingLimit = limit
return nil
}
}
// ExpressionSizeCodePointLimit is an option which limits the maximum code point count of an
// expression.
func ExpressionSizeCodePointLimit(expressionSizeCodePointLimit int) Option {
@ -102,3 +117,11 @@ func PopulateMacroCalls(populateMacroCalls bool) Option {
return nil
}
}
// EnableOptionalSyntax enables syntax for optional field and index selection.
func EnableOptionalSyntax(optionalSyntax bool) Option {
return func(opts *options) error {
opts.enableOptionalSyntax = optionalSyntax
return nil
}
}