go/ directory - github.com/apache/beam/sdks/v2/go - Go Packages

Path Synopsis

beamctl command

beamctl is a command line client for the Apache Beam portability services.

beamctl is a command line client for the Apache Beam portability services.

beamctl/cmd

Package cmd contains the commands for beamctl.

Package cmd contains the commands for beamctl.

prism command

prism is a stand alone local Beam Runner.

prism is a stand alone local Beam Runner.

specialize command

specialize is a low-level tool to generate type-specialized code.

specialize is a low-level tool to generate type-specialized code.

starcgen command

starcgen is a tool to generate specialized type assertion shims to be used in Apache Beam Go SDK pipelines instead of the default reflection shim.

starcgen is a tool to generate specialized type assertion shims to be used in Apache Beam Go SDK pipelines instead of the default reflection shim.

symtab command

Package verifies that functions sym2addr and addr2sym work correctly.

Package verifies that functions sym2addr and addr2sym work correctly.

pool

Package pool facilitates a external worker service, as an alternate mode for the standard Beam container.

Package pool facilitates a external worker service, as an alternate mode for the standard Beam container.

tools

Package tools contains utilities for Beam bootloader containers, such as for obtaining runtime provision information -- such as pipeline options.

Package tools contains utilities for Beam bootloader containers, such as for obtaining runtime provision information -- such as pipeline options.

cookbook/tornadoes command

tornadoes is an example that reads the public samples of weather data from BigQuery, counts the number of tornadoes that occur in each month, and writes the results to BigQuery.

tornadoes is an example that reads the public samples of weather data from BigQuery, counts the number of tornadoes that occur in each month, and writes the results to BigQuery.

debugging_wordcount command

debugging_wordcount is an example that verifies word counts in Shakespeare and includes Beam best practices.

debugging_wordcount is an example that verifies word counts in Shakespeare and includes Beam best practices.

fhirio/import command

import is a pipeline example using the fhirio connector to bulk import FHIR resources from GCS into a given FHIR store.

import is a pipeline example using the fhirio connector to bulk import FHIR resources from GCS into a given FHIR store.

fhirio/read_write_pubsub command

read_write_pubsub is a pipeline example using the fhirio connector to read FHIR resources from GCS, write them to a GCP FHIR store, and, if a PubSub topic is provided, read the written resources from the FHIR store and log them based on the PubSub notifications about store updates.

read_write_pubsub is a pipeline example using the fhirio connector to read FHIR resources from GCS, write them to a GCP FHIR store, and, if a PubSub topic is provided, read the written resources from the FHIR store and log them based on the PubSub notifications about store updates.

forest command

forest is an example that shows that pipeline construction is normal Go code -- the pipeline "forest" is created recursively and uses a global variable -- and that a pipeline may contain non-connected parts.

forest is an example that shows that pipeline construction is normal Go code -- the pipeline "forest" is created recursively and uses a global variable -- and that a pipeline may contain non-connected parts.

kafka command

taxi is an example using a cross-language Kafka pipeline to write and read to Kafka.

taxi is an example using a cross-language Kafka pipeline to write and read to Kafka.

large_wordcount command

large_wordcount is an example that demonstrates a more complex version of a wordcount pipeline.

large_wordcount is an example that demonstrates a more complex version of a wordcount pipeline.

minimal_wordcount command

minimal_wordcount is an example that counts words in King Lear, by William Shakespeare.

minimal_wordcount is an example that counts words in King Lear, by William Shakespeare.

multiout command

multiout is a wordcount variation that uses a multi-outout DoFn and writes 2 output files.

multiout is a wordcount variation that uses a multi-outout DoFn and writes 2 output files.

native_wordcap command

native_wordcap is a toy streaming pipeline that uses PubSub.

native_wordcap is a toy streaming pipeline that uses PubSub. Package nativepubsubio contains a Golang implementation of streaming reads and writes to PubSub.

readavro command

readavro is a simple Avro read/write Example This example uses a 500 Byte sample avro file [twitter.avro] download here: https://s3-eu-west-1.amazonaws.com/daidokoro-dev/apache/twitter.avro

