Skip to main content

Python wrapper for Spark logical plan capture extension

Project description

spark-logical-plan-capture

Python package for connecting the Spark extension io.github.mt.logicplan.LogicalPlanCaptureExtension via spark-submit or from PySpark code.

Install

pip install spark-logical-plan-capture

Usage in PySpark

from pyspark.sql import SparkSession
from spark_logical_plan_capture import get_spark_conf, get_jar_path

conf = get_spark_conf()

spark = (
    SparkSession.builder
    .config("spark.sql.extensions", conf["spark.sql.extensions"])
    .config("spark.jars", conf["spark.jars"])
    .getOrCreate()
)

Usage with spark-submit

spark-submit \
  --conf "spark.sql.extensions=io.github.mt.logicplan.LogicalPlanCaptureExtension" \
  --jars "$(python -c 'from spark_logical_plan_capture import get_jar_path; print(get_jar_path())')" \
  your_job.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spark_logical_plan_capture-0.1.0.tar.gz (13.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

spark_logical_plan_capture-0.1.0-py3-none-any.whl (13.2 kB view details)

Uploaded Python 3

File details

Details for the file spark_logical_plan_capture-0.1.0.tar.gz.

File metadata

File hashes

Hashes for spark_logical_plan_capture-0.1.0.tar.gz
Algorithm Hash digest
SHA256 913862d1740ee82c3643ef8debee0252072edca07acef47326bb6540334d0d78
MD5 79f19e9c877ec19c656aa0db0a9d61f8
BLAKE2b-256 a4d4d0b7141c3e70b346e8c74be75b9b5d552dde0e3c97d552b4b7a062b1b17a

See more details on using hashes here.

File details

Details for the file spark_logical_plan_capture-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for spark_logical_plan_capture-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 67b92e847c18aa45228cf4201507651232a2fe50aa56f7de6c01a1a3e89de090
MD5 c289821fce91bb094c432951f0f938fc
BLAKE2b-256 970296a500f8dcbd92bd3793f8d1b389c21b61028159247293689c0dfff0b776

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page