Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for withAudit (0.13 sec)

  1. staging/src/k8s.io/apiserver/pkg/server/config_test.go

    func TestAuthenticationAuditAnnotationsDefaultChain(t *testing.T) {
    	authn := authenticator.RequestFunc(func(req *http.Request) (*authenticator.Response, bool, error) {
    		// confirm that we can set an audit annotation in a handler before WithAudit
    		audit.AddAuditAnnotation(req.Context(), "pandas", "are awesome")
    
    		return &authenticator.Response{User: &user.DefaultInfo{}}, true, nil
    	})
    	backend := &testBackend{}
    	c := &Config{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Apr 29 18:59:21 UTC 2024
    - 13.1K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/endpoints/handlers/patch.go

    			scope.err(err, w, req)
    			return
    		}
    		options.TypeMeta.SetGroupVersionKind(metav1.SchemeGroupVersion.WithKind("PatchOptions"))
    
    		admit = admission.WithAudit(admit)
    
    		audit.LogRequestPatch(req.Context(), patchBytes)
    		span.AddEvent("Recorded the audit event")
    
    		baseContentType := runtime.ContentTypeJSON
    		if patchType == types.ApplyPatchType {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 28 08:48:22 UTC 2024
    - 28.5K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/server/config.go

    	handler = filterlatency.TrackStarted(handler, c.TracerProvider, "impersonation")
    
    	handler = filterlatency.TrackCompleted(handler)
    	handler = genericapifilters.WithAudit(handler, c.AuditBackend, c.AuditPolicyRuleEvaluator, c.LongRunningFunc)
    	handler = filterlatency.TrackStarted(handler, c.TracerProvider, "audit")
    
    	failedHandler := genericapifilters.Unauthorized(c.Serializer)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 28 08:48:22 UTC 2024
    - 47.7K bytes
    - Viewed (0)
  4. manifests/addons/dashboards/lib/panels.libsonnet

          + timeSeries.standardOptions.withUnit('short')
          + timeSeries.standardOptions.withDecimals(0),
    
        seconds(title, targets, desc=''):
          self.base(title, targets, desc)
          + timeSeries.standardOptions.withUnit('s'),
    
        connections(title, targets, desc=''):
          self.base(title, targets, desc)
          + timeSeries.standardOptions.withUnit('cps'),
    
        dns(title, targets, desc=''):
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Jun 12 20:46:28 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  5. pkg/monitoring/options.go

    type options struct {
    	enabledCondition func() bool
    	unit             Unit
    	name             string
    	description      string
    }
    
    // WithUnit provides configuration options for a new Metric, providing unit of measure
    // information for a new Metric.
    func WithUnit(unit Unit) Options {
    	return func(opts *options) {
    		opts.unit = unit
    	}
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 17 20:25:52 UTC 2023
    - 1.6K bytes
    - Viewed (0)
  6. pkg/monitoring/example_gauge_test.go

    package monitoring_test
    
    import "istio.io/istio/pkg/monitoring"
    
    var pushLatency = monitoring.NewGauge(
    	"push_latency_seconds",
    	"Duration, measured in seconds, of the last push",
    	monitoring.WithUnit(monitoring.Seconds),
    )
    
    func ExampleNewGauge() {
    	// only the last recorded value (99.2) will be exported for this gauge
    	pushLatency.Record(77.3)
    	pushLatency.Record(22.8)
    	pushLatency.Record(99.2)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 17 20:25:52 UTC 2023
    - 994 bytes
    - Viewed (0)
  7. pkg/monitoring/example_distribution_test.go

    var (
    	method = monitoring.CreateLabel("method")
    
    	receivedBytes = monitoring.NewDistribution(
    		"received_bytes_total",
    		"Distribution of received bytes by method",
    		[]float64{10, 100, 1000, 10000},
    		monitoring.WithUnit(monitoring.Bytes),
    	)
    )
    
    func ExampleNewDistribution() {
    	receivedBytes.With(method.Value("/projects/1")).Record(458)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 17 20:25:52 UTC 2023
    - 995 bytes
    - Viewed (0)
  8. pkg/monitoring/distribution.go

    }
    
    var _ Metric = &distribution{}
    
    func newDistribution(o options) *distribution {
    	d, err := meter().Float64Histogram(o.name,
    		api.WithDescription(o.description),
    		api.WithUnit(string(o.unit)))
    	if err != nil {
    		log.Fatalf("failed to create distribution: %v", err)
    	}
    	r := &distribution{d: d}
    	r.baseMetric = baseMetric{
    		name: o.name,
    		rest: r,
    	}
    	return r
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 17 20:25:52 UTC 2023
    - 1.8K bytes
    - Viewed (0)
  9. pkg/monitoring/counter.go

    	precomputedAddOption []api.AddOption
    }
    
    var _ Metric = &counter{}
    
    func newCounter(o options) *counter {
    	c, err := meter().Float64Counter(o.name,
    		api.WithDescription(o.description),
    		api.WithUnit(string(o.unit)))
    	if err != nil {
    		log.Fatalf("failed to create counter: %v", err)
    	}
    	r := &counter{c: c}
    	r.baseMetric = baseMetric{
    		name: o.name,
    		rest: r,
    	}
    	return r
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 17 20:25:52 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  10. pkg/monitoring/gauge.go

    			defer r.attributeSetsMutex.Unlock()
    			for _, gv := range r.attributeSets {
    				observer.Observe(gv.val, gv.opt...)
    			}
    			return nil
    		}),
    		api.WithDescription(o.description),
    		api.WithUnit(string(o.unit)))
    	if err != nil {
    		log.Fatalf("failed to create gauge: %v", err)
    	}
    	r.g = g
    	r.baseMetric = baseMetric{
    		name: o.name,
    		rest: r,
    	}
    	return r
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Sep 13 16:04:48 UTC 2023
    - 2.9K bytes
    - Viewed (0)
Back to top