본문으로 건너뛰기
cccskills
무료GitHub에 공개

runners

Configure and troubleshoot Apache Beam runners, the engines that execute data processing pipelines. Covers local testing, Dataflow, Flink, and Spark, with Java and Python examples, runner validation tests, and guidance on logs and execution settings.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Guides understanding and working with Apache Beam runners (Direct, Dataflow, Flink, Spark, etc.). Use when configuring pipelines for different execution environments or debugging runner-specific issues.

연동 도구Google Cloud
설치 방법 보기

이럴 때 유용합니다

  • Test a Beam pipeline locally
  • Configure pipeline execution on Dataflow
  • Review Flink or Spark execution settings
  • Investigate runner-specific failures

포함된 파일(1)

  • SKILL.md6.0 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Apache Beam Runners

Overview

Runners execute Beam pipelines on distributed processing backends. Each runner translates the portable Beam model to its native execution engine.

Available Runners

RunnerLocationDescription
Directrunners/direct-java/Local execution for testing
Prismrunners/prism/Portable local runner
Dataflowrunners/google-cloud-dataflow-java/Google Cloud Dataflow
Flinkrunners/flink/Apache Flink
Sparkrunners/spark/Apache Spark
Jetrunners/jet/Hazelcast Jet
Twister2runners/twister2/Twister2

Direct Runner

For local development and testing.

Java

PipelineOptions options = PipelineOptionsFactory.create();
options.setRunner(DirectRunner.class);
Pipeline p = Pipeline.create(options);

Python

options = PipelineOptions()
options.view_as(StandardOptions).runner = 'DirectRunner'
p = beam.Pipeline(options=options)

Command Line

--runner=DirectRunner

Dataflow Runner

Prerequisites

  • GCP project with Dataflow API enabled
  • Service account with Dataflow Admin role
  • GCS bucket for staging

Java Usage

DataflowPipelineOptions options = PipelineOptionsFactory.as(DataflowPipelineOptions.class);
options.setRunner(DataflowRunner.class);
options.setProject("my-project");
options.setRegion("us-central1");
options.setTempLocation("gs://my-bucket/temp");

Python Usage

options = PipelineOptions([
    '--runner=DataflowRunner',
    '--project=my-project',
    '--region=us-central1',
    '--temp_location=gs://my-bucket/temp'
])

Runner v2

--experiments=use_runner_v2

Custom SDK Container

--sdkContainerImage=gcr.io/project/beam_java11_sdk:custom

Flink Runner

Embedded Mode

FlinkPipelineOptions options = PipelineOptionsFactory.as(FlinkPipelineOptions.class);
options.setRunner(FlinkRunner.class);
options.setFlinkMaster("[local]");

Cluster Mode

options.setFlinkMaster("host:port");

Portable Mode (Python)

options = PipelineOptions([
    '--runner=FlinkRunner',
    '--flink_master=host:port',
    '--environment_type=LOOPBACK'  # or DOCKER, EXTERNAL
])

Spark Runner

Java

SparkPipelineOptions options = PipelineOptionsFactory.as(SparkPipelineOptions.class);
options.setRunner(SparkRunner.class);
options.setSparkMaster("local[*]");  # or spark://host:port

Python (Portable)

options = PipelineOptions([
    '--runner=SparkRunner',
    '--spark_master_url=local[*]'
])

Testing with Runners

ValidatesRunner Tests

Tests that validate runner correctness:

# Direct Runner
./gradlew :runners:direct-java:validatesRunner

# Flink Runner
./gradlew :runners:flink:1.18:validatesRunner

# Spark Runner
./gradlew :runners:spark:3:validatesRunner

# Dataflow Runner
./gradlew :runners:google-cloud-dataflow-java:validatesRunner

TestPipeline with Runners

@Rule public TestPipeline pipeline = TestPipeline.create();

// Set runner via system property
-DbeamTestPipelineOptions='["--runner=TestDataflowRunner"]'

Portable Runners

Concept

  • SDK-independent execution via Fn API
  • SDK runs in container, communicates via gRPC

