Cloud Foundry extension

  • Latest Dynatrace
  • Extension
  • Published Apr 07, 2026

Monitor Cloud Foundry container metrics and PaaS resource definitions with the Dynatrace extension for full infrastructure observability.

Get started

Overview

This extension uses the Cloud Foundry API (CAPI) to connect to the foundation and collect resource definitions and metadata for the following resource types:

  • info
  • apps
  • builds
  • domains
  • droplets
  • organizations
  • organization_quotas
  • packages
  • processes
  • routes
  • service_instances
  • spaces

This data can be ingested as metrics and optionally as events.

Use cases

Use this extension for:

  • Cloud Foundry resource topology
  • Overview dashboards and screens for Cloud Foundry workloads

Requirements

  • Cloud Foundry API (CAPI) v3
  • A user with read-only access to Cloud Controller API resources. cloud_controller.admin_read_only permission.
  • ActiveGate deployed on a Linux or Windows environment.

Compatibility information

  • Cloud Foundry API (CAPI) endpoints: v3/[RESOURCE] and legacy v2 APIs for /v2/info and [TOKEN_ENDPOINT]/oauth/token
  • Most vendor supported Cloud Foundry clusters should be compatible: IBM Cloud Foundry, SAP BTP, VMware Tanzu Application Service (TAS)

Activation and setup

Find Cloud Foundry in the in-product Extensions or Hub page and activate it.

Monitoring configurations

Once the extension is activated in your environment, you can create monitoring configurations.

  1. Select the ActiveGate group that will run the monitoring configuration.
  2. Provide the required extension configuration to connect to Cloud Foundry:
    • Connection Name: A basic name for this connection. This appears as the foundation name property.

    • Extension Schedule: How often the extension should run (default is every 1 minute).

    • CloudFoundry API Target (API_URL): The API to connect to, for example https://api.<your-cf-domain>.

    • Username and Password Credentials: Cloud Foundry username and password, stored securely in the Dynatrace Credential Vault.

      • We recommend using a Cloud Foundry admin read-only account that can view almost all Cloud Controller API resources, but can't modify them.

        Example:

        uaac user add ReadOnlyUser -p SecretPassword --emails something@example.com
        uaac member add cloud_controller.admin_read_only ReadOnlyUser
        uaac member add scim.read ReadOnlyUser
    • Optional CloudFoundry Client Credentials: Cloud Foundry client_id and client_secret. Use this only when your Cloud Foundry environment does not use the default public OAuth2 client (client_id: cf, no secret).

      • Only required if your environment defines a custom OAuth client.
    • Ingest Resource JSON: Ingest resource definitions as a Dynatrace log event. This is useful to query and view, but the metrics will already contain much of this in dimensions.

    • Optional User Network Proxy: Connect from the Dynatrace ActiveGate to the Cloud Foundry API through a proxy. Provide Proxy Host, Username, and Password.

    • Verify SSL Certificates: Validate SSL/TLS certificates for this connection. Disable only for environments with self‑signed certificates, or use a custom certificate path.

  3. Review the available feature sets to determine which to enable and monitor. The enabled feature sets will affect which APIs are called.

Details

API requests

Getting Started with Cloud Foundry CAPI v3

  • Your Cloud Foundry API endpoint is typically available at: https://api.<your-cf-domain>. In the extension configuration this full URL is entered for the: 'CloudFoundry API Target' - API_URL.

  • A request for metadata is made to [API_URL]/v2/info which also includes the UAA TOKEN_ENDPOINT for Oauth authentication.

    Example:

    {
    "custom.api": "https://api.example.com",
    "name": "VMware Tanzu Application Service",
    "build": "2.10.35-build.1",
    "support": "https://support.pivotal.io",
    "version": 0,
    "description": "https://docs.pivotal.io/pivotalcf/2-10/pcf-release-notes/runtime-rn.html",
    "authorization_endpoint": "https://login.example.com",
    "token_endpoint": "https://uaa.example.com",
    "min_cli_version": "6.23.0",
    "min_recommended_cli_version": "6.23.0",
    "app_ssh_endpoint": "ssh.example.com:2222",
    "app_ssh_host_key_fingerprint": "...",
    "app_ssh_oauth_client": "ssh-proxy",
    "doppler_logging_endpoint": "wss://doppler.example:443",
    "api_version": "2.150.0",
    "osbapi_version": "2.15",
    "routing_endpoint": "https://api.example.com/routing"
    }
  • Direct UAA Authentication is then used to retrieve a bearer token using a password grant type.

  • The token is then used to authenticate resource GET requests: [API_URL]/v3/[RESOURCE] e.g., https://api.example.com/v3/organizations

  • The extension will then parse each response into metrics with metadata dimensions, and if enabled ingest the resource definition as a log event.