readavro is a simple Avro read/write Example This example uses a 500 Byte sample avro file [twitter.avro] download here: https://s3-eu-west-1.amazonaws.com/daidokoro-dev/apache/twitter.avro

slowly_updating_side_input command

slowly_updating_side_input is an example pipeline demonstrating the pattern described at https://beam.apache.org/documentation/patterns/side-inputs/.

slowly_updating_side_input is an example pipeline demonstrating the pattern described at https://beam.apache.org/documentation/patterns/side-inputs/.

snippets

Package snippets contains code used in the Beam Programming Guide as examples for the Apache Beam Go SDK.

Package snippets contains code used in the Beam Programming Guide as examples for the Apache Beam Go SDK.

streaming_wordcap command

streaming_wordcap is a toy streaming pipeline that uses PubSub.

streaming_wordcap is a toy streaming pipeline that uses PubSub.

stringsplit command

An example of using a Splittable DoFn in the Go SDK with a portable runner.

An example of using a Splittable DoFn in the Go SDK with a portable runner.

timer_wordcap command

timer_wordcap is a toy streaming pipeline that demonstrates the use of State and Timers.

timer_wordcap is a toy streaming pipeline that demonstrates the use of State and Timers.

wasm command

wasm is a simple example that loads and executes a wasm file function.

wasm is a simple example that loads and executes a wasm file function.

windowed_wordcount command

windowed_wordcount counts words in text, and can run over either unbounded or bounded input collections.

windowed_wordcount counts words in text, and can run over either unbounded or bounded input collections.

wordcount command

wordcount is an example that counts words in Shakespeare and demonstrates Beam best practices.

wordcount is an example that counts words in Shakespeare and demonstrates Beam best practices.

xlang

Package xlang contains functionality for testing cross-language transforms.

Package xlang contains functionality for testing cross-language transforms.

xlang/bigquery command

Wordcount is an example using cross-language BigQuery transforms to read and write to BigQuery.

Wordcount is an example using cross-language BigQuery transforms to read and write to BigQuery.

xlang/cogroup_by command

cogroup_by exemplifies using a cross-language cogroup by key transform from a test expansion service.

cogroup_by exemplifies using a cross-language cogroup by key transform from a test expansion service.

xlang/combine command

combine exemplifies using a cross-language combine per key transform from a test expansion service.

combine exemplifies using a cross-language combine per key transform from a test expansion service.

xlang/combine_globally command

combine_globally exemplifies using a cross-language combine global transform from a test expansion service.

combine_globally exemplifies using a cross-language combine global transform from a test expansion service.

xlang/group_by command

group_by exemplifies using a cross-language group by key transform from a test expansion service.

group_by exemplifies using a cross-language group by key transform from a test expansion service.

xlang/multi_input_output command

multi exemplifies using a cross-language transform with multiple inputs and outputs from a test expansion service.

multi exemplifies using a cross-language transform with multiple inputs and outputs from a test expansion service.

xlang/partition command

partition exemplifies using a cross-language partition transform from a test expansion service.

partition exemplifies using a cross-language partition transform from a test expansion service.

xlang/sql command

Prerequisites to run sql: –> [Required] Job needs to be submitted to a portable runner (--runner=universal) –> [Required] Endpoint of job service needs to be passed (--endpoint=<ip:port>) –> [Required] Endpoint of expansion service needs to be passed (--expansion_addr=<ip:port>) –> [Optional] Environment type can be LOOPBACK.

Prerequisites to run sql: –> [Required] Job needs to be submitted to a portable runner (--runner=universal) –> [Required] Endpoint of job service needs to be passed (--endpoint=<ip:port>) –> [Required] Endpoint of expansion service needs to be passed (--expansion_addr=<ip:port>) –> [Optional] Environment type can be LOOPBACK.

xlang/wordcount command

wordcount exemplifies using a cross-language Count transform from a test expansion service to count words.

wordcount exemplifies using a cross-language Count transform from a test expansion service to count words.

yatzy command

yatzy is an implementation of https://en.wikipedia.org/wiki/Yatzy that shows that pipeline construction is normal Go code.