Environment Types

  • DOCKER - SDK in Docker container
  • LOOPBACK - SDK in same process (testing)
  • EXTERNAL - SDK at specified address
  • PROCESS - SDK in subprocess

Job Server

Start Flink job server:

./gradlew :runners:flink:1.18:job-server:runShadow

Start Spark job server:

./gradlew :runners:spark:3:job-server:runShadow

Runner-Specific Options

Dataflow

OptionDescription
--projectGCP project
--regionGCP region
--tempLocationGCS temp location
--stagingLocationGCS staging
--numWorkersInitial workers
--maxNumWorkersMax workers
--workerMachineTypeVM type

Flink

OptionDescription
--flinkMasterFlink master address
--parallelismDefault parallelism
--checkpointingIntervalCheckpoint interval

Spark

OptionDescription
--sparkMasterSpark master URL
--sparkConfAdditional Spark config

Building Runner Artifacts

Dataflow Worker Jar

./gradlew :runners:google-cloud-dataflow-java:worker:shadowJar

Flink Job Server

./gradlew :runners:flink:1.18:job-server:shadowJar

Spark Job Server

./gradlew :runners:spark:3:job-server:shadowJar

Debugging

Direct Runner

  • Enable logging: -Dorg.slf4j.simpleLogger.defaultLogLevel=debug
  • Use --targetParallelism=1 for deterministic execution

Dataflow

  • Check Dataflow UI: console.cloud.google.com/dataflow
  • Use --experiments=upload_graph for graph debugging
  • Worker logs in Cloud Logging

Portable Runners

  • Enable debug logging on job server
  • Check SDK harness logs in worker containers

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Guides adding metadata, extra information attached to data elements, to Apache Beam's WindowedValue. Maps the changes needed across serialization, storage, processing, and runner interfaces so new fields remain available during pipeline execution.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Adding trace context or drain flags to WindowedValue
  • Checking metadata preservation through Windmill storage
  • Reviewing propagation through grouping and timers
apache/beam8.7천2026년 10월 19일 업데이트

Learn Apache Beam's core concepts through Java and Python examples. Understand distributed datasets, processing steps, pipeline execution, and time windows, with guidance on aggregation, late data, error handling, and sharing processing steps across languages.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Learn how Pipeline, PCollection, and PTransform fit together
  • Understand grouping, aggregation, merging, and splitting
  • Study time windows, output timing, and late data
apache/beam8.7천2026년 10월 19일 업데이트

ci-cd

무료

Helps investigate and modify Apache Beam's automated build and test workflows in GitHub Actions. Explains workflow types, failure logs, targeted reruns, local reproduction, and the cloud credentials needed for workflows that access GCP.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Investigating failed checks on a pull request
  • Rerunning a specific test workflow
  • Reproducing CI test commands locally
apache/beam8.7천2026년 10월 19일 업데이트

Navigate Apache Beam contributions from finding an issue to submitting a pull request, a proposed code change, and responding to reviews. Covers environment setup, tests, formatting, licensing requirements, and closer evaluation of changes to core components.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Prepare a first Apache Beam contribution
  • Organize a pull request and its related issue
  • Check tests and formatting before submission
apache/beam8.7천2026년 10월 19일 업데이트

Build Apache Beam connectors that read and write external data. This guide covers Java implementation, schema support for structured records, access from Python and Go, Managed API integration, and testing.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Add a connector for an external data system
  • Make a Java connector available to Python and Go
  • Integrate a connector with Beam YAML and the Managed API
apache/beam8.7천2026년 10월 19일 업데이트

Build and test Apache Beam with Gradle, the system that manages its project tasks. Find relevant configuration files, inspect library dependencies, run formatting checks, publish locally, and investigate build failures.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Build or test a specific Apache Beam module
  • Inspect library dependencies and version conflicts
  • Run formatting and pre-commit checks
apache/beam8.7천2026년 10월 19일 업데이트

apache의 스킬 모두 보기

이 스킬의 문제 신고