Skip to main content

Databricks plugin for flyte

Project description

Databricks Plugin for Flyte

This plugin provides Databricks integration for Flyte, enabling you to run Spark jobs on Databricks as Flyte tasks.

Installation

pip install flyteplugins-databricks

Usage

from flyteplugins.databricks import Databricks, DatabricksConnector

@task(task_config=Databricks(
    databricks_conf={
        "run_name": "flyte databricks plugin",
        "new_cluster": {
            "spark_version": "13.3.x-scala2.12",
            "autoscale": {
                "min_workers": 1,
                "max_workers": 1,
            },
            "node_type_id": "m6i.large",
            "num_workers": 1,
            "aws_attributes": {
                "availability": "SPOT_WITH_FALLBACK",
                "instance_profile_arn": "arn:aws:iam::339713193121:instance-profile/databricks-demo",
                "ebs_volume_type": "GENERAL_PURPOSE_SSD",
                "ebs_volume_count": 1,
                "ebs_volume_size": 100,
                "first_on_demand": 1,
            },
        },
        # "existing_cluster_id": "1113-204018-tb9vr2fm", # use existing cluster id if you want
        "timeout_seconds": 3600,
        "max_retries": 1,
    },
    databricks_instance="mycompany.cloud.databricks.com",
))
def my_spark_task() -> int:
    # Your Spark code here
    return 42

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

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

flyteplugins_databricks-2.2.1-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file flyteplugins_databricks-2.2.1-py3-none-any.whl.

File metadata

File hashes

Hashes for flyteplugins_databricks-2.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 01262346535236cc7602e2d999e6e4a6ab945b4f563668e9b19a3b4cfb8263e5
MD5 830b4250d0703da2e5b9d30f5907e1f3
BLAKE2b-256 6e7490089b7879d701fc32bbe33abb960e6ceb1a9ea4ee075b3ff212ef5d8b7a

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