spark_on_k8s.sql¶
Implementation reference. These symbols describe how the project works; their presence here does not make them supported application imports. Use the documented entry points and support policy.
SQL_APP_PATH = f'{SQL_MOUNT_PATH}/spark_sql.py'
module-attribute
¶
SQL_ARGUMENTS = [f'{SQL_MOUNT_PATH}/queries.json']
module-attribute
¶
SQL_MOUNT_PATH = '/configmap'
module-attribute
¶
prepare_sql_configmap(sql, *, allow_empty=False, source_name='<inline>')
¶
Prepare SQL statements and the standalone runner for a managed ConfigMap.
Parsing happens on the submitting machine. The Spark image needs only PySpark and the standard library, with no Airflow or spark-on-k8s installation.
Source code in spark_on_k8s/sql/__init__.py
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | |
prepare_sql_options(*, sql=None, sql_file=None, **submit_options)
¶
Return independent submit_app options for SQL, without contacting Kubernetes.
Source code in spark_on_k8s/sql/__init__.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | |
reserves_sql_mount(path, *, template=False)
¶
Return whether a mount would replace or shadow the generated SQL ConfigMap.
Exact template mounts are replaced by the generated mount, so only their descendants conflict.
Source code in spark_on_k8s/sql/__init__.py
69 70 71 72 73 74 75 76 | |