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

enable stateful configs to connectors #510

Merged
merged 1 commit into from
Nov 7, 2022
Merged
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
3 changes: 3 additions & 0 deletions api/compute/v1alpha1/sink_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ type SinkSpec struct {

// Image pull policy, one of Always, Never, IfNotPresent, default to IfNotPresent.
ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`

// +kubebuilder:validation:Optional
StateConfig *Stateful `json:"statefulConfig,omitempty"`
}

// SinkStatus defines the observed state of Topic
Expand Down
3 changes: 3 additions & 0 deletions api/compute/v1alpha1/source_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ type SourceSpec struct {

// Image pull policy, one of Always, Never, IfNotPresent, default to IfNotPresent.
ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`

// +kubebuilder:validation:Optional
StateConfig *Stateful `json:"statefulConfig,omitempty"`
}

type BatchSourceConfig struct {
Expand Down
10 changes: 10 additions & 0 deletions api/compute/v1alpha1/zz_generated.deepcopy.go

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

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
name: functionmeshes.compute.functionmesh.io
spec:
group: compute.functionmesh.io
Expand Down Expand Up @@ -6091,6 +6091,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sinkType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
subscriptionName:
type: string
subscriptionPosition:
Expand Down Expand Up @@ -9069,6 +9088,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sourceType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
tenant:
type: string
volumeMounts:
Expand Down Expand Up @@ -9138,4 +9176,10 @@ spec:
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
{{- if eq .Values.admissionWebhook.certificate.provider "cert-manager" }}
{{- include "function-mesh-operator.certManager.annotation" . | nindent 4 -}}
{{- end }}
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
name: functions.compute.functionmesh.io
spec:
conversion:
Expand Down Expand Up @@ -3185,4 +3185,10 @@ spec:
specReplicasPath: .spec.replicas
statusReplicasPath: .status.replicas
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
{{- if eq .Values.admissionWebhook.certificate.provider "cert-manager" }}
{{- include "function-mesh-operator.certManager.annotation" . | nindent 4 -}}
{{- end }}
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
name: sinks.compute.functionmesh.io
spec:
conversion:
Expand Down Expand Up @@ -3005,6 +3005,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sinkType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
subscriptionName:
type: string
subscriptionPosition:
Expand Down Expand Up @@ -3074,4 +3093,10 @@ spec:
specReplicasPath: .spec.replicas
statusReplicasPath: .status.replicas
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
{{- if eq .Values.admissionWebhook.certificate.provider "cert-manager" }}
{{- include "function-mesh-operator.certManager.annotation" . | nindent 4 -}}
{{- end }}
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
name: sources.compute.functionmesh.io
spec:
conversion:
Expand Down Expand Up @@ -2989,6 +2989,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sourceType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
tenant:
type: string
volumeMounts:
Expand Down Expand Up @@ -3048,4 +3067,10 @@ spec:
specReplicasPath: .spec.replicas
statusReplicasPath: .status.replicas
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
{{- end }}
47 changes: 46 additions & 1 deletion config/crd/bases/compute.functionmesh.io_functionmeshes.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@

---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
creationTimestamp: null
name: functionmeshes.compute.functionmesh.io
spec:
Expand Down Expand Up @@ -6092,6 +6093,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sinkType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
subscriptionName:
type: string
subscriptionPosition:
Expand Down Expand Up @@ -9070,6 +9090,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sourceType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
tenant:
type: string
volumeMounts:
Expand Down Expand Up @@ -9139,3 +9178,9 @@ spec:
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
9 changes: 8 additions & 1 deletion config/crd/bases/compute.functionmesh.io_functions.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@

---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
creationTimestamp: null
name: functions.compute.functionmesh.io
spec:
Expand Down Expand Up @@ -3164,3 +3165,9 @@ spec:
specReplicasPath: .spec.replicas
statusReplicasPath: .status.replicas
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
28 changes: 27 additions & 1 deletion config/crd/bases/compute.functionmesh.io_sinks.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@

---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
controller-gen.kubebuilder.io/version: v0.6.2
creationTimestamp: null
name: sinks.compute.functionmesh.io
spec:
Expand Down Expand Up @@ -2984,6 +2985,25 @@ spec:
x-kubernetes-preserve-unknown-fields: true
sinkType:
type: string
statefulConfig:
properties:
pulsar:
properties:
javaProvider:
properties:
className:
type: string
config:
type: object
required:
- className
type: object
serviceUrl:
type: string
required:
- serviceUrl
type: object
type: object
subscriptionName:
type: string
subscriptionPosition:
Expand Down Expand Up @@ -3053,3 +3073,9 @@ spec:
specReplicasPath: .spec.replicas
statusReplicasPath: .status.replicas
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
Loading