public sealed class FlexTemplateRuntimeEnvironment : IMessage<FlexTemplateRuntimeEnvironment>, IEquatable<FlexTemplateRuntimeEnvironment>, IDeepCloneable<FlexTemplateRuntimeEnvironment>, IBufferMessage, IMessage
Reference documentation and code samples for the Dataflow v1beta3 API class FlexTemplateRuntimeEnvironment.
The environment values to be set at runtime for flex template.
public MapField<string, string> AdditionalUserLabels { get; }
Additional user labels to be specified for the job.
Keys and values must follow the restrictions specified in the labeling
restrictions
page.
An object containing a list of "key": value pairs.
Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
If true, save a heap dump before killing a thread or process which is GC
thrashing or out of memory. The location of the heap file will either be
echoed back to the user, or the user will be given the opportunity to
download the heap file.
public string SaveHeapDumpsToGcsPath { get; set; }
Cloud Storage bucket (directory) to upload heap dumps to the given
location. Enabling this implies that heap dumps should be generated on OOM
(dump_heap_on_oom is set to true).
Docker registry location of container image to use for the 'worker harness.
Default is the container for the version of the SDK. Note this field is
only valid for portable pipelines.
The Compute Engine region
(https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
which worker processing should occur, e.g. "us-west1". Mutually exclusive
with worker_zone. If neither worker_region nor worker_zone is specified,
default to the control plane's region.
The Compute Engine zone
(https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
with worker_region. If neither worker_region nor worker_zone is specified,
a zone in the control plane's region is chosen based on available capacity.
If both worker_zone and zone are set, worker_zone takes precedence.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThe \u003ccode\u003eFlexTemplateRuntimeEnvironment\u003c/code\u003e class in the Dataflow v1beta3 API allows setting runtime environment values for flex templates.\u003c/p\u003e\n"],["\u003cp\u003eThis class inherits from \u003ccode\u003eobject\u003c/code\u003e and implements several interfaces, including \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eIt includes constructors to create new instances, either empty or as a copy of another \u003ccode\u003eFlexTemplateRuntimeEnvironment\u003c/code\u003e object.\u003c/p\u003e\n"],["\u003cp\u003eThe class has numerous properties to configure various aspects of the job environment, such as autoscaling, disk size, network settings, machine type, and Cloud Storage locations for temporary files and heap dumps.\u003c/p\u003e\n"],["\u003cp\u003eThe latest version available is \u003ccode\u003e2.0.0-beta07\u003c/code\u003e, and the assembly for this class is \u003ccode\u003eGoogle.Cloud.Dataflow.V1Beta3.dll\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,["# Dataflow v1beta3 API - Class FlexTemplateRuntimeEnvironment (2.0.0-beta07)\n\nVersion latestkeyboard_arrow_down\n\n- [2.0.0-beta07 (latest)](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/latest/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment)\n- [2.0.0-beta06](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/2.0.0-beta06/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment)\n- [1.0.0-beta03](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/1.0.0-beta03/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment) \n\n public sealed class FlexTemplateRuntimeEnvironment : IMessage\u003cFlexTemplateRuntimeEnvironment\u003e, IEquatable\u003cFlexTemplateRuntimeEnvironment\u003e, IDeepCloneable\u003cFlexTemplateRuntimeEnvironment\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Dataflow v1beta3 API class FlexTemplateRuntimeEnvironment.\n\nThe environment values to be set at runtime for flex template. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e FlexTemplateRuntimeEnvironment \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[FlexTemplateRuntimeEnvironment](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/latest/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[FlexTemplateRuntimeEnvironment](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/latest/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[FlexTemplateRuntimeEnvironment](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/latest/Google.Cloud.Dataflow.V1Beta3.FlexTemplateRuntimeEnvironment), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Dataflow.V1Beta3](/dotnet/docs/reference/Google.Cloud.Dataflow.V1Beta3/latest/Google.Cloud.Dataflow.V1Beta3)\n\nAssembly\n--------\n\nGoogle.Cloud.Dataflow.V1Beta3.dll\n\nConstructors\n------------\n\n### FlexTemplateRuntimeEnvironment()\n\n public FlexTemplateRuntimeEnvironment()\n\n### FlexTemplateRuntimeEnvironment(FlexTemplateRuntimeEnvironment)\n\n public FlexTemplateRuntimeEnvironment(FlexTemplateRuntimeEnvironment other)\n\nProperties\n----------\n\n### AdditionalExperiments\n\n public RepeatedField\u003cstring\u003e AdditionalExperiments { get; }\n\nAdditional experiment flags for the job.\n\n### AdditionalUserLabels\n\n public MapField\u003cstring, string\u003e AdditionalUserLabels { get; }\n\nAdditional user labels to be specified for the job.\nKeys and values must follow the restrictions specified in the [labeling\nrestrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)\npage.\nAn object containing a list of \"key\": value pairs.\nExample: { \"name\": \"wrench\", \"mass\": \"1kg\", \"count\": \"3\" }.\n\n### AutoscalingAlgorithm\n\n public AutoscalingAlgorithm AutoscalingAlgorithm { get; set; }\n\nThe algorithm to use for autoscaling\n\n### DiskSizeGb\n\n public int DiskSizeGb { get; set; }\n\nWorker disk size, in gigabytes.\n\n### DumpHeapOnOom\n\n public bool DumpHeapOnOom { get; set; }\n\nIf true, save a heap dump before killing a thread or process which is GC\nthrashing or out of memory. The location of the heap file will either be\nechoed back to the user, or the user will be given the opportunity to\ndownload the heap file.\n\n### EnableStreamingEngine\n\n public bool EnableStreamingEngine { get; set; }\n\nWhether to enable Streaming Engine for the job.\n\n### FlexrsGoal\n\n public FlexResourceSchedulingGoal FlexrsGoal { get; set; }\n\nSet FlexRS goal for the job.\n\u003chttps://cloud.google.com/dataflow/docs/guides/flexrs\u003e\n\n### IpConfiguration\n\n public WorkerIPAddressConfiguration IpConfiguration { get; set; }\n\nConfiguration for VM IPs.\n\n### KmsKeyName\n\n public string KmsKeyName { get; set; }\n\nName for the Cloud KMS key for the job.\nKey format is:\nprojects/\\\u003cproject\\\u003e/locations/\\\u003clocation\\\u003e/keyRings/\\\u003ckeyring\\\u003e/cryptoKeys/\\\u003ckey\\\u003e\n\n### LauncherMachineType\n\n public string LauncherMachineType { get; set; }\n\nThe machine type to use for launching the job. The default is\nn1-standard-1.\n\n### MachineType\n\n public string MachineType { get; set; }\n\nThe machine type to use for the job. Defaults to the value from the\ntemplate if not specified.\n\n### MaxWorkers\n\n public int MaxWorkers { get; set; }\n\nThe maximum number of Google Compute Engine instances to be made\navailable to your pipeline during execution, from 1 to 1000.\n\n### Network\n\n public string Network { get; set; }\n\nNetwork to which VMs will be assigned. If empty or unspecified,\nthe service will use the network \"default\".\n\n### NumWorkers\n\n public int NumWorkers { get; set; }\n\nThe initial number of Google Compute Engine instances for the job.\n\n### SaveHeapDumpsToGcsPath\n\n public string SaveHeapDumpsToGcsPath { get; set; }\n\nCloud Storage bucket (directory) to upload heap dumps to the given\nlocation. Enabling this implies that heap dumps should be generated on OOM\n(dump_heap_on_oom is set to true).\n\n### SdkContainerImage\n\n public string SdkContainerImage { get; set; }\n\nDocker registry location of container image to use for the 'worker harness.\nDefault is the container for the version of the SDK. Note this field is\nonly valid for portable pipelines.\n\n### ServiceAccountEmail\n\n public string ServiceAccountEmail { get; set; }\n\nThe email address of the service account to run the job as.\n\n### StagingLocation\n\n public string StagingLocation { get; set; }\n\nThe Cloud Storage path for staging local files.\nMust be a valid Cloud Storage URL, beginning with `gs://`.\n\n### Subnetwork\n\n public string Subnetwork { get; set; }\n\nSubnetwork to which VMs will be assigned, if desired. You can specify a\nsubnetwork using either a complete URL or an abbreviated path. Expected to\nbe of the form\n\"\u003chttps://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK\u003e\"\nor \"regions/REGION/subnetworks/SUBNETWORK\". If the subnetwork is located in\na Shared VPC network, you must use the complete URL.\n\n### TempLocation\n\n public string TempLocation { get; set; }\n\nThe Cloud Storage path to use for temporary files.\nMust be a valid Cloud Storage URL, beginning with `gs://`.\n\n### WorkerRegion\n\n public string WorkerRegion { get; set; }\n\nThe Compute Engine region\n(\u003chttps://cloud.google.com/compute/docs/regions-zones/regions-zones\u003e) in\nwhich worker processing should occur, e.g. \"us-west1\". Mutually exclusive\nwith worker_zone. If neither worker_region nor worker_zone is specified,\ndefault to the control plane's region.\n\n### WorkerZone\n\n public string WorkerZone { get; set; }\n\nThe Compute Engine zone\n(\u003chttps://cloud.google.com/compute/docs/regions-zones/regions-zones\u003e) in\nwhich worker processing should occur, e.g. \"us-west1-a\". Mutually exclusive\nwith worker_region. If neither worker_region nor worker_zone is specified,\na zone in the control plane's region is chosen based on available capacity.\nIf both `worker_zone` and `zone` are set, `worker_zone` takes precedence.\n\n### Zone\n\n public string Zone { get; set; }\n\nThe Compute Engine [availability\nzone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)\nfor launching worker instances to run your pipeline.\nIn the future, worker_zone will take precedence."]]