yatzy is an implementation of https://en.wikipedia.org/wiki/Yatzy that shows that pipeline construction is normal Go code.

beam

Package beam is an implementation of the Apache Beam (https://beam.apache.org) programming model in Go.

Package beam is an implementation of the Apache Beam (https://beam.apache.org) programming model in Go.

beam/artifact

Package artifact contains utilities for staging and retrieving artifacts.

Package artifact contains utilities for staging and retrieving artifacts. Package gcsproxy contains artifact staging and retrieval servers backed by GCS.

beam/core

Package core contains constants and other static data related to the SDK, such as the SDK Name and version.

Package core contains constants and other static data related to the SDK, such as the SDK Name and version.

beam/core/funcx

Package funcx contains functions and types used to perform type analysis of Beam functions.

Package funcx contains functions and types used to perform type analysis of Beam functions.

beam/core/graph

Package graph is the internal representation of the Beam execution plan.

Package graph is the internal representation of the Beam execution plan. Package coder contains coder representation and utilities. Package testutil contains helpers to test and validate custom Beam Schema coders. Package mtime contains a millisecond representation of time. Package window contains window representation, windowing strategies and utilities. Package trigger helps construct aggregation triggers with beam.WindowInto.

beam/core/metrics

Package metrics implements the Beam metrics API, described at http://s.apache.org/beam-metrics-api

Package metrics implements the Beam metrics API, described at http://s.apache.org/beam-metrics-api

beam/core/runtime

Package runtime contains runtime hooks and utilities for pipeline options and type registration.

Package runtime contains runtime hooks and utilities for pipeline options and type registration. Package coderx contains coders for primitive types that aren't included in the beam model.

beam/core/runtime/contextreg

Package contextreg contains the global registrations of functions for extracting ptransform annotations or environment resource hints from context.Context attached to scopes.

Package contextreg contains the global registrations of functions for extracting ptransform annotations or environment resource hints from context.Context attached to scopes. Package exec contains runtime plan representation and execution. Package optimized contains type-specialized shims for faster execution. Package genx is a convenience package to better support the code generator.

beam/core/runtime/graphx

Package graphx provides facilities to help with the serialization of pipelines into a serializable graph structure suitable for the worker.

Package graphx provides facilities to help with the serialization of pipelines into a serializable graph structure suitable for the worker. Package schema contains utility functions for relating Go types and Beam Schemas. Package harness implements the SDK side of the Beam FnAPI. Package init contains the harness initialization code defined by the FnAPI. Package statecache implements the state caching feature described by the Beam Fn API Package pipelinex contains utilities for manipulating Beam proto pipelines.

beam/core/runtime/xlangx

Package xlangx contains various low-level utilities needed for adding cross-language transforms to the pipeline.

Package xlangx contains various low-level utilities needed for adding cross-language transforms to the pipeline. Package expansionx contains utilities for starting expansion services for cross-language transforms.

beam/core/sdf

Package contains interfaces used specifically for splittable DoFns.

Package contains interfaces used specifically for splittable DoFns.

beam/core/state

Package state contains structs for reading and manipulating pipeline state.

Package state contains structs for reading and manipulating pipeline state. Package timers contains structs for setting pipeline timers.

beam/core/typex

Package typex contains full type representation for PCollections and DoFns, and utilities for type checking.

Package typex contains full type representation for PCollections and DoFns, and utilities for type checking. Package dot produces DOT graphs from Beam graph representations. Package hooks allows runners to tailor execution of the worker harness. Package ioutilx contains additional io utilities. Package jsonx contains utilities for working with JSON encoded data. Package protox contains utilities for working with protobufs. Package reflectx contains a set of reflection utilities and well-known types. Package symtab allows reading low-level symbol information from the symbol table.

beam/internal/errors

Package errors contains functionality for creating and wrapping errors with improved formatting compared to the standard Go error functionality.

Package errors contains functionality for creating and wrapping errors with improved formatting compared to the standard Go error functionality.

beam/io/avroio

Package avroio contains transforms for reading and writing avro files.

Package avroio contains transforms for reading and writing avro files.

beam/io/bigqueryio

Package bigqueryio provides transformations and utilities to interact with Google BigQuery.

Package bigqueryio provides transformations and utilities to interact with Google BigQuery.

beam/io/bigtableio

Package bigtableio provides transformations and utilities to interact with Google Bigtable.

Package bigtableio provides transformations and utilities to interact with Google Bigtable.

beam/io/databaseio

Package databaseio provides transformations and utilities to interact with generic database database/sql API.

Package databaseio provides transformations and utilities to interact with generic database database/sql API.

beam/io/datastoreio

Package datastoreio provides transformations and utilities to interact with Google Datastore.

Package datastoreio provides transformations and utilities to interact with Google Datastore.

beam/io/fhirio

Package fhirio provides an API for reading and writing resources to Google Cloud Healthcare Fhir stores.

Package fhirio provides an API for reading and writing resources to Google Cloud Healthcare Fhir stores.

beam/io/fileio

Package fileio provides transforms for matching and reading files.

Package fileio provides transforms for matching and reading files. Package filesystem contains an extensible file system abstraction.

beam/io/filesystem/gcs

Package gcs contains a Google Cloud Storage (GCS) implementation of the Beam file system.

Package gcs contains a Google Cloud Storage (GCS) implementation of the Beam file system. Package local contains a local file implementation of the Beam file system. Package memfs contains a in-memory Beam filesystem. Package s3 contains an AWS S3 implementation of the Beam file system.

beam/io/mongodbio

Package mongodbio contains transforms for reading from and writing to MongoDB.

Package mongodbio contains transforms for reading from and writing to MongoDB.

beam/io/natsio

Package natsio contains transforms for interacting with NATS.

Package natsio contains transforms for interacting with NATS.

beam/io/parquetio

Package parquetio contains transforms for reading and writing parquet files

Package parquetio contains transforms for reading and writing parquet files

beam/io/pubsubio

Package pubsubio provides access to Pub/Sub on Dataflow streaming.

Package pubsubio provides access to Pub/Sub on Dataflow streaming. Package offsetrange defines a restriction and restriction tracker for offset ranges.

beam/io/spannerio

Package spannerio provides an API for reading and writing resouces to Google Spanner datastores.

Package spannerio provides an API for reading and writing resouces to Google Spanner datastores.

beam/io/synthetic

Package synthetic contains transforms for creating synthetic pipelines.

Package synthetic contains transforms for creating synthetic pipelines.

beam/io/textio

Package textio contains transforms for reading and writing text files.

Package textio contains transforms for reading and writing text files.

beam/io/xlang/bigqueryio

Package bigqueryio contains cross-language functionality for using Google Cloud BigQuery (https://cloud.google.com/bigquery).

Package bigqueryio contains cross-language functionality for using Google Cloud BigQuery (https://cloud.google.com/bigquery).

beam/io/xlang/bigtableio

Package bigtableio contains cross-language functionality for using Google Cloud BigQuery (https://cloud.google.com/bigquery).

Package bigtableio contains cross-language functionality for using Google Cloud BigQuery (https://cloud.google.com/bigquery).

beam/io/xlang/debeziumio

Package debeziumio contains cross-language functionality for using Debezium (http://kafka.apache.org/).

Package debeziumio contains cross-language functionality for using Debezium (http://kafka.apache.org/).

beam/io/xlang/jdbcio

Package jdbcio contains cross-language functionality for reading and writing data to JDBC.

Package jdbcio contains cross-language functionality for reading and writing data to JDBC.

beam/io/xlang/kafkaio

Package kafkaio contains cross-language functionality for using Apache Kafka (http://kafka.apache.org/).

Package kafkaio contains cross-language functionality for using Apache Kafka (http://kafka.apache.org/).

beam/io/xlang/schemaio

Package schemaio contains utilities for constructing cross-language IO wrappers meant to interface with the Java SDK's Schema IOs.

Package schemaio contains utilities for constructing cross-language IO wrappers meant to interface with the Java SDK's Schema IOs.

beam/log

Package log contains a re-targetable context-aware logging system.

Package log contains a re-targetable context-aware logging system.

beam/model

Package model contains the portable Beam model contracts.

Package model contains the portable Beam model contracts. Package gcpopts contains shared options for Google Cloud Platform. Package jobopts contains shared options for job submission.

beam/options/resource

Package resource supports Beam resource hints to specify scoped hints or annotations to pipelines.

Package resource supports Beam resource hints to specify scoped hints or annotations to pipelines.

beam/provision

Package provision contains utilities for obtaining runtime provision, information -- such as pipeline options.

Package provision contains utilities for obtaining runtime provision, information -- such as pipeline options.

beam/register

Package register contains functions for registering and optimizing your DoFn.

Package register contains functions for registering and optimizing your DoFn.

beam/runners

Package runners defines the common "--runner" flag.

Package runners defines the common "--runner" flag.

beam/runners/dataflow

Package dataflow contains the Dataflow runner for submitting pipelines to Google Cloud Dataflow.

Package dataflow contains the Dataflow runner for submitting pipelines to Google Cloud Dataflow. Package dataflowlib translates a Beam pipeline model to the Dataflow API job model, for submission to Google Cloud Dataflow.

beam/runners/direct

Package direct contains the direct runner for running single-bundle pipelines in the current process.

Package direct contains the direct runner for running single-bundle pipelines in the current process.

beam/runners/dot

Package dot is a Beam runner that "runs" a pipeline by producing a DOT graph of the execution plan.

Package dot is a Beam runner that "runs" a pipeline by producing a DOT graph of the execution plan. Package flink contains the Flink runner.

beam/runners/prism

Package prism contains a local runner for running pipelines in the current process.

Package prism contains a local runner for running pipelines in the current process.

beam/runners/prism/internal

Package internal is where the less separable parts of the runner are put together in order to execute pipelines, and validate that beam features are implemented, and configured appropriately for the variant a pipeline is using.

Package internal is where the less separable parts of the runner are put together in order to execute pipelines, and validate that beam features are implemented, and configured appropriately for the variant a pipeline is using. Package config defines and handles the parsing and provision of configurations for the runner. Package engine handles the operational components of a runner, to track elements, watermarks, timers, triggers etc Package jobservices handles services necessary WRT handling jobs from SDKs. Package urns handles extracting urns from all the protos. Package web serves a web UI for Prism.

beam/runners/prism/internal/worker

Package worker handles interactions with SDK side workers, representing the worker services, communicating with those services, and SDK environments.

Package worker handles interactions with SDK side workers, representing the worker services, communicating with those services, and SDK environments. Package samza contains the Samza runner. Package spark contains the Spark runner.

beam/runners/universal

Package universal contains a general-purpose runner that can submit jobs to any portable Beam runner.

Package universal contains a general-purpose runner that can submit jobs to any portable Beam runner. Package extworker provides an external worker service and related utilities. Package runnerlib contains utilities for submitting Go pipelines to a Beam model runner.

beam/runners/vet

Package vet is a Beam runner that "runs" a pipeline by producing generated code to avoid symbol table lookups and reflection in pipeline execution.

Package vet is a Beam runner that "runs" a pipeline by producing generated code to avoid symbol table lookups and reflection in pipeline execution. Package testpipeline exports small test pipelines for testing the vet runner. Package passert contains verification transformations for testing pipelines. Package ptest contains utilities for pipeline unit testing.

beam/testing/teststream

Package teststream contains code configuring the TestStream primitive for use in testing code that is meant to be run on streaming data sources.

Package teststream contains code configuring the TestStream primitive for use in testing code that is meant to be run on streaming data sources.

beam/transforms/filter

Package filter contains transformations for removing pipeline elements based on various conditions.

Package filter contains transformations for removing pipeline elements based on various conditions. Package periodic contains transformations for generating periodic sequences.

beam/transforms/sql

Package sql contains SQL transform APIs, allowing SQL queries to be used in Beam Go pipelines.

Package sql contains SQL transform APIs, allowing SQL queries to be used in Beam Go pipelines.

beam/transforms/sql/sqlx

Package sqlx contains "internal" SQL transform interfaces that are needed by the SQL expansion providers.

Package sqlx contains "internal" SQL transform interfaces that are needed by the SQL expansion providers. Package stats contains transforms for statistical processing.

beam/transforms/top

Package top contains transformations for finding the smallest (or largest) N elements based on arbitrary orderings.

Package top contains transformations for finding the smallest (or largest) N elements based on arbitrary orderings. Package xlang contains cross-language transforms. Package dataframe is a wrapper for DataframeTransform defined in Apache Beam Python SDK. Package inference has the cross language implementation of RunInference API implemented in Python SDK. Package python contains data structures required for python external transforms in a multilanguage pipeline. Package schema has the cross language implementation for calling schema transforms in other language SDKs.

beam/util/diagnostics

Package diagnostics is a beam internal package that contains code for writing and uploading diagnostic info (e.g.

Package diagnostics is a beam internal package that contains code for writing and uploading diagnostic info (e.g. Package errorx contains utilities for handling errors.

beam/util/execx

Package execx contains wrappers and utilities for the exec package.

Package execx contains wrappers and utilities for the exec package.

beam/util/fsx

Package fsx contains utilities for working with filesystems.

Package fsx contains utilities for working with filesystems.

beam/util/gcsx

Package gcsx contains utilities for working with Google Cloud Storage (GCS).

Package gcsx contains utilities for working with Google Cloud Storage (GCS). Package grpcx contains utilities for working with gRPC.

beam/util/harnessopts

Package harnessopts defines user-facing entrypoints into Beam hooks affecting the SDK harness.

Package harnessopts defines user-facing entrypoints into Beam hooks affecting the SDK harness. Package pubsubx contains utilities for working with Google PubSub.

beam/util/shimx

Package shimx specifies the templates for generating type assertion shims for Apache Beam Go SDK pipelines.

Package shimx specifies the templates for generating type assertion shims for Apache Beam Go SDK pipelines.

beam/util/starcgenx

Package starcgenx is a Static Analysis Type Assertion shim and Registration Code Generator which provides an extractor to extract types from a package, in order to generate appropriate shims for a package so code can be generated for it.

Package starcgenx is a Static Analysis Type Assertion shim and Registration Code Generator which provides an extractor to extract types from a package, in order to generate appropriate shims for a package so code can be generated for it. Package structx provides utilities for working with structs.

beam/util/syscallx

Package syscallx provides system call utilities that attempt to hide platform differences.

Package syscallx provides system call utilities that attempt to hide platform differences.

beam/x/beamx

Package beamx is a convenience package for beam.

Package beamx is a convenience package for beam.

beam/x/debug

Package debug contains pipeline components that may help in debugging pipeline issues.

Package debug contains pipeline components that may help in debugging pipeline issues.

beam/x/hooks/perf

Package perf is to add performance measuring hooks to a runner, such as cpu, heap, or trace profiles.

Package perf is to add performance measuring hooks to a runner, such as cpu, heap, or trace profiles.

integration

Package integration provides functionality that needs to be shared between all integration tests.

Package integration provides functionality that needs to be shared between all integration tests. Package containers contains utilities for running test containers in integration tests. Package jars contains functionality for running jars for integration tests. Package ports contains utilities for handling ports needed for integration tests. Package bigquery contains integration tests for cross-language BigQuery IO transforms. Package bigtable contains integration tests for cross-language Bigtable IO transforms. Package debezium contains integration tests for cross-language Debezium IO transforms. Package jdbc contains integration tests for cross-language JDBC IO transforms. Package kafka contains integration tests for cross-language Kafka IO transforms. Package primitives contains integration tests for primitives in beam. Package synthetic contains pipelines for testing synthetic steps and sources. Package wordcount contains transforms for wordcount.

integration/xlang

Package xlang contains integration tests for cross-language transforms.

Package xlang contains integration tests for cross-language transforms.

regression

Package regression contains pipeline regression tests.

Package regression contains pipeline regression tests.

regression/coders/fromyaml command

fromyaml generates a resource file from the standard_coders.yaml file for use in these coder regression tests.

fromyaml generates a resource file from the standard_coders.yaml file for use in these coder regression tests.