Commit 029816d
refactor: extract dereference/validate pipeline from reconcile (#687)
* refactor(app): scaffold dereference and validate submodules
Empty modules with snafu Error stubs. Wires up `mod` declarations so
later commits can fill them in without further plumbing changes.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(app): add dereference module with template/S3/logdir fetch
Defines DereferencedSparkApplication and an async dereference() function
that consolidates template merging, S3 connection resolution, the early
S3 TLS sanity check, and log directory resolution. Not yet wired into
reconcile().
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(app): add validate module with image + product-config validation
Defines ValidatedSparkApplication and a sync validate() function that
resolves the product image (moved from reconcile()) and runs
validated_role_config. Not yet wired into reconcile().
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(app): wire reconcile through dereference + validate
reconcile() now delegates template merging, S3 resolution, TLS sanity
checking, log directory resolution, image resolution, and product-config
validation to the new submodules. The function body shrinks by ~70 lines
and the controller's Error enum loses six variants now living in the
submodules.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* chore(history): rename history_controller.rs to controller.rs
Aligns history with connect (which already uses controller.rs) ahead of
splitting it into a controller/ submodule folder.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(history): scaffold dereference and validate submodules
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(history): add dereference module with log directory fetch
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(history): add validate module with image + product-config validation
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(history): wire reconcile through dereference + validate
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(connect): scaffold dereference and validate submodules
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(connect): add dereference module with S3 connection fetch
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(connect): add validate module with image + role config resolution
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* refactor(connect): wire reconcile through dereference + validate
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* style: apply cargo fmt to wired controllers
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fix: correct error message
* fix: remove obsolete errors
* fix: regenerate crate hashes
* test(spark-connect): trim 10-assert to bare CR Available wait
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* test(smoke): add SparkHistoryServer resource snapshot assert
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* test(smoke): add SparkHistoryServer ConfigMap data snapshot
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* test(smoke): add SparkApplication resource snapshot assert
Drift-detect the 3 ConfigMaps, ServiceAccount, and RoleBinding that
persist after SparkApplication/spark-pi-s3-1 reaches phase: Succeeded.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* test(smoke): add SparkApplication ConfigMap data snapshot
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* test(spark-connect): add SparkConnectServer resource snapshot assert
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* test(spark-connect): add SparkConnectServer ConfigMap data snapshot
Snapshot the full `.data` of spark-connect-server and spark-connect-executor
ConfigMaps. Uses `.yaml.j2` because spark-defaults.conf and template.yaml differ
between s3-use-tls dimensions (https vs http, extraJavaOptions, initContainers,
minio-tls-ca volume). The spark.kubernetes.namespace line is substituted at
runtime via sed/__NAMESPACE__ to survive randomised kuttl namespaces.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* docs: adapt changelog
* fix(smoke): improve diff output
* fix(tests): fix test asserts for vector aggregator
* fix(connect): add vector aggregator fixes
* move TLS check into the validate step
* thread dereferenced fields through the validated structs
* fix: correct error handling for no-tls s3 bucket
* fix: remove obsolete tls validation check
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Andrew Kenworthy <andrew.kenworthy@stackable.tech>1 parent 9f44126 commit 029816d
22 files changed
Lines changed: 4752 additions & 282 deletions
File tree
- rust/operator-binary/src
- connect
- controller
- crd
- history
- controller
- spark_k8s_controller
- tests/templates/kuttl
- smoke
- spark-connect
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
23 | 22 | | |
24 | 23 | | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
31 | 32 | | |
32 | 33 | | |
33 | 34 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | | - | |
| 24 | + | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
28 | 31 | | |
29 | 32 | | |
30 | 33 | | |
| |||
124 | 127 | | |
125 | 128 | | |
126 | 129 | | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | 130 | | |
133 | 131 | | |
134 | 132 | | |
| |||
138 | 136 | | |
139 | 137 | | |
140 | 138 | | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | 139 | | |
150 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
151 | 147 | | |
152 | 148 | | |
153 | 149 | | |
| |||
170 | 166 | | |
171 | 167 | | |
172 | 168 | | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | 169 | | |
178 | 170 | | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
179 | 185 | | |
180 | 186 | | |
181 | 187 | | |
| |||
186 | 192 | | |
187 | 193 | | |
188 | 194 | | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | | - | |
199 | | - | |
200 | | - | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | 195 | | |
207 | 196 | | |
208 | 197 | | |
| |||
251 | 240 | | |
252 | 241 | | |
253 | 242 | | |
254 | | - | |
| 243 | + | |
255 | 244 | | |
256 | 245 | | |
257 | | - | |
| 246 | + | |
258 | 247 | | |
259 | 248 | | |
260 | | - | |
| 249 | + | |
261 | 250 | | |
262 | 251 | | |
263 | 252 | | |
264 | 253 | | |
265 | 254 | | |
266 | 255 | | |
267 | 256 | | |
268 | | - | |
| 257 | + | |
269 | 258 | | |
270 | 259 | | |
271 | 260 | | |
| |||
280 | 269 | | |
281 | 270 | | |
282 | 271 | | |
283 | | - | |
284 | | - | |
| 272 | + | |
| 273 | + | |
285 | 274 | | |
286 | | - | |
| 275 | + | |
287 | 276 | | |
288 | 277 | | |
289 | 278 | | |
| |||
293 | 282 | | |
294 | 283 | | |
295 | 284 | | |
296 | | - | |
297 | | - | |
| 285 | + | |
| 286 | + | |
298 | 287 | | |
299 | 288 | | |
300 | 289 | | |
| |||
310 | 299 | | |
311 | 300 | | |
312 | 301 | | |
313 | | - | |
| 302 | + | |
314 | 303 | | |
315 | 304 | | |
316 | 305 | | |
| |||
323 | 312 | | |
324 | 313 | | |
325 | 314 | | |
326 | | - | |
327 | | - | |
| 315 | + | |
| 316 | + | |
328 | 317 | | |
329 | 318 | | |
330 | 319 | | |
331 | 320 | | |
332 | | - | |
| 321 | + | |
333 | 322 | | |
334 | 323 | | |
335 | 324 | | |
| |||
Lines changed: 33 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
0 commit comments