Skip to content

Commit cc09011

Browse files
author
Maksym Trofimenko
committed
update tinynode api add module_version to the spec
1 parent 173d919 commit cc09011

File tree

6 files changed

+17
-3
lines changed

6 files changed

+17
-3
lines changed

api-docs.md

+1
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,7 @@ _Appears in:_
252252
| Field | Description |
253253
| --- | --- |
254254
| `module` _string_ | Module name - container image repo + tag |
255+
| `module_version` _string_ | Module version semver v2 compatible (without v prefix) |
255256
| `component` _string_ | Component name within a module |
256257
| `ports` _[TinyNodePortConfig](#tinynodeportconfig) array_ | Port configurations |
257258
| `edges` _[TinyNodeEdge](#tinynodeedge) array_ | Edges to send message next |

api/v1alpha1/tinynode_types.go

+5
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@ type TinyNodeSpec struct {
6363
// +kubebuilder:validation:Required
6464
Module string `json:"module"`
6565

66+
// Module version semver v2 compatible (without v prefix)
67+
// +kubebuilder:validation:Required
68+
// +kubebuilder:default="1.0.0"
69+
ModuleVersion string `json:"module_version"`
70+
6671
// Component name within a module
6772
// +kubebuilder:validation:Required
6873
Component string `json:"component"`

charts/tinysystems-crd/Chart.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ type: application
1313
# This is the chart version. This version number should be incremented each time you make changes
1414
# to the chart and its templates, including the app version.
1515
# Versions are expected to follow Semantic Versioning (https://semver.org/)
16-
version: 0.1.23
16+
version: 0.1.24
1717
# This is the version number of the application being deployed. This version number should be
1818
# incremented each time you make changes to the application. Versions are not expected to
1919
# follow Semantic Versioning. They should reflect the version the application is using.

charts/tinysystems-crd/templates/tinynode-crd.yaml

+5
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ spec:
7070
module:
7171
description: Module name - container image repo + tag
7272
type: string
73+
module_version:
74+
default: '''1.0.0'''
75+
description: Module version semver v2 compatible (without v prefix)
76+
type: string
7377
ports:
7478
description: Port configurations
7579
items:
@@ -96,6 +100,7 @@ spec:
96100
required:
97101
- component
98102
- module
103+
- module_version
99104
type: object
100105
status:
101106
description: TinyNodeStatus defines the observed state of TinyNode

config/crd/bases/operator.tinysystems.io_tinynodes.yaml

+5
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,10 @@ spec:
6969
module:
7070
description: Module name - container image repo + tag
7171
type: string
72+
module_version:
73+
default: 1.0.0
74+
description: Module version semver v2 compatible (without v prefix)
75+
type: string
7276
ports:
7377
description: Port configurations
7478
items:
@@ -95,6 +99,7 @@ spec:
9599
required:
96100
- component
97101
- module
102+
- module_version
98103
type: object
99104
status:
100105
description: TinyNodeStatus defines the observed state of TinyNode

internal/scheduler/scheduler.go

-2
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ type Scheduler interface {
2929
HandleInternal(ctx context.Context, msg *runner.Msg) error
3030
//Destroy stops the instance and deletes it
3131
Destroy(name string) error
32-
//Start starts scheduler
33-
Start(ctx context.Context) error
3432
}
3533

3634
type Schedule struct {

0 commit comments

Comments
 (0)