Using microservices applications
This topic describes how to use Instana Microservices Application Monitoring for VMware Tanzu.
- The VMware Tanzu Foundation in the Instana Infrastructure Map
- Cloud Foundry Dashboards (private preview)
- Cloud Foundry Applications in Instana's Application Perspectives
- Automatic Maintenance Windows for BOSH deployments
- Pipeline Feedback for BOSH deployments
- Monitoring BOSH Agent, Gorouter and other processes
- More on How to Use Instana to Monitor Microservices
- Deployment of Cloud Foundry Applications
- VMware Tanzu Kubernetes Grid Support
The VMware Tanzu Foundation in the Instana Infrastructure Map
Instana Microservices Application Monitoring for VMware Tanzu is entirely automated. After installation, the Instana agent is rolled out to all the supported Virtual Machines across the VMware Tanzu foundation.
The Infrastructure Map of Instana provides the end user with powerful tools to make sense or the largest deployments:
- Dynamic Focus is a robust, full blown editor capable of searching through multiple data contexts simultaneously; see the Dynamic Focus Instana documentation for more information about how to use Dynamic Focus
- Grouping and perspectives are a way to organize large infrastructures in manageable groups; for more information, see the Infrastructure Monitoring Instana documentation for more information about how to use grouping and perspectives in the Infrastructure Map
Out of the box, Instana Microservices Application Monitoring for VMware Tanzu provides the following BOSH-related tags to aid with grouping:
agent_bosh_release_version
provides a short-hand to search for the version of the BOSH release deployed on the host; BOSH releases are upgraded in lock-step with Instana Microservices Application Monitoring for VMware Tanzu versions to simplify the overview of the update state of your Instana Microservices Application Monitoring for VMware Tanzubosh_deployment
,bosh_availability_zone
,bosh_instance_name
, andbosh_instance_id
are immediately-recognizable data for VMware Tanzu operators familiar with BOSH, the provisioning layer of VMware Tanzu
For more information about how to use the Instana dashboard, see the Instana documentation.
Cloud Foundry Dashboards (private preview)
Important: The Cloud Foundry Dashboards in Instana are currently in technical preview status. They are used in production at very large customers and provide great value, but we would still like to devote some more effort to them before we declare their general availability.
Note: This section describes a preview which is currently in public preview. Please reach out to support to request access.
The Cloud Foundry application platform is an important and distinct part of your overall application stack. To encompass this importance Instana has dedicated support for CloudFroundry applications. This starts by its own dedicated top-level element in the Instana UI which makes it easily accessible and easy to understand for Cloud Foundry users. At the same time all information is deeply linked via the DynamicGraph into other product areas like Infrastructure, Application Perspectives, and Tracing.
Listing Applications
By default, Instana lists all applications that it detects from all the reporting clusters. The applications are easily searchable or sortable by the most relevant information like state
, organization
, or space
.
Application Dashboard
The Cloud Foundry Application dashboard contains the most important information for an application to check for the status and any problems. It lists the Garden containers that this application is made of and links to a detailed Garden Container dashboard; for more information on how Instana monitors Garden containers, head over the Garden Container page. It also provides access to all calls to this application via the "Analyze Calls" button.
Cloud Foundry Applications in Instana's Application Perspectives
The applications deployed on a VMware Tanzu foundation monitored with the Instana Microservices Application Monitoring for VMware Tanzu tile are automatically monitored and their performance is readily available on Instana's dashboards.
Automatic Maintenance Windows for BOSH deployments
The Instana tile automatically detects BOSH deployments running across the VMware Tanzu foundation and automatically create, schedule and unschedule maintenance windows. For more information on the "Maintenance Windows" feature of Instana, please consult the Scheduling maintenance windows documentation page.
The "Automatic Maintenance Windows" feature of the tile requires the following configurations:
- Backend connection > API endpoint URL, to point to your tenant unit in Instana.
- Backend connection > API token requires an API token with (at least) the
Configuration of custom alerts
permission; for more information on API tokens, consult the Tokens documentation page.
The Automatic Maintenance Windows functionality can be deactivated with the Agent automatic configurations > Automatic maintenance windows for BOSH option in the tile configuration.
The rollout of the change requires to run Apply Changes in OpsManager to the VMware Tanzu Application Service for VMs or VMware Tanzu Kubernetes Grid tile.
Pipeline Feedback for BOSH deployments
Important: The Pipeline Feedback functionality is currently in experimental status. In foundations with many service instances, each of which usually has a a dedicated BOSH deployment, it may become a bit too chatty. Let us know what you think of it!
The Instana tile automatically detects BOSH deployments running across the VMware Tanzu foundation and reports them in Instana as a releases
of the Pipeline Feedback functionality. For more information on the Pipeline Feedback functionality,
please consult the Pipeline Feedback documentation page.
The "Pipeline Feedback for BOSH deployments" feature is opt-in. To turn it on, head over to the Instana tile configurations in OpsManager and activate the Agent automatic configurations > [Experimental] Pipeline Feedback for BOSH option. Also, make sure to configure correctly the following settings:
- Backend connection > API endpoint URL, to point to your tenant unit in Instana.
- Backend connection > API token requires an API token with (at least) the
Configuration of releases
permission; for more information on API tokens, consult the Tokens documentation page.
The rollout of the change requires to run Apply Changes in OpsManager to the VMware Tanzu Application Service for VMs or VMware Tanzu Kubernetes Grid tile.
Monitoring BOSH Agent, Gorouter and other processes
Instana automatically monitors out-of-the-box CPU, memory and file descriptor consumption of notable processes in the Cloud Foundry and Kubernetes control plane. Specifically:
- BOSH agent
- BOSH DNS
- Gorouter
- Cloud Controller
- kube-apiserver
- kube-controller-manager
- kube-scheduler
More on How to Use Instana to Monitor Microservices
For more information about how to use Instana's advanced tracing and monitoring capabilities, see the Instana documentation.
Deployment of Cloud Foundry Applications
The goal of Instana Microservices Application Monitoring for VMware Tanzu is to entirely automate the monitoring of Cloud Foundry applications and their services; while we work on achieving the goal, in some cases some minor configuration steps may be required, depending on which type of Cloud Foundry application is pushed.
Deploying Java applications
Monitoring of Java applications is entirely automated by the Instana agent, which will trace Java applications without needing them even to restart.
Deploying DotNet Core Apps with the DotNet Core Buildpack
The Instana Microservices Application Monitoring for VMware Tanzu supports the monitoring of non self-contained DotNet Core applications by following the following steps:
-
Add the Instana Nuget package to the Cloud Foundry application by performing the following command:
dotnet add myproject.csproj package Instana.Profiler.Linux.Bundled.Refs
-
Prepare the DotNet Core application to be published:
dotnet publish -c Release
-
Add the following environment variables to the application manifest:
--- applications: - name: <application_name> path: bin/Release/netcoreapp3.1/publish/ env: CORECLR_ENABLE_PROFILING: 1 CORECLR_PROFILER: "{cf0d821e-299b-5307-a3d8-b283c03916dd}" CORECLR_PROFILER_PATH: "/home/vcap/app/instana_tracing/CoreProfiler.so" LD_LIBRARY_PATH: "/home/vcap/app/instana_tracing" DOTNET_STARTUP_HOOKS: "/home/vcap/app/Instana.Tracing.Core.dll"
Notice that the value of the path
variable may change depending on the .NET Core SDK being used and the name of the configuration passed to the dotnet publish -c Release
via the -c
flag, which in this
example is Release
.
-
Push the Cloud Foundry application using the
cf push
command:cf push
Notice that the command above assumes that the application's manifest.mf
file resides in the folder from which the cf push
command is executed. See Deploying with App Manifests page for more information on how to use the cf push
command together with a manifest file.
Deploying Node.js Apps with the Node.js Buildpack
Tip: The instana_buildpack
buildpack can automate this setup entirely, without code-changes in your codebase.
The only step necessary is adding the @instana/collector
package; see the Installation section of the Instana Node.js
documentation.
Deploying Python Apps with the Python Buildpack
Tip: The instana_buildpack
buildpack can automate this setup entirely, without code-changes in your codebase.
Monitoring Python Cloud Foundry applications requires the following steps:
-
Add the
instana
package to therequirements.txt
file -
Add to the application manifest the
AUTOWRAPT_BOOTSTRAP
environment variable with valueinstana
as showed below--- applications: - name: test-python-flask buildpacks: - python_buildpack env: AUTOWRAPT_BOOTSTRAP: instana
Deploying Ruby Apps with the Ruby Buildpack
Tip: The instana_buildpack
buildpack can automate this setup entirely, without code-changes in your codebase.
The only step necessary is adding the instana
gem; see the Installation section of the Instana Ruby documentation.
Instana Cloud Foundry Buildpack
Important: The instana_buildpack
Cloud Foundry buildpack is currently in experimental status. The deployment of the instana_buildpack
is opt-in in the tile under the Agent automatic configurations screen.
Since version 1.177.0, the tile integrates the instana_buildpack
Cloud Foundry buildpack that automates the Instana setup of Node.js, Python or Ruby Cloud Foundry application. When the instana_buildpack
is opted-in
by the Cloud Foundry application manifest, it automatically configures the staging process to bake in the droplet (the container image that is run by Cloud Foundry) all that is needed to have that Cloud Foundry application monitored with
Instana.
The instana_buildpack
is a so-called decorator buildpack, which adds logic and resources to the staging process, and must be used in conjunction with a final buildpack, which actually launches the Cloud Foundry
application instances. For example the following command line will use the instana_buildpack
to automate monitoring of a Node.js application:
cf push -b instana_buildpack -b nodejs_buildpack
The same can be achieved defining multiple buildpacks in the application manifest.yml
as follows:
---
applications:
- name: test-nodejs
buildpacks:
- instana_buildpack
- nodejs_buildpack
For more information on how to use multiple buildpack when pushing Cloud Foundry applications, refer to the Pushing an App with Multiple Buildpacks documentation.
Important: The instana_buildpack
buildpack must not be used as the last buildpack in the sequence of buildpacks, as that will result in a staging error.
VMware Tanzu Kubernetes Grid Support
VMware Tanzu Kubernetes Grid, formerly known as Pivotal Container Service (PKS), is an enterprise Kubernetes platform, architected for rapid results, scaling, and reliability on any infrastructure. For more information about VMware Tanzu Kubernetes Grid, visit the VMware Tanzu Kubernetes Grid page.
Installation
The Instana Microservices Application Monitoring for VMware Tanzu tile includes full support for VMware Tanzu Kubernetes Grid. See the Installing and Configuring Instana Microservices Application Monitoring for VMware Tanzu for guidance on how to install the Instana Microservices Application Monitoring for VMware Tanzu tile.
After its rollout in a foundation with VMware Tanzu Kubernetes Grid installed, Instana's Kubernetes monitoring will be automatically deployed on all Kubernetes clusters created by the VMware Tanzu Kubernetes Grid Service Broker.
Kubernetes clusters that already existed before the rollout of the Instana tile will need to be upgraded to receive the Instana agents; for more information on how to upgrade Kubernetes clusters via VMware Tanzu Kubernetes Grid, see the Upgrading Clusters page.
Configuration
Agent configurations specify to the tile will apply for agents running on BOSH as well as on Kubernetes; see the Installing and Configuring Instana Microservices Application Monitoring for VMware Tanzu page for an overview of which configurations can be set at the agent level.
Kubernetes Clusters in Instana
Like all other supported Kubernetes versions and distributions, Kubernetes clusters that are created through the VMware Tanzu Kubernetes Grid are visible in the Kubernetes views of Instana.
All features available for other Kubernetes distributions are also available for VMware Tanzu Kubernetes Grid. The Instana tile automatically configures the deployment of the agents to the Pod Security Policies settings configured in the VMware Tanzu Kubernetes Grid tile.
For more information on how Kubernetes is monitored by Instana, see the Kubernetes page of the Instana documentation.