10000 [Feature] [ML] GPU Jobs (#1549) · arangodb/kube-arangodb@de4def4 · GitHub
[go: up one dir, main page]

Skip to content

Commit de4def4

Browse files
authored
[Feature] [ML] GPU Jobs (#1549)
1 parent df65970 commit de4def4

File tree

5 files changed

+59
-3
lines changed

5 files changed

+59
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
- (Feature) (ML) Multi DB Settings
3838
- (Feature) (ML) Port adjustments
3939
- (Feature) (ML) Support for deployments with JWT auth enabled
40+
- (Feature) (ML) GPU Jobs
4041

4142
## [1.2.35](https://github.com/arangodb/kube-arangodb/tree/1.2.35) (2023-11-06)
4243
- (Maintenance) Update go-driver to v1.6.0, update IsNotFound() checks

docs/api/ArangoMLExtension.V1Alpha1.md

Lines changed: 33 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,16 @@ Links:
6666

6767
***
6868

69+
### .spec.deployment.prediction.gpu
70+
71+
Type: `boolean` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L31)</sup>
72+
73+
GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
74+
75+
Default Value: `false`
76+
77+
***
78+
6979
### .spec.deployment.prediction.image
7080

7181
Type: `string` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/shared/v1/image.go#L31)</sup>
@@ -76,7 +86,7 @@ Image define image details
7686

7787
### .spec.deployment.prediction.port
7888

79-
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L30)</sup>
89+
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L34)</sup>
8090

8191
Port defines on which port the container will be listening for connections
8292

@@ -122,6 +132,16 @@ Links:
122132

123133
***
124134

135+
### .spec.deployment.project.gpu
136+
137+
Type: `boolean` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L31)</sup>
138+
139+
GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
140+
141+
Default Value: `false`
142+
143+
***
144+
125145
### .spec.deployment.project.image
126146

127147
Type: `string` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/shared/v1/image.go#L31)</sup>
@@ -132,7 +152,7 @@ Image define image details
132152

133153
### .spec.deployment.project.port
134154

135-
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L30)</sup>
155+
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L34)</sup>
136156

137157
Port defines on which port the container will be listening for connections
138158

@@ -240,6 +260,16 @@ Links:
240260

241261
***
242262

263+
### .spec.deployment.training.gpu
264+
265+
Type: `boolean` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L31)</sup>
266+
267+
GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
268+
269+
Default Value: `false`
270+
271+
***
272+
243273
### .spec.deployment.training.image
244274

245275
Type: `string` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/shared/v1/image.go#L31)</sup>
@@ -250,7 +280,7 @@ Image define image details
250280

251281
### .spec.deployment.training.port
252282

253-
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L30)</sup>
283+
Type: `integer` <sup>[\[ref\]](https://github.com/arangodb/kube-arangodb/blob/1.2.35/pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go#L34)</sup>
254284

255285
Port defines on which port the container will be listening for connections
256286

pkg/apis/ml/v1alpha1/extension_spec_deployment_component.go

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,24 @@ import (
2626
)
2727

2828
type ArangoMLExtensionSpecDeploymentComponent struct {
29+
// GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
30+
// +doc/default: false
31+
GPU *bool `json:"gpu,omitempty"`
32+
2933
// Port defines on which port the container will be listening for connections
3034
Port *int32 `json:"port,omitempty"`
3135

3236
// ContainerTemplate Keeps the information about Container configuration
3337
*sharedApi.ContainerTemplate `json:",inline"`
3438
}
3539

40+
func (s *ArangoMLExtensionSpecDeploymentComponent) GetGPU() bool {
41+
if s == nil || s.GPU == nil {
42+
return false
43+
}
44+
return *s.GPU
45+
}
46+
3647
func (s *ArangoMLExtensionSpecDeploymentComponent) GetPort(def int32) int32 {
3748
if s == nil || s.Port == nil {
3849
return def

pkg/apis/ml/v1alpha1/zz_generated.deepcopy.go

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/crd/crds/ml-extension.schema.generated.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,9 @@ v1alpha1:
385385
prediction:
386386
description: Prediction defines how Prediction workload will be deployed
387387
properties:
388+
gpu:
389+
description: GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
390+
type: boolean
388391
image:
389392
description: Image define image details
390393
type: string
@@ -476,6 +479,9 @@ v1alpha1:
476479
project:
477480
description: Project defines how Project workload will be deployed
478481
properties:
482+
gpu:
483+
description: GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
484+
type: boolean
479485
image:
480486
description: Image define image details
481487
type: string
@@ -612,6 +618,9 @@ v1alpha1:
612618
training:
613619
description: Training defines how Training workload will be deployed
614620
properties:
621+
gpu:
622+
description: GPU defined if GPU Jobs are enabled for component. In use only for ArangoMLExtensionSpecDeploymentComponentPrediction and ArangoMLExtensionSpecDeploymentComponentTraining
623+
type: boolean
615624
image:
616625
description: Image define image details
617626
type: string

0 commit comments

Comments
 (0)
0