Configure large message payload support in Apigee hybrid

Overview

Apigee hybrid supports large message payloads up to 30MB. The default message payload size is 10MB. See Message payload size.

To enable environments in your hybrid installation to support large message payloads, you need to make the following changes to your runtime configuration:

  • Increase the heap size to 4Gi.
  • Increase memory limits to 6Gi.
  • Increase memory resource requests to 4Gi.

You can configure these settings for individual environments or for all environments in your installation.

Configure individual environments to support large message payloads

If the proxies configured to support large message payloads have endpoints in only one or a few environments in your installation, you can configure the environments to support large payloads. This avoids adding additional memory to environments that will not need to support large payloads.

To configure individual environments to support large message payloads, you can use the envs.components.runtime properties. Make the following changes to your overrides.yaml file:

  1. Add the following stanza to your overrides.yaml file:
    envs:
    - name: ENV_NAME
      components.
        runtime:
          cwcAppend:
            bin_setenv_max_mem: 4096m   # Increase max heap size to 4 gigs
          resources:
            requests:
              memory: 4Gi
            limits:
              memory: 6Gi
    

    See:

  2. Upgrade the apigee-env chart for each environment you are updating:

    Dry run:

    helm upgrade ENV_RELEASE_NAME apigee-env/ \
      --install \
      --namespace APIGEE_NAMESPACE \
      --set env=ENV_NAME \
      -f OVERRIDES_FILE \
      --dry-run=server
    
    • ENV_RELEASE_NAME is a name used to keep track of installation and upgrades of the apigee-env chart. This name must be unique from the other Helm release names in your installation. Usually this is the same as ENV_NAME. However, if your environment has the same name as your environment group, you must use different release names for the environment and environment group, for example dev-env-release and dev-envgroup-release. For more information on releases in Helm, see Three big concepts class="external" in the Helm documentation.
    • ENV_NAME is the name of the environment you are upgrading.
    • OVERRIDES_FILE is your edited overrides.yaml file.
  3. Upgrade the chart:

    Dry run:

    helm upgrade ENV_RELEASE_NAME apigee-env/ \
      --install \
      --namespace APIGEE_NAMESPACE \
      --set env=ENV_NAME \
      -f OVERRIDES_FILE
    

Configure all environments to support large message payloads

Changes to your runtime stanza will set the heap and memory limits for all environments in your installation. You can override these settings for individual environments with the envs.components.runtime properties.

  1. Add the following stanza to your overrides.yaml file:
    runtime:
      cwcAppend:
        bin_setenv_max_mem: 4096m   # Increase max heap size to 4 gigs
      resources:
        requests:
          memory: 4Gi
        limits:
          memory: 6Gi
    

    See:

  2. Upgrade the apigee-env chart for each environment in your installation:

    Dry run:

    helm upgrade ENV_RELEASE_NAME apigee-env/ \
      --install \
      --namespace APIGEE_NAMESPACE \
      --set env=ENV_NAME \
      -f OVERRIDES_FILE \
      --dry-run=server
    

    Upgrade the chart:

    helm upgrade ENV_RELEASE_NAME apigee-env/ \
      --install \
      --namespace APIGEE_NAMESPACE \
      --set env=ENV_NAME \
      -f OVERRIDES_FILE