Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Status to NodeFeature CRD #1664

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion api/generated/clientset/versioned/clientset.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/clientset/versioned/fake/doc.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/clientset/versioned/fake/register.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/clientset/versioned/scheme/doc.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/clientset/versioned/scheme/register.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/informers/externalversions/factory.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/informers/externalversions/generic.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/informers/externalversions/nfd/interface.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/listers/nfd/v1alpha1/expansion_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/listers/nfd/v1alpha1/nodefeature.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/listers/nfd/v1alpha1/nodefeaturegroup.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/generated/listers/nfd/v1alpha1/nodefeaturerule.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 18 additions & 1 deletion api/nfd/v1alpha1/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ type NodeFeature struct {
metav1.ObjectMeta `json:"metadata,omitempty"`

// Specification of the NodeFeature, containing features discovered for a node.
Spec NodeFeatureSpec `json:"spec"`
Spec NodeFeatureSpec `json:"spec"`
Status NodeFeatureStatus `json:"status"`
ozhuraki marked this conversation as resolved.
Show resolved Hide resolved
}

// NodeFeatureSpec describes a NodeFeature object.
Expand All @@ -55,6 +56,22 @@ type NodeFeatureSpec struct {
Labels map[string]string `json:"labels"`
}

// Status of a NodeFeature object.
type NodeFeatureStatus struct {
// UTC time when the NodeFeature object was last updated.
// +optional
ozhuraki marked this conversation as resolved.
Show resolved Hide resolved
LastAppliedAt metav1.Time `json:"lastAppliedAt,omitempty"`
// +optional
// Number of features discovered.
NumberOfFeatures int `json:"numberOfFeatures,omitempty"`
// +optional
// Number of errors during last feature discovery.
NumberOfFeatureErrors int `json:"numberOfFeatureErrors,omitempty"`
ozhuraki marked this conversation as resolved.
Show resolved Hide resolved
// +optional
// Number of labels created.
NumberOfLabels int `json:"numberOfLabels,omitempty"`
}

// Features is the collection of all discovered features.
type Features struct {
// Flags contains all the flag-type features of the node.
Expand Down
20 changes: 19 additions & 1 deletion api/nfd/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions deployment/base/nfd-crds/nfd-api-crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,26 @@ spec:
be created.
type: object
type: object
status:
description: Status of a NodeFeature object.
properties:
lastAppliedAt:
description: UTC time when the NodeFeature object was last updated.
format: date-time
type: string
numberOfFeatureErrors:
description: Number of errors during last feature discovery.
type: integer
numberOfFeatures:
description: Number of features discovered.
type: integer
numberOfLabels:
description: Number of labels created.
type: integer
type: object
required:
- spec
- status
type: object
served: true
storage: true
Expand Down
18 changes: 18 additions & 0 deletions deployment/helm/node-feature-discovery/crds/nfd-api-crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,26 @@ spec:
be created.
type: object
type: object
status:
description: Status of a NodeFeature object.
properties:
lastAppliedAt:
description: UTC time when the NodeFeature object was last updated.
format: date-time
type: string
numberOfFeatureErrors:
description: Number of errors during last feature discovery.
type: integer
numberOfFeatures:
description: Number of features discovered.
type: integer
numberOfLabels:
description: Number of labels created.
type: integer
type: object
required:
- spec
- status
type: object
served: true
storage: true
Expand Down
Loading