Skip to content

Commit

Permalink
Add make gen fmt
Browse files Browse the repository at this point in the history
Signed-off-by: obaydullahmhs <[email protected]>
  • Loading branch information
obaydullahmhs committed Sep 25, 2023
1 parent 07151ca commit 511b300
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 12 deletions.
1 change: 1 addition & 0 deletions apis/kubedb/v1alpha2/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -522,6 +522,7 @@ const (
KafkaPortNameExternal = "external"
KafkaTopicNameHealth = "kafka-health"
KafkaTopicDeletionThresholdOffset = 1000
KafkaMaxNumberOfController = 1000
KafkaRESTPort = 9092
KafkaControllerRESTPort = 9093
KafkaInternalRESTPort = 29092
Expand Down
18 changes: 9 additions & 9 deletions apis/ops/v1alpha1/kafka_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,47 +27,47 @@ import (
"kmodules.xyz/client-go/apiextensions"
)

func (_ KafkaOpsRequest) CustomResourceDefinition() *apiextensions.CustomResourceDefinition {
func (_ *KafkaOpsRequest) CustomResourceDefinition() *apiextensions.CustomResourceDefinition {
return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralKafkaOpsRequest))
}

var _ apis.ResourceInfo = &KafkaOpsRequest{}

func (k KafkaOpsRequest) ResourceFQN() string {
func (k *KafkaOpsRequest) ResourceFQN() string {
return fmt.Sprintf("%s.%s", ResourcePluralKafkaOpsRequest, ops.GroupName)
}

func (k KafkaOpsRequest) ResourceShortCode() string {
func (k *KafkaOpsRequest) ResourceShortCode() string {
return ResourceCodeKafkaOpsRequest
}

func (k KafkaOpsRequest) ResourceKind() string {
func (k *KafkaOpsRequest) ResourceKind() string {
return ResourceKindKafkaOpsRequest
}

func (k KafkaOpsRequest) ResourceSingular() string {
func (k *KafkaOpsRequest) ResourceSingular() string {
return ResourceSingularKafkaOpsRequest
}

func (k KafkaOpsRequest) ResourcePlural() string {
func (k *KafkaOpsRequest) ResourcePlural() string {
return ResourcePluralKafkaOpsRequest
}

func (k KafkaOpsRequest) ValidateSpecs() error {
func (k *KafkaOpsRequest) ValidateSpecs() error {
return nil
}

var _ Accessor = &KafkaOpsRequest{}

func (k KafkaOpsRequest) GetRequestType() any {
func (k *KafkaOpsRequest) GetRequestType() any {
return k.Spec.Type
}

func (k *KafkaOpsRequest) GetObjectMeta() metav1.ObjectMeta {
return k.ObjectMeta
}

func (k KafkaOpsRequest) GetUpdateVersionSpec() *KafkaUpdateVersionSpec {
func (k *KafkaOpsRequest) GetUpdateVersionSpec() *KafkaUpdateVersionSpec {
return k.Spec.UpdateVersion
}

Expand Down
2 changes: 1 addition & 1 deletion apis/ops/v1alpha1/kafka_ops_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const (
// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase"
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"
type KafkaOpsRequest struct {
metav1.TypeMeta `json:",omitempty"`
metav1.TypeMeta `json:",inline,omitempty"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec KafkaOpsRequestSpec `json:"spec,omitempty"`
Status OpsRequestStatus `json:"status,omitempty"`
Expand Down
14 changes: 14 additions & 0 deletions apis/ops/v1alpha1/openapi_generated.go

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

4 changes: 2 additions & 2 deletions crds/ops.kubedb.com_kafkaopsrequests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -339,14 +339,14 @@ spec:
type: integer
reason:
type: string
severity:
type: string
status:
type: string
type:
type: string
required:
- lastTransitionTime
- message
- reason
- status
- type
type: object
Expand Down

0 comments on commit 511b300

Please sign in to comment.