Licensing and cost

This extension ingests metrics and optionally logs. For more information about licensing costs, see Extending Dynatrace (Davis data units) or Metrics powered by Grail overview (DPS) depending on your license model.

  • Stable resources such as Organizations, Apps, Spaces, etc. are collected each polling interval. More volatile resources such as Builds, Droplets, Packages, and Processes are only collected when updated.
  • You can use feature sets to restrict which resources are monitored.
  • You can also configure custom monitoring intervals to collect data less frequently than the default of every 1 minute.

Topology

A custom entity type is created for each resource. You can visualize this topology in Infrastructure & Operations Infrastructure & Operations or use it in custom dashboards, queries or alerts.

  • Foundation: dt:cloudfoundry_foundation
  • App: dt:cloudfoundry_app
  • Build: dt:cloudfoundry_build
  • Domain: dt:cloudfoundry_domain
  • Droplet: dt:cloudfoundry_droplet
  • Organization: dt:cloudfoundry_org
  • Organization Quota: dt:cloudfoundry_org_quota
  • Package: dt:cloudfoundry_package
  • Process: dt:cloudfoundry_process
  • Route: dt:cloudfoundry_route
  • Service Instance: dt:cloudfoundry_service_instance
  • Space: dt:cloudfoundry_space

Platform monitoring correlation

To set up Dynatrace for Full stack monitoring on CloudFoundry refer to: Set up Dynatrace on Cloud Foundry. This allows you to deploy OneAgents to your Cloud Foundry cluster VMs and monitor the platform.

With both integrations enabled you then have:

  • Platform Monitoring: OneAgents deployed to cluster VMs for full-stack monitoring
  • API Resource Monitoring: This extension polling for resource definitions, metadata and topology information.

You can then use the Dynatrace Query Language (DQL) to map and visualize this data together. Examples:

  • Applications
    • API Extension: GUID from the https://api.example.com/v3/apps API.
    • OneAgent: CF_APP_ID available in the process metadata. This is collected from the container VCAP_APPLICATION environment variable
    • Example query: All monitored Application process groups
      fetch `dt.entity.dt:cloudfoundry_app`
      | fields id,guid
      | lookup [
      fetch dt.entity.process_group_instance
      | filter matchesPhrase(softwareTechnologies, "GARDEN")
      | fields metadata, customPgMetadata, gardenApplicationNames, softwareTechnologies, id, entity.name, instance_of
      | fieldsAdd cf_app_id = arrayFirst(arrayRemoveNulls(iCollectArray(parse(metadata[], """'CLOUD_FOUNDRY_APP_ID:' LD:CLOUD_FOUNDRY_APP_ID"""))))
      | filter isNotNull(cf_app_id)
      | fieldsAdd process_group_id = instance_of[dt.entity.process_group]
      ], sourceField: guid, lookupField:cf_app_id, prefix: "pgi."
      | lookup [
      fetch `dt.entity.process_group`
      | fields id, entity.name
      ], sourceField:pgi.process_group_id, lookupField:id, prefix:"pg."
      | fields pg.id, pg.entity.name
      | fieldsAdd process_group = record(entityId=pg.id, displayName=pg.entity.name, dim="dt.entity.process_group")
  • Spaces
    • API Extension: GUID from the https://api.example.com/v3/spaces API.
    • OneAgent: CF_SPACE_ID available in the process metadata. This is collected from the container VCAP_APPLICATION environment variable
    • Example query: All monitored Space process groups
      fetch `dt.entity.dt:cloudfoundry_space`
      | fields id,guid
      | lookup [
      fetch dt.entity.process_group_instance
      | filter matchesPhrase(softwareTechnologies, "GARDEN")
      | fields metadata, customPgMetadata, gardenApplicationNames, softwareTechnologies, id, entity.name, instance_of
      | fieldsAdd cf_space_id = arrayFirst(arrayRemoveNulls(iCollectArray(parse(metadata[], """'CLOUD_FOUNDRY_SPACE_ID:' LD:CLOUD_FOUNDRY_SPACE_ID"""))))
      | filter isNotNull(cf_space_id)
      | fieldsAdd process_group_id = instance_of[dt.entity.process_group]
      ], sourceField: guid, lookupField:cf_space_id, prefix: "pgi."
      | lookup [
      fetch `dt.entity.process_group`
      | fields id, entity.name
      ], sourceField:pgi.process_group_id, lookupField:id, prefix:"pg."
      | fields pg.id, pg.entity.name
      | fieldsAdd process_group = record(entityId=pg.id, displayName=pg.entity.name, dim="dt.entity.process_group")

