mirror of
https://github.com/kubernetes-sigs/prometheus-adapter.git
synced 2026-04-07 22:25:03 +00:00
vendor: Update vendor logic
This commit is contained in:
parent
c6ac5cbc87
commit
4ca64b85f0
1540 changed files with 265304 additions and 91616 deletions
5
vendor/k8s.io/apiserver/pkg/authorization/union/union.go
generated
vendored
5
vendor/k8s.io/apiserver/pkg/authorization/union/union.go
generated
vendored
|
|
@ -25,6 +25,7 @@ limitations under the License.
|
|||
package union
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strings"
|
||||
|
||||
utilerrors "k8s.io/apimachinery/pkg/util/errors"
|
||||
|
|
@ -41,14 +42,14 @@ func New(authorizationHandlers ...authorizer.Authorizer) authorizer.Authorizer {
|
|||
}
|
||||
|
||||
// Authorizes against a chain of authorizer.Authorizer objects and returns nil if successful and returns error if unsuccessful
|
||||
func (authzHandler unionAuthzHandler) Authorize(a authorizer.Attributes) (authorizer.Decision, string, error) {
|
||||
func (authzHandler unionAuthzHandler) Authorize(ctx context.Context, a authorizer.Attributes) (authorizer.Decision, string, error) {
|
||||
var (
|
||||
errlist []error
|
||||
reasonlist []string
|
||||
)
|
||||
|
||||
for _, currAuthzHandler := range authzHandler {
|
||||
decision, reason, err := currAuthzHandler.Authorize(a)
|
||||
decision, reason, err := currAuthzHandler.Authorize(ctx, a)
|
||||
|
||||
if err != nil {
|
||||
errlist = append(errlist, err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue