# Google Cloud Orchestration Airflow V1 Client - Class EnvironmentConfig (2.2.3)

2.2.3 (latest) 2.2.2 2.1.8 2.0.1 1.6.4 1.5.0 1.4.2 1.3.0 1.2.0 1.1.0 1.0.4 Reference documentation and code samples for the Google Cloud Orchestration Airflow V1 Client class EnvironmentConfig.

Configuration information for an environment.

Generated from protobuf message `google.cloud.orchestration.airflow.service.v1.EnvironmentConfig`

## Namespace

Google \\ Cloud \\ Orchestration \\ Airflow \\ Service \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ gke_cluster` | `string` Output only. The Kubernetes Engine cluster used to run this environment. |
| `↳ dag_gcs_prefix` | `string` Output only. The Cloud Storage prefix of the DAGs for this environment. Although Cloud Storage objects reside in a flat namespace, a hierarchical file tree can be simulated using "/"-delimited object name prefixes. DAG objects for this environment reside in a simulated directory with the given prefix. |
| `↳ node_count` | `int` The number of nodes in the Kubernetes Engine cluster that will be used to run this environment. This field is supported for Cloud Composer environments in versions composer-1.*.* -airflow-*.*.\*. |
| `↳ software_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.SoftwareConfig` Optional. The configuration settings for software inside the environment. |
| `↳ node_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.NodeConfig` Optional. The configuration used for the Kubernetes Engine cluster. |
| `↳ private_environment_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.PrivateEnvironmentConfig` Optional. The configuration used for the Private IP Cloud Composer environment. |
| `↳ web_server_network_access_control` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerNetworkAccessControl` Optional. The network-level access control policy for the Airflow web server. If unspecified, no network-level access restrictions will be applied. |
| `↳ database_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DatabaseConfig` Optional. The configuration settings for Cloud SQL instance used internally by Apache Airflow software. |
| `↳ web_server_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerConfig` Optional. The configuration settings for the Airflow web server App Engine instance. |
| `↳ encryption_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EncryptionConfig` Optional. The encryption options for the Cloud Composer environment and its dependencies. Cannot be updated. |
| `↳ maintenance_window` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MaintenanceWindow` Optional. The maintenance window is the period when Cloud Composer components may undergo maintenance. It is defined so that maintenance is not executed during peak hours or critical time periods. The system will not be under maintenance for every occurrence of this window, but when maintenance is planned, it will be scheduled during the window. The maintenance window period must encompass at least 12 hours per week. This may be split into multiple chunks, each with a size of at least 4 hours. If this value is omitted, the default value for maintenance window is applied. By default, maintenance windows are from 00:00:00 to 04:00:00 (GMT) on Friday, Saturday, and Sunday every week. |
| `↳ workloads_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WorkloadsConfig` Optional. The workloads configuration settings for the GKE cluster associated with the Cloud Composer environment. The GKE cluster runs Airflow scheduler, web server and workers workloads. This field is supported for Cloud Composer environments in versions composer-2.*.* -airflow-*.*.\* and newer. |
| `↳ environment_size` | `int` Optional. The size of the Cloud Composer environment. This field is supported for Cloud Composer environments in versions composer-2.*.* -airflow-*.*.\* and newer. |
| `↳ airflow_uri` | `string` Output only. The URI of the Apache Airflow Web UI hosted within this environment (see [Airflow web interface](https://docs.cloud.google.com/composer/docs/how-to/accessing/airflow-web-interface)). |
| `↳ airflow_byoid_uri` | `string` Output only. The 'bring your own identity' variant of the URI of the Apache Airflow Web UI hosted within this environment, to be accessed with external identities using workforce identity federation (see [Access environments with workforce identity federation](https://docs.cloud.google.com/composer/docs/composer-2/access-environments-with-workforce-identity-federation)). |
| `↳ master_authorized_networks_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MasterAuthorizedNetworksConfig` Optional. The configuration options for GKE cluster master authorized networks. By default master authorized networks feature is: - in case of private environment: enabled with no external networks allowlisted. - in case of public environment: disabled. |
| `↳ recovery_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.RecoveryConfig` Optional. The Recovery settings configuration of an environment. This field is supported for Cloud Composer environments in versions composer-2.*.* -airflow-*.*.\* and newer. |
| `↳ resilience_mode` | `int` Optional. Resilience mode of the Cloud Composer Environment. This field is supported for Cloud Composer environments in versions composer-2.2.0-airflow-*.*.\* and newer. |
| `↳ data_retention_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DataRetentionConfig` Optional. The configuration setting for Airflow database data retention mechanism. |

### getGkeCluster

Output only. The Kubernetes Engine cluster used to run this environment.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setGkeCluster

Output only. The Kubernetes Engine cluster used to run this environment.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDagGcsPrefix

Output only. The Cloud Storage prefix of the DAGs for this environment.

Although Cloud Storage objects reside in a flat namespace, a hierarchical
file tree can be simulated using "/"-delimited object name prefixes. DAG
objects for this environment reside in a simulated directory with the given
prefix.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setDagGcsPrefix

Output only. The Cloud Storage prefix of the DAGs for this environment.

Although Cloud Storage objects reside in a flat namespace, a hierarchical
file tree can be simulated using "/"-delimited object name prefixes. DAG
objects for this environment reside in a simulated directory with the given
prefix.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getNodeCount

The number of nodes in the Kubernetes Engine cluster that will be
used to run this environment.

This field is supported for Cloud Composer environments in versions
composer-1.*.* -airflow-*.*.\*.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` |   |

### setNodeCount

The number of nodes in the Kubernetes Engine cluster that will be
used to run this environment.

This field is supported for Cloud Composer environments in versions
composer-1.*.* -airflow-*.*.\*.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSoftwareConfig

Optional. The configuration settings for software inside the environment.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.SoftwareConfig|null` |   |

### hasSoftwareConfig

### clearSoftwareConfig

### setSoftwareConfig

Optional. The configuration settings for software inside the environment.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.SoftwareConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getNodeConfig

Optional. The configuration used for the Kubernetes Engine cluster.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.NodeConfig|null` |   |

### hasNodeConfig

### clearNodeConfig

### setNodeConfig

Optional. The configuration used for the Kubernetes Engine cluster.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.NodeConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getPrivateEnvironmentConfig

Optional. The configuration used for the Private IP Cloud Composer
environment.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.PrivateEnvironmentConfig|null` |   |

### hasPrivateEnvironmentConfig

### clearPrivateEnvironmentConfig

### setPrivateEnvironmentConfig

Optional. The configuration used for the Private IP Cloud Composer
environment.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.PrivateEnvironmentConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getWebServerNetworkAccessControl

Optional. The network-level access control policy for the Airflow web
server. If unspecified, no network-level access restrictions will be
applied.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerNetworkAccessControl|null` |   |

### hasWebServerNetworkAccessControl

### clearWebServerNetworkAccessControl

### setWebServerNetworkAccessControl

Optional. The network-level access control policy for the Airflow web
server. If unspecified, no network-level access restrictions will be
applied.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerNetworkAccessControl` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDatabaseConfig

Optional. The configuration settings for Cloud SQL instance used internally
by Apache Airflow software.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DatabaseConfig|null` |   |

### hasDatabaseConfig

### clearDatabaseConfig

### setDatabaseConfig

Optional. The configuration settings for Cloud SQL instance used internally
by Apache Airflow software.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DatabaseConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getWebServerConfig

Optional. The configuration settings for the Airflow web server App Engine
instance.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerConfig|null` |   |

### hasWebServerConfig

### clearWebServerConfig

### setWebServerConfig

Optional. The configuration settings for the Airflow web server App Engine
instance.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WebServerConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEncryptionConfig

Optional. The encryption options for the Cloud Composer environment
and its dependencies. Cannot be updated.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EncryptionConfig|null` |   |

### hasEncryptionConfig

### clearEncryptionConfig

### setEncryptionConfig

Optional. The encryption options for the Cloud Composer environment
and its dependencies. Cannot be updated.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EncryptionConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getMaintenanceWindow

Optional. The maintenance window is the period when Cloud Composer
components may undergo maintenance. It is defined so that maintenance is
not executed during peak hours or critical time periods.

The system will not be under maintenance for every occurrence of this
window, but when maintenance is planned, it will be scheduled
during the window.
The maintenance window period must encompass at least 12 hours per week.
This may be split into multiple chunks, each with a size of
at least 4 hours.
If this value is omitted, the default value for maintenance window is
applied. By default, maintenance windows are from 00:00:00 to 04:00:00
(GMT) on Friday, Saturday, and Sunday every week.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MaintenanceWindow|null` |   |

### hasMaintenanceWindow

### clearMaintenanceWindow

### setMaintenanceWindow

Optional. The maintenance window is the period when Cloud Composer
components may undergo maintenance. It is defined so that maintenance is
not executed during peak hours or critical time periods.

The system will not be under maintenance for every occurrence of this
window, but when maintenance is planned, it will be scheduled
during the window.
The maintenance window period must encompass at least 12 hours per week.
This may be split into multiple chunks, each with a size of
at least 4 hours.
If this value is omitted, the default value for maintenance window is
applied. By default, maintenance windows are from 00:00:00 to 04:00:00
(GMT) on Friday, Saturday, and Sunday every week.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MaintenanceWindow` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getWorkloadsConfig

Optional. The workloads configuration settings for the GKE cluster
associated with the Cloud Composer environment. The GKE cluster runs
Airflow scheduler, web server and workers workloads.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WorkloadsConfig|null` |   |

### hasWorkloadsConfig

### clearWorkloadsConfig

### setWorkloadsConfig

Optional. The workloads configuration settings for the GKE cluster
associated with the Cloud Composer environment. The GKE cluster runs
Airflow scheduler, web server and workers workloads.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.WorkloadsConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEnvironmentSize

Optional. The size of the Cloud Composer environment.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [EnvironmentSize](https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EnvironmentConfig.EnvironmentSize). |

### setEnvironmentSize

Optional. The size of the Cloud Composer environment.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [EnvironmentSize](https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EnvironmentConfig.EnvironmentSize). |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAirflowUri

Output only. The URI of the Apache Airflow Web UI hosted within this
environment (see [Airflow web
interface](https://docs.cloud.google.com/composer/docs/how-to/accessing/airflow-web-interface)).

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setAirflowUri

Output only. The URI of the Apache Airflow Web UI hosted within this
environment (see [Airflow web
interface](https://docs.cloud.google.com/composer/docs/how-to/accessing/airflow-web-interface)).

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAirflowByoidUri

Output only. The 'bring your own identity' variant of the URI of the Apache
Airflow Web UI hosted within this environment, to be accessed with external
identities using workforce identity federation (see [Access environments
with workforce identity
federation](https://docs.cloud.google.com/composer/docs/composer-2/access-environments-with-workforce-identity-federation)).

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setAirflowByoidUri

Output only. The 'bring your own identity' variant of the URI of the Apache
Airflow Web UI hosted within this environment, to be accessed with external
identities using workforce identity federation (see [Access environments
with workforce identity
federation](https://docs.cloud.google.com/composer/docs/composer-2/access-environments-with-workforce-identity-federation)).

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getMasterAuthorizedNetworksConfig

Optional. The configuration options for GKE cluster master authorized
networks. By default master authorized networks feature is:

- in case of private environment: enabled with no external networks
  allowlisted.

- in case of public environment: disabled.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MasterAuthorizedNetworksConfig|null` |   |

### hasMasterAuthorizedNetworksConfig

### clearMasterAuthorizedNetworksConfig

### setMasterAuthorizedNetworksConfig

Optional. The configuration options for GKE cluster master authorized
networks. By default master authorized networks feature is:

- in case of private environment: enabled with no external networks
  allowlisted.

- in case of public environment: disabled.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.MasterAuthorizedNetworksConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getRecoveryConfig

Optional. The Recovery settings configuration of an environment.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.RecoveryConfig|null` |   |

### hasRecoveryConfig

### clearRecoveryConfig

### setRecoveryConfig

Optional. The Recovery settings configuration of an environment.

This field is supported for Cloud Composer environments in versions
composer-2.*.* -airflow-*.*.\* and newer.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.RecoveryConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getResilienceMode

Optional. Resilience mode of the Cloud Composer Environment.

This field is supported for Cloud Composer environments in versions
composer-2.2.0-airflow-*.*.\* and newer.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [ResilienceMode](https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EnvironmentConfig.ResilienceMode). |

### setResilienceMode

Optional. Resilience mode of the Cloud Composer Environment.

This field is supported for Cloud Composer environments in versions
composer-2.2.0-airflow-*.*.\* and newer.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [ResilienceMode](https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.EnvironmentConfig.ResilienceMode). |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDataRetentionConfig

Optional. The configuration setting for Airflow database data retention
mechanism.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DataRetentionConfig|null` |   |

### hasDataRetentionConfig

### clearDataRetentionConfig

### setDataRetentionConfig

Optional. The configuration setting for Airflow database data retention
mechanism.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-orchestration-airflow/latest/V1.DataRetentionConfig` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |