Skip to content

Commit

Permalink
Implement SparkApplication integration (without dynamic scaling)
Browse files Browse the repository at this point in the history
Signed-off-by: Shingo Omura <everpeace@gmail.com>
  • Loading branch information
everpeace committed Jan 21, 2025
1 parent 298decd commit 799345a
Show file tree
Hide file tree
Showing 10 changed files with 1,445 additions and 1 deletion.
2 changes: 2 additions & 0 deletions config/components/manager/controller_manager_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ integrations:
- "kubeflow.org/tfjob"
- "kubeflow.org/xgboostjob"
- "workload.codeflare.dev/appwrapper"
- "codeflare.dev/appwrapper"
- "sparkoperator.k8s.io/sparkapplication"
# - "pod"
# - "deployment" # requires enabling pod integration
# - "statefulset" # requires enabling pod integration
Expand Down
2 changes: 1 addition & 1 deletion config/components/manager/manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ spec:
- /manager
args:
- "--zap-log-level=2"
imagePullPolicy: Always
imagePullPolicy: IfNotPresent
image: controller:latest
name: manager
securityContext:
Expand Down
25 changes: 25 additions & 0 deletions config/components/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,31 @@ rules:
- get
- list
- watch
- apiGroups:
- sparkoperator.k8s.io
resources:
- sparkapplications
verbs:
- get
- list
- patch
- update
- watch
- apiGroups:
- sparkoperator.k8s.io
resources:
- sparkapplications/finalizers
verbs:
- get
- update
- apiGroups:
- sparkoperator.k8s.io
resources:
- sparkapplications/status
verbs:
- get
- patch
- update
- apiGroups:
- workload.codeflare.dev
resources:
Expand Down
39 changes: 39 additions & 0 deletions config/components/webhook/manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,25 @@ webhooks:
resources:
- rayjobs
sideEffects: None
- admissionReviewVersions:
- v1
clientConfig:
service:
name: webhook-service
namespace: system
path: /mutate-sparkoperator-k8s-io-v1beta2-sparkapplication
failurePolicy: Fail
name: msparkapplication.kb.io
rules:
- apiGroups:
- sparkoperator.k8s.io
apiVersions:
- v1beta2
operations:
- CREATE
resources:
- sparkapplications
sideEffects: None
- admissionReviewVersions:
- v1
clientConfig:
Expand Down Expand Up @@ -596,6 +615,26 @@ webhooks:
resources:
- rayjobs
sideEffects: None
- admissionReviewVersions:
- v1
clientConfig:
service:
name: webhook-service
namespace: system
path: /validate-sparkoperator-k8s-io-v1beta2-sparkapplication
failurePolicy: Fail
name: vsparkapplication.kb.io
rules:
- apiGroups:
- sparkoperator.k8s.io
apiVersions:
- v1beta2
operations:
- CREATE
- UPDATE
resources:
- sparkapplications
sideEffects: None
- admissionReviewVersions:
- v1
clientConfig:
Expand Down
1 change: 1 addition & 0 deletions pkg/controller/jobs/jobs.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,6 @@ import (
_ "sigs.k8s.io/kueue/pkg/controller/jobs/pod"
_ "sigs.k8s.io/kueue/pkg/controller/jobs/raycluster"
_ "sigs.k8s.io/kueue/pkg/controller/jobs/rayjob"
_ "sigs.k8s.io/kueue/pkg/controller/jobs/sparkapplication"
_ "sigs.k8s.io/kueue/pkg/controller/jobs/statefulset"
)
Loading

0 comments on commit 799345a

Please sign in to comment.