Feature sets

When activating your extension using monitoring configuration, you can limit monitoring to one of the feature sets. To work properly, the extension has to collect at least one metric after the activation.

In highly segmented networks, feature sets can reflect the segments of your environment. Then, when you create a monitoring configuration, you can select a feature set and a corresponding ActiveGate group that can connect to this particular segment.

All metrics that aren't categorized into any feature set are considered to be the default and are always reported.

A metric inherits the feature set of a subgroup, which in turn inherits the feature set of a group. Also, the feature set defined on the metric level overrides the feature set defined on the subgroup level, which in turn overrides the feature set defined on the group level.

spaces
Metric nameMetric keyDescription
CloudFoundry Spacescloudfoundry.spaces.propertiesConstant metric used to report CloudFoundry Spaces properties as dimensions.
Cloudfoundry Space resources collected as logscloudfoundry.spaces.logs_collectedHow many resource logs were collected in the last query
processes
Metric nameMetric keyDescription
CloudFoundry Process Instancescloudfoundry.processes.instancesThe number of instances of the process
CloudFoundry Process Memory Usagecloudfoundry.processes.memory_limitProcess memory limit
CloudFoundry Process Disk Limitcloudfoundry.processes.disk_limitProcess disk usage limit
CloudFoundry Process Log Rate Limitcloudfoundry.processes.log_rate_limitProcess Log Rate Limit
Cloudfoundry Process resources collected as logscloudfoundry.processes.logs_collectedHow many resource logs were collected in the last query
default
Metric nameMetric keyDescription
CloudFoundry API Connectivitycloudfoundry.connectivityCloudfoundry API successful connection percentage
apps
Metric nameMetric keyDescription
CloudFoundry App Statecloudfoundry.apps.stateThe App state. STOPPED = 0, STARTED = 1. Use the state dimension for the string value.
Cloudfoundry App resources collected as logscloudfoundry.apps.logs_collectedHow many resource logs were collected in the last query
routes
Metric nameMetric keyDescription
CloudFoundry Routescloudfoundry.routes.propertiesConstant metric used to report CloudFoundry Route properties as dimensions.
Cloudfoundry Route resources collected as logscloudfoundry.routes.logs_collectedHow many resource logs were collected in the last query
organizationQuotas
Metric nameMetric keyDescription
CloudFoundry Org Quota Apps Total Memory Limitcloudfoundry.organization_quotas.apps.total_memory_limitTotal memory limit for all Apps in the quota
CloudFoundry Org Quota Apps Per Process Memory Limitcloudfoundry.organization_quotas.apps.per_process_memory_limitPer process memory limit for all Apps in the quota
CloudFoundry Org Quota Per App Task Limitcloudfoundry.organization_quotas.apps.per_app_tasksLimit for the total tasks per App in the quota
CloudFoundry Org Quota Apps Total Instance Limitcloudfoundry.organization_quotas.apps.total_instancesLimit for the total number of Apps in the quota
CloudFoundry Org Quota Apps Log Rate Limitcloudfoundry.organization_quotas.apps.log_rate_limitLog rate limit per App in the quota
CloudFoundry Org Quota Service Paid Allowedcloudfoundry.organization_quotas.services.paid_services_allowedThe number of paid services allowed in the quota
CloudFoundry Org Quota Service Total Instancescloudfoundry.organization_quotas.services.total_service_instancesThe number of service instances allowed in the quota
CloudFoundry Org Quota Service Total keyscloudfoundry.organization_quotas.services.total_service_keysThe number of service keys allowed in the quota
CloudFoundry Org Quota Routes Totalcloudfoundry.organization_quotas.routes.total_routesThe total number of routes in the quota
CloudFoundry Org Quota Routes Total Reserved Portscloudfoundry.organization_quotas.routes.total_reserved_portsThe total number of reserved ports in the quota
CloudFoundry Org Quota Domains Totalcloudfoundry.organization_quotas.domains.total_domainsThe total number of domains allowed in the quota
Cloudfoundry Organization Quota resources collected as logscloudfoundry.organization_quotas.logs_collectedHow many resource logs were collected in the last query
domains
Metric nameMetric keyDescription
CloudFoundry Domainscloudfoundry.domains.propertiesConstant metric used to report CloudFoundry Domain properties as dimensions.
Cloudfoundry Domain resources collected as logscloudfoundry.domains.logs_collectedHow many resource logs were collected in the last query
organizations
Metric nameMetric keyDescription
CloudFoundry Organizationscloudfoundry.organizations.propertiesConstant metric used to report CloudFoundry Organization properties as dimensions.
Cloudfoundry Organization resources collected as logscloudfoundry.organizations.logs_collectedHow many resource logs were collected in the last query
serviceInstances
Metric nameMetric keyDescription
CloudFoundry Service Instance Last Operation Statecloudfoundry.service_instances.last_operation.stateThe Service Instance last operation state. failed = 0, in progress = 1 succeeded = 2. Use the 'state' dimension for the string value.
Cloudfoundry Package resources collected as logscloudfoundry.service_instances.logs_collectedHow many resource logs were collected in the last query
builds
Metric nameMetric keyDescription
CloudFoundry Build Statecloudfoundry.builds.stateThe state of the build. FAILED = 0, STAGING = 1, STAGED = 2. Use the 'state' dimension for the string value.
CloudFoundry Build Staging Memory Limitcloudfoundry.builds.staging_memory_limitThe staging memory limit for the build
CloudFoundry Build Staging Disk Limitcloudfoundry.builds.staging_disk_limitThe staging disk limit for the build
CloudFoundry Build Staging Log Rate Limitcloudfoundry.builds.staging_log_rate_limitThe staging log rate limit for the build
Cloudfoundry Build resources collected as logscloudfoundry.builds.logs_collectedHow many resource logs were collected in the last query
packages
Metric nameMetric keyDescription
CloudFoundry Package Statecloudfoundry.packages.stateThe Package state. FAILED = 0, AWAITING_UPLOAD = 1, READY = 2. Use the 'state' dimension for the string value.
Cloudfoundry Package resources collected as logscloudfoundry.packages.logs_collectedHow many resource logs were collected in the last query
droplets
Metric nameMetric keyDescription
CloudFoundry Dropletscloudfoundry.droplets.propertiesConstant metric used to report CloudFoundry Droplet properties as dimensions.
Cloudfoundry Droplet resources collected as logscloudfoundry.droplets.logs_collectedHow many resource logs were collected in the last query

FAQ

What is the Custom Metric Usage of this extension?

The amount of custom metrics will vary depending on the number of resources running in your Foundation. Total number of:

  • apps
  • builds
  • domains
  • droplets
  • organizations
  • organization_quotas
  • packages
  • processes
  • routes
  • service_instances
  • spaces

With these values, the formula for datapoints ingested by the extension is:

  • Note: each line corresponds to a certain feature set which can be enabled or disabled. Except for default which is always collected.
Default: 1 (api connectivity)
+
Apps: 1 + (1 * number_of_apps)
+
Builds: 1 + (4 * number_of_builds)
+
Domains: 1 + (1 * number_of_domains)
+
Droplets: 1 + (1 * number_of_droplets)
+
Organizations: 1 + (1 * number_of_organizations)
+
Organization Quotas: 1 + (11 * number_of_org_quotas)
+
Packages: 1 + (1 * number_of_packages)
+
Processes: 1 + (4 * number_of_processes)
+
Routes: 1 + (1 * number_of_routes)
+
Service Instances: 1 + (1 * number_of_sis)
+
Spaces: 1 + (1 * number_of_spaces)

The result can be multiplied by 0.001 to get the amount of DDUs used per Minute or by 525600 to get the amount of datapoints used per year.

What is the Custom Log usage of this extension?

If enabled, ingested log events are simply 1 log event per Resource.

  • Stable resource definitions are reingested each polling interval: Apps, Domains, Organizations, Organization_Quotas, Routes, Service_Instances, Spaces
  • Volatile resource definitions are only ingested if they were recently updated: Builds, Droplets, Packages, Processes.
Related tags
CloudPythonCloud infrastructureThe Linux FoundationInfrastructure Observability