Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for NewSchemasBuilder (0.24 sec)

  1. pkg/config/schema/codegen/templates/collections.go.tmpl

    		}.MustBuild()
    {{ end }}
    
    	// All contains all collections in the system.
    	All = collection.NewSchemasBuilder().
    	{{- range .Entries }}
    		MustAdd({{ .Resource.Identifier }}).
    	{{- end }}
    		Build()
    
    	// Kube contains only kubernetes collections.
    	Kube = collection.NewSchemasBuilder().
    	{{- range .Entries }}
    		{{- if or (contains .Resource.Group "k8s.io") .Resource.Builtin  }}
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 25 14:44:17 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  2. pkg/config/schema/collection/schemas.go

    func SchemasFor(schemas ...resource.Schema) Schemas {
    	b := NewSchemasBuilder()
    	for _, s := range schemas {
    		b.MustAdd(s)
    	}
    	return b.Build()
    }
    
    // SchemasBuilder is a builder for the schemas type.
    type SchemasBuilder struct {
    	schemas Schemas
    }
    
    // NewSchemasBuilder returns a new instance of SchemasBuilder.
    func NewSchemasBuilder() *SchemasBuilder {
    	s := Schemas{
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Aug 01 08:10:15 UTC 2023
    - 6K bytes
    - Viewed (0)
  3. pkg/config/analysis/legacy/util/kuberesource/resources.go

    	resultBuilder := collection.NewSchemasBuilder()
    	for _, gv := range inputs {
    		s, f := collections.All.FindByGroupVersionKind(gv)
    		if !f {
    			continue
    		}
    		_ = resultBuilder.Add(s)
    	}
    
    	return resultBuilder.Build()
    }
    
    func DefaultExcludedSchemas() collection.Schemas {
    	resultBuilder := collection.NewSchemasBuilder()
    	for _, r := range collections.Kube.All() {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 02 08:32:06 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  4. pkg/config/schema/collection/schemas_test.go

    	defer func() {
    		r := recover()
    		g.Expect(r).To(BeNil())
    	}()
    	b := collection.NewSchemasBuilder()
    
    	b.MustAdd(emptyResource)
    }
    
    func TestSchemas_MustRegister_Panic(t *testing.T) {
    	g := NewWithT(t)
    	defer func() {
    		r := recover()
    		g.Expect(r).NotTo(BeNil())
    	}()
    	b := collection.NewSchemasBuilder()
    
    	b.MustAdd(emptyResource)
    	b.MustAdd(emptyResource)
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 31 14:48:28 UTC 2023
    - 5.4K bytes
    - Viewed (0)
  5. pkg/config/schema/collections/collections.agent.gen.go

    		MustAdd(WorkloadEntry).
    		MustAdd(WorkloadGroup).
    		Build()
    
    	// Kube contains only kubernetes collections.
    	Kube = collection.NewSchemasBuilder().
    		Build()
    
    	// Pilot contains only collections used by Pilot.
    	Pilot = collection.NewSchemasBuilder().
    		MustAdd(AuthorizationPolicy).
    		MustAdd(DestinationRule).
    		MustAdd(Gateway).
    		MustAdd(PeerAuthentication).
    		MustAdd(ProxyConfig).
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 25 14:44:17 UTC 2024
    - 12.9K bytes
    - Viewed (0)
  6. pkg/config/analysis/analyzer_test.go

    	a := Combine("combined", a1, a2, a3, a4)
    	g.Expect(a.Metadata().Inputs).To(ConsistOf(col1.GroupVersionKind(), col2.GroupVersionKind(), col3.GroupVersionKind(), col4.GroupVersionKind()))
    
    	removed := a.RemoveSkipped(collection.NewSchemasBuilder().MustAdd(col1).MustAdd(col2).Build())
    
    	g.Expect(removed).To(ConsistOf(a3.Metadata().Name, a4.Metadata().Name))
    	g.Expect(a.Metadata().Inputs).To(ConsistOf(col1.GroupVersionKind(), col2.GroupVersionKind()))
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 31 14:48:28 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  7. pkg/config/schema/collections/mock.go

    			if cfg.Spec.(*testconfig.MockConfig).Key == "" {
    				return nil, errors.New("empty key")
    			}
    			return nil, nil
    		},
    	}.MustBuild()
    
    	// Mocks is a Schemas containing the Mock Schema.
    	Mocks = collection.NewSchemasBuilder().MustAdd(Mock).Build()
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Mar 01 01:34:15 UTC 2023
    - 1.4K bytes
    - Viewed (0)
  8. pkg/config/schema/collections/collections.gen.go

    		ClusterScoped: false,
    		Synthetic:     false,
    		Builtin:       false,
    		ValidateProto: validation.ValidateWorkloadGroup,
    	}.MustBuild()
    
    	// All contains all collections in the system.
    	All = collection.NewSchemasBuilder().
    		MustAdd(AuthorizationPolicy).
    		MustAdd(CertificateSigningRequest).
    		MustAdd(ConfigMap).
    		MustAdd(CustomResourceDefinition).
    		MustAdd(DaemonSet).
    		MustAdd(Deployment).
    		MustAdd(DestinationRule).
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 25 14:44:17 UTC 2024
    - 31.4K bytes
    - Viewed (0)
  9. pilot/pkg/config/aggregate/config.go

    // makeStore creates an aggregate config store from several config stores and
    // unifies their descriptors
    func makeStore(stores []model.ConfigStore, writer model.ConfigStore) (model.ConfigStore, error) {
    	union := collection.NewSchemasBuilder()
    	storeTypes := make(map[config.GroupVersionKind][]model.ConfigStore)
    	for _, store := range stores {
    		for _, s := range store.Schemas().All() {
    			if len(storeTypes[s.GroupVersionKind()]) == 0 {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Dec 26 01:14:27 UTC 2023
    - 5.4K bytes
    - Viewed (0)
  10. pilot/pkg/config/kube/crdclient/client_test.go

    		Spec: pb,
    	}); err != nil {
    		t.Fatalf("Create => got %v", err)
    	}
    
    	return pb
    }
    
    // Ensure that the client can run without CRDs present
    func TestClientNoCRDs(t *testing.T) {
    	schema := collection.NewSchemasBuilder().MustAdd(collections.Sidecar).Build()
    	store, _ := makeClient(t, schema, nil)
    	retry.UntilOrFail(t, store.HasSynced, retry.Timeout(time.Second))
    	r := collections.VirtualService
    	configMeta := config.Meta{
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri May 10 02:58:52 UTC 2024
    - 14.1K bytes
    - Viewed (0)
Back to top