SPYT Update Guide
This document outlines how to update SPYT using the Kubernetes operator.
Important Information Before Updating
During a SPYT update:
- The YTsaurus cluster continues operating normally.
- YTsaurus server components aren’t restarted.
- Data access via the YTsaurus API remains available.
- The update installs the new version alongside the current one without replacing it (Multiple SPYT Versions).
Before updating:
-
Verify compatibility between SPYT, Spark, Java, Scala, and Python versions.
Refer to the compatibility table. -
Review available SPYT versions and their changes.
See the SPYT releases.
Preparation for the Update
1. Check the Current SPYT Version
Retrieve the current SPYT version from the specification:
kubectl get spyt -n <namespace> -o yaml | grep image
Example output:
image: ghcr.io/ytsaurus/spyt:2.8.0
2. Check SPYT Status
Verify that SPYT is in the Finished state:
kubectl get spyt -n <namespace>
Example output:
NAME STATUS
<spyt-name> Finished
If SPYT isn’t in the Finished state, wait for ongoing operations to complete.
3. Save a Backup of the SPYT Specification
Save a backup of the current SPYT specification:
kubectl get spyt -n <namespace> -o yaml > spyt-backup.yaml
Updating SPYT
The operator doesn’t modify existing SPYT resources. Instead, it creates a new version as a separate resource. Both versions coexist on the cluster — their artifacts are stored side by side in Cypress. You can delete the old version later.
1. Prepare the Specification for the New Version
Use the current SPYT specification as a basis:
kubectl get spyt <spyt-name> -n <namespace> -o yaml
Create a spyt-<new-version>.yaml file with:
- A new resource name in the
metadata.namefield. - A new image version in the
imagefield.
Example specification for version 2.9.0:
apiVersion: cluster.ytsaurus.tech/v1
kind: Spyt
metadata:
name: spyt-2-9-0
namespace: <namespace>
spec:
image: ghcr.io/ytsaurus/spyt:2.9.0
ytsaurus:
name: <ytsaurus-name>
2. Apply the New Version
Apply the new version specification:
kubectl apply -f spyt-<new-version>.yaml -n <namespace>
The operator creates a new SPYT resource and uploads its artifacts to Cypress. The existing resource remains unchanged.
3. Track the Update Progress
Monitor the SPYT status during the update:
kubectl get spyt -n <namespace> -w
Update States:
| Status | Description |
|---|---|
CreatingUser |
The operator creates a user in Cypress. |
UploadingIntoCypress |
The operator uploads files to Cypress. |
Finished |
The update is complete. |
4. Verify the Update
-
Confirm that both resources are in the
Finishedstate:kubectl get spyt -n <namespace>Example output:
NAME STATUS <spyt-name> Finished <new-spyt-name> Finished -
Check the new image version:
kubectl get spyt -n <namespace> -o yaml | grep imageExample output:
image: ghcr.io/ytsaurus/spyt:2.9.0
Multiple SPYT Versions on a Single Cluster
The update process adds a new SPYT version as a separate resource, allowing multiple versions to coexist on the same YTsaurus cluster. Different teams can use different versions simultaneously.
SPYT and Spark artifacts are stored in Cypress at the path //home/spark/. The operator doesn’t delete old artifacts, so versions don’t interfere with each other.
Removing an Old SPYT Version
When the old SPYT version is no longer needed:
-
Delete the SPYT resource:
kubectl delete spyt <old-spyt-name> -n <namespace> -
Remove old artifacts from Cypress (if necessary):
- Open the
//home/spark/spyt/releasesand//home/spark/conf/releasesdirectories. - Locate nodes with the unwanted version number.
- Delete them from the context menu
- Open the