Skip to content

Commit

Permalink
Add support for temporal v1.24.x
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandrevilain committed Sep 8, 2024
1 parent 6110327 commit 564d33e
Show file tree
Hide file tree
Showing 42 changed files with 310 additions and 211 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM --platform=${BUILDPLATFORM} golang:1.22.2 as builder
FROM --platform=${BUILDPLATFORM} golang:1.22.2 AS builder

ARG TARGETPLATFORM
ARG BUILDPLATFORM
Expand Down
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down Expand Up @@ -62,18 +62,20 @@ Somes examples are available to help you get started:
The following table shows operator compatibility with Temporal and Kubernetes.
Please note this table only reports end-to-end tests suite coverage, others versions *may* work.
| Temporal Operator | Temporal | Kubernetes |
|-------------------|--------------------|----------------|
| v0.18.x | v1.19.x to v1.23.x | v1.25 to v1.29 |
| v0.17.x | v1.18.x to v1.22.x | v1.25 to v1.29 |
| v0.16.x | v1.18.x to v1.22.x | v1.24 to v1.27 |
| v0.15.x | v1.18.x to v1.21.x | v1.24 to v1.27 |
| v0.14.x | v1.18.x to v1.21.x | v1.24 to v1.27 |
| v0.13.x | v1.18.x to v1.20.x | v1.24 to v1.27 |
| v0.12.x | v1.18.x to v1.20.x | v1.23 to v1.26 |
| v0.11.x | v1.17.x to v1.19.x | v1.23 to v1.26 |
| v0.10.x | v1.17.x to v1.19.x | v1.23 to v1.26 |
| v0.9.x | v1.16.x to v1.18.x | v1.22 to v1.25 |
| Temporal Operator | Temporal | Kubernetes |
|------------------------|--------------------|----------------|
| v0.20.x (not released) | v1.19.x to v1.24.x | v1.26 to v1.30 |
| v0.19.x | v1.19.x to v1.23.x | v1.25 to v1.29 |
| v0.18.x | v1.19.x to v1.23.x | v1.25 to v1.29 |
| v0.17.x | v1.18.x to v1.22.x | v1.25 to v1.29 |
| v0.16.x | v1.18.x to v1.22.x | v1.24 to v1.27 |
| v0.15.x | v1.18.x to v1.21.x | v1.24 to v1.27 |
| v0.14.x | v1.18.x to v1.21.x | v1.24 to v1.27 |
| v0.13.x | v1.18.x to v1.20.x | v1.24 to v1.27 |
| v0.12.x | v1.18.x to v1.20.x | v1.23 to v1.26 |
| v0.11.x | v1.17.x to v1.19.x | v1.23 to v1.26 |
| v0.10.x | v1.17.x to v1.19.x | v1.23 to v1.26 |
| v0.9.x | v1.16.x to v1.18.x | v1.22 to v1.25 |
## Roadmap
Expand Down
16 changes: 13 additions & 3 deletions api/v1beta1/temporalcluster_defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,14 @@ import (
)

const (
defaultTemporalVersion = "1.23.0"
defaultTemporalVersion = "1.24.2"
defaultTemporalImage = "temporalio/server"

defaultTemporalUIVersion = "2.25.0"
defaultTemporalUIVersion = "2.27.3"
defaultTemporalUIImage = "temporalio/ui"

defaultTemporalAdmintoolsImage = "temporalio/admin-tools"
defaultTemporalAdmintoolsImage = "temporalio/admin-tools"
defaultTemporalAdmintoolsVersion = "1.24.2-tctl-1.18.1-cli-0.13.2"
)

// Default set default fields values.
Expand Down Expand Up @@ -213,6 +214,15 @@ func (c *TemporalCluster) Default() {
c.Spec.AdminTools.Image = defaultTemporalAdmintoolsImage
}

if c.Spec.AdminTools.Version == "" {
if c.Spec.Version.GreaterOrEqual(version.V1_24_0) {
c.Spec.AdminTools.Version = defaultTemporalAdmintoolsVersion
} else {
c.Spec.AdminTools.Version = c.Spec.Version.String()
}

}

Check failure on line 224 in api/v1beta1/temporalcluster_defaults.go

