kubeflow / kubeflow/spark-operator

Request: Include memory parsing case-sensitivity fix in next release (v2.5.3 / v2.6.0)

Open
#3,176 1 comment 0 reactions 0 assignees View on GitHub
kind/feature
Dominant language
Python
Stars
3.2k
Forks
1.5k
Avg merge
5d 10h
Merged PRs (30d)
13

Description

### Why is this needed?

`ConvertJavaMemoryStringToK8sMemoryString()` has a case-sensitivity bug where uppercase suffixes produce invalid K8s quantities:

- `"8g"` → `"8Gi"` ✅
- `"8G"` → `"8GGi"` ❌

The function calls `strings.ToLower()` on the input but then runs `strings.TrimSuffix()` with the lowercase suffix against the **original (uppercase) string**. The trim is a no-op, so the suffix gets doubled.

Fix is merged to master ([f639568](https://github.com/kubeflow/spark-operator/commit/f63956881da11d5bd3bebe7b3d914e124d4130e1)) but not in any tagged release. Last release was v2.5.2 (July 31, 2026).

Kueue (v0.19.x) vendors spark-operator v2.5.2 and inherits this bug. All users of Kueue's `SparkApplicationIntegration` must enforce lowercase memory values as a workaround. Kueue cannot bump the vendor until a tagged release contains the fix.

Spark itself accepts both `"8g"` and `"8G"`, so users don't expect case to matter — this silently breaks admission.

### Describe the solution you would like

Cut a patch release (v2.5.3) or minor release (v2.6.0) that includes commit [f639568](https://github.com/kubeflow/spark-operator/commit/f63956881da11d5bd3bebe7b3d914e124d4130e1) and other fixes merged since v2.5.2.

Happy to help prepare the release PR (changelog, version bumps) if needed.

### Describe alternatives you have considered

1. **Middleware workaround** — currently converting all memory values to lowercase before submitting SparkApplications. Works but fragile and shouldn't be permanent.
2. **Kueue-side patch** — ask Kueue to vendor from master or copy the fixed function. Messy since go modules require tagged versions for `v2/` modules.
3. **Fork** — build a custom spark-operator image with the fix cherry-picked. Adds maintenance burden.

All are workarounds. A tagged release is the clean solution that unblocks the entire Kueue + Spark ecosystem.

### Additional context

- Kueue tracking issue: _(link to companion Kueue issue once filed)_
- Kueue's `go.mod` pins `github.com/kubeflow/spark-operator/v2 v2.5.2`
- Active PRs continue to merge (e.g. #3152 approved Sep 14) — repo is healthy, just needs a release cut
- v2.5.0 → v2.5.1 → v2.5.2 released within months in 2026, so cadence supports a v2.5.3

cc @vara-bonthu @ChenYi015 @jacobsalway

### Love this feature?

Give it a 👍 We prioritize the features with most 👍

Contributor guide

Open the contributing guide

Research direction

Start by reviewing commit f639568 and the release changes since v2.5.2, including the referenced memory conversion function and version or changelog updates. Confirm the fix is included, prepare the requested release PR, and verify that a tagged v2.5.3 or v2.6.0 contains it for Kueue's v2 module dependency.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes
Domain
release
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.