Skip to content

Commit 5d176aa

Browse files
committed
remove iceberg test script
1 parent 433a2ea commit 5d176aa

File tree

2 files changed

+4
-54
lines changed

2 files changed

+4
-54
lines changed

docs/modules/spark-k8s/pages/usage-guide/spark-connect.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,7 @@ The following features are not supported by the Stackable Spark operator yet
5353
* Authorization and authentication. Currently, anyone with access to the Spark Connect service can run jobs.
5454
* Volumes and volume mounts can be added only with pod overrides.
5555
* Job dependencies must be provisioned as custom images or via `--packages` or `--jars` arguments.
56+
57+
== Known Issues
58+
59+
* Dynamically provisioning the iceberg runtime leads to "iceberg.SparkWrite$WriterFactory" ClassNotfoundException when attempting to use it from clients.
Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,3 @@
1-
---
2-
apiVersion: v1
3-
kind: ConfigMap
4-
metadata:
5-
name: simple-connect-app
6-
labels:
7-
stackable.tech/vendor: Stackable
8-
data:
9-
simple-connect-app.py: |
10-
import sys
11-
12-
from pyspark.sql import SparkSession
13-
from pyspark.sql.types import *
14-
15-
remote = sys.argv[1]
16-
spark = (SparkSession.builder
17-
.remote(remote)
18-
.appName("simple-connect-app")
19-
.getOrCreate())
20-
21-
schema = StructType([
22-
StructField("id", LongType(), True),
23-
StructField("data", StringType(), True)
24-
])
25-
26-
27-
# create table
28-
df = spark.createDataFrame([], schema)
29-
df.writeTo("local.db.table").create()
30-
31-
# append to table
32-
data = [
33-
(1,"one"),
34-
(2,"two"),
35-
(3,"three"),
36-
(4,"four")
37-
]
38-
39-
df = spark.createDataFrame(data, schema)
40-
df.writeTo("local.db.table").append()
41-
421
---
432
apiVersion: batch/v1
443
kind: Job
@@ -51,10 +10,6 @@ spec:
5110
spec:
5211
restartPolicy: OnFailure
5312
activeDeadlineSeconds: 100
54-
volumes:
55-
- name: script
56-
configMap:
57-
name: simple-connect-app
5813
containers:
5914
- name: simple-connect-app
6015
{% if test_scenario['values']['spark-connect-client'].find(",") > 0 %}
@@ -63,12 +18,6 @@ spec:
6318
image: oci.stackable.tech/sdp/spark-connect-client:{{ test_scenario['values']['spark-connect-client'] }}-stackable0.0.0-dev
6419
{% endif %}
6520
imagePullPolicy: IfNotPresent
66-
#
67-
# TODO: cannot use the PySpark job from the ConfigMap because it breaks
68-
# with a "iceberg.SparkWrite$WriterFactory" ClassNotfoundException.
69-
# Use the app bundled within spark-connect-client instead
70-
# "/app/simple-connect-app.py",
71-
#
7221
command:
7322
[
7423
"/usr/bin/python",
@@ -82,6 +31,3 @@ spec:
8231
requests:
8332
cpu: 200m
8433
memory: 128Mi
85-
volumeMounts:
86-
- name: script
87-
mountPath: /app

0 commit comments

Comments
 (0)