View workflow job for this annotation

GitHub Actions / Lint files

unnecessary trailing newline (whitespace)

if c.Spec.MTLS != nil {
if c.Spec.MTLS.RefreshInterval == nil {
c.Spec.MTLS.RefreshInterval = &metav1.Duration{Duration: time.Hour}
Expand Down
3 changes: 3 additions & 0 deletions api/v1beta1/temporalcluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -585,6 +585,9 @@ type TemporalAdminToolsSpec struct {
// Image defines the temporal admin tools docker image the instance should run.
// +optional
Image string `json:"image"`
// Version defines the temporal admin tools version the instance should run.
// +optional
Version string `json:"version"`
// Compute Resources required by the ui.
// More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
// +optional
Expand Down
10 changes: 6 additions & 4 deletions api/v1beta1/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 @@ -191,7 +191,7 @@ spec:
user: temporal
ui:
enabled: true
version: 1.23.0
version: 1.24.2
</pre>
### Apply TemporalCluster CustomResource
Expand Down
3 changes: 3 additions & 0 deletions config/crd/bases/temporal.io_temporalclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,9 @@ spec:
More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
type: object
type: object
version:
description: Version defines the temporal admin tools version the instance should run.
type: string
type: object
archival:
description: Archival allows Workflow Execution Event Histories and Visibility data backups for the temporal cluster.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ spec:
user: temporal
ui:
enabled: true
version: 1.23.0
version: 1.24.2
</pre>
### Apply TemporalCluster CustomResource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ spec:
user: temporal
ui:
enabled: true
version: 1.23.0
version: 1.24.2
</pre>

### Apply TemporalCluster CustomResource
Expand Down
2 changes: 1 addition & 1 deletion config/samples/temporal.io_v1beta1_temporalcluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
12 changes: 12 additions & 0 deletions docs/api/v1beta1.md
Original file line number Diff line number Diff line change
Expand Up @@ -4574,6 +4574,18 @@ string
</tr>
<tr>
<td>
<code>version</code><br>
<em>
string
</em>
</td>
<td>
<em>(Optional)</em>
<p>Version defines the temporal admin tools version the instance should run.</p>
</td>
</tr>
<tr>
<td>
<code>resources</code><br>
<em>
<a href="https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.23/#resourcerequirements-v1-core">
Expand Down
4 changes: 2 additions & 2 deletions docs/features/admin-tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
admintools:
enabled: true
# You can specify the admin tools version if needed.
# Check available tag you can check by the link below
# https://hub.docker.com/r/temporalio/admin-tools/tags
version: 1.23.0
version: 1.24.2-tctl-1.18.1-cli-0.13.2
```
8 changes: 4 additions & 4 deletions docs/features/archival.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
archival:
Expand Down Expand Up @@ -104,7 +104,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
archival:
Expand Down Expand Up @@ -142,7 +142,7 @@ kind: TemporalCluster
metadata:
name: prod
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
services:
Expand Down Expand Up @@ -195,7 +195,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
archival:
Expand Down
2 changes: 1 addition & 1 deletion docs/features/dynamic-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
dynamicConfig:
Expand Down
2 changes: 1 addition & 1 deletion docs/features/monitoring/prometheus-operator.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
metrics:
Expand Down
2 changes: 1 addition & 1 deletion docs/features/monitoring/prometheus.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
metrics:
Expand Down
8 changes: 4 additions & 4 deletions docs/features/temporal-ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
ui:
Expand All @@ -39,7 +39,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
ui:
Expand All @@ -63,7 +63,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
# [...]
ui:
Expand Down Expand Up @@ -92,7 +92,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
ui:
enabled: true
Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-cassandra/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-mtls-istio/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-mtls-linkerd/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-mtls/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-mysql/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-postgres-es/03-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
jobTtlSecondsAfterFinished: 300
persistence:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-postgres/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down
2 changes: 1 addition & 1 deletion examples/cluster-sidecar/02-temporal-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: prod
namespace: demo
spec:
version: 1.23.0
version: 1.24.2
numHistoryShards: 1
persistence:
defaultStore:
Expand Down
Loading

0 comments on commit 564d33e

Please sign in to comment.