confidential
Making	application	monitoring	a	cloud	platform	feature
January	25,	2017	– Alois	Mayr	– @mayralois
confidential
about:me
§ Linz,	Austria
§ Software	Engineering	background
§ Software	Quality	Models
§ Shift	to	“Ops”	topics,	Cloud	&	Containers
confidential
about:dynatrace
§ APM	market	leader	who	helps	companies	in	Digital	
transformation
§ Founded	in	Austria	back	in	2005
§ ~	1600	employees	worldwide
§ >	8000	customers	across	all	industries
§ Seen	many	performance	and	stability	problems	and	
patterns	out	there
confidential
about:you
§ Who	of	you	run/manage/use	any	kind	of	containers	in	
production?
§ Cloud	Foundry?	
§ Kubernetes?
The	cloud-native	evolution
9	out	of	10
of	surveyed	respondents	are	going	to
migrate	to	cloud	technologies
within	the	next	five	years
Get	your	copy	https://info.dynatrace.com/apm_all_wp_cloud_native_evolution_en_registration.html
..but	what	does	it	mean	to	be	cloud	native?
Onsi Fakhoui:	VP	Cloud	Research	&	Development
..but	what	does	it	mean	to	be	cloud	native?
Micro-services	oriented	- loosely	coupled,	explicit	dependencies
Container	packaged	- isolated	unit	of	application	deployment
Dynamically	managed	- central	orchestration	process
Source:	Cloud	Native	Computing	Foundation
confidential
Micro-services	oriented
§ Pick	the	technology	you	want	to	use
§ Develop	and	deploy	independently
§ Scale	services	independently
confidential
What	does	this	mean?
No	longer	throw	it	over	the	wall
bash-3.2$ cf target -s prod
API endpoint: https://api.cf.$DOMAIN
User: amayr
Org: dynatrace
Space: prod
bash-3.2$ cf push
confidential
Tons	of	services	and	instances…
confidential
From	stack	traces	to	service	tracing
Tightly	coupled.	Really	Distribute?
confidential
How	to	get	monitoring	to	your	services
confidential
Goal
Get	the	agent	
into	garden	
containers
confidential
How
Integrate	with	
buildpacks and	
have	them	do	
the	job
Buildpacks
Java	buildpack
IBM	Liberty	buildpack
Nodejs buildpack
confidential
How	to	monitor	CF	apps	with	Dynatrace	(Option	1)
§ Java	buildpack integrated	with	buildpack
§ IBM	Websphere Liberty	buildpack integrated	with	buildpack
§ Node.js via	npm module
§ .NET	(on	Windows	cells) co-deploy	with	app
confidential
Create	a	Dynatrace	service	
$ cf cups dynatrace-example -p '{"environmentid":"someenvirontmentid",
"apitoken":"someapitoken"}'
Creating user provided service dynatrace-example in org dynatrace / space dev as admin...
OK
$ cf s
Getting services in org dynatrace / space dev as admin...
OK
name service plan bound apps last operation
easytravel-mongodb easytravel-mongodb free create succeeded
dynatrace-example user-provided
Alternative:
You	cloud	also	use	a	service-broker	that	is	available	on	GitHub
https://github.com/dynatrace-innovationlab/dynatrace-service-broker
Note:	Make	sure	the	name	of	the	service	contains	’dynatrace’
confidential
Pivotal	Cloud	Foundry	Tile
§ Tile	uses	service-broker	to	manage	various	Dynatrace	environments
§ Central	point	of	configuration	– use	it	everywhere
confidential
Configure	your	apps
$ cat manifest-withDynatrace.yml
---
applications:
- name: easytravel-backend
memory: 786M
instances: 1
host: easytravel-backend-dynatrace
path: app/easyTravel/deploy/backend/backend.war
buildpack: https://github.com/cloudfoundry/java-buildpack.git
services:
- easytravel-mongodb
- dynatrace-example
- name: easytravel-frontend
memory: 768M
instances: 1
host: easytravel-frontend-dynatrace
path: app/easyTravel/deploy/frontend/frontend.war
buildpack: https://github.com/cloudfoundry/java-buildpack.git
services:
- dynatrace-example
env:
ET_BACKEND_URL: 'http://easytravel-backend-dynatrace.apps.pcf.example.com'
confidential
Push	your	apps
$ cf push -f manifest-withDynatrace.yml
Using manifest file manifest-withDynatrace.yml
Creating app easytravel-backend in org dynatrace / space dev as admin...
OK
Using route easytravel-backend-dynatrace.apps.pcf.example.com
Binding easytravel-backend-dynatrace.apps.pcf.example.com to easytravel-backend...
OK
-----> Downloading Open JDK Like Memory Calculator 2.0.2_RELEASE from
https://download.run.pivotal.io/memory-calculator/trusty/x86_64/memory-calculator-2.0.2_RELEASE.tar.gz
(0.1s)
Memory Settings: -Xss268K -Xmx523161K -XX:MaxMetaspaceSize=80486K -Xms523161K -
XX:MetaspaceSize=80486K
-----> Downloading Dynatrace One Agent latest from
https://example.live.dynatrace.com/api/v1/deployment/installer/agent/unix/paas/latest?include=java&bitness=6
4&Api-Token=exampletoken (3.1s)
Expanding Dynatrace OneAgent to .java-buildpack/dynatrace_one_agent (0.1s)
-----> Downloading Tomcat Instance 8.0.37 from https://java-buildpack.cloudfoundry.org/tomcat/ tomcat-
8.0.37.tar.gz (0.4s)
confidential
confidential
Full-Stack	Cloud	Foundry	Monitoring
Cloud	monitoring	taken	to	the	next	level
confidential
Goal
Deploy	agent	
to	ALL	
components	
and	containers
confidential
How	injection	into	garden	containers	work
§ Secret	sauce	J
§ But….	No kernel module needed
confidential
How	to	get	full-stack	monitoring	for	Cloud	Foundry
§ Deploy	OneAgent	to	each	and	every	bosh-managed	VM
§ bosh	ssh
§ wget |	sh
OR	by	means	of	a	bosh	release	/	addon
§ bosh	upload	release	dynatrace-oneagent.tgz
§ bosh	update	runtime-config dynatrace-oneagent.yml
§ bosh	deploy
confidential
bosh	addon
$ bosh upload release dynatrace-oneagent.tgz
$ bosh update runtime-config runtime-config-dynatrace.yml
Acting as user 'director' on 'p-bosh'
Successfully updated runtime config
ubuntu@opsmanager192:~$ bosh runtime-config
Acting as user 'director' on 'p-bosh'
releases:
- name: dynatrace-oneagent
version: 1.0
addons:
- name: dynatrace-oneagent
jobs:
- name: dynatrace-oneagent
release: dynatrace-oneagent
properties:
dynatrace:
downloadurl: https://<environmentid>.live.dynatrace.com/installer/agent/unix/latest/<token>
processhooking: 1
proxy:
applogaccess: 1
confidential
Cluster	network	health
confidential
CF	cluster	component	health
confidential
cloud_controller process	eats	up	all	the	CPU	time
confidential
Get	the	log	files	of	the	process
confidential
MySQL	server	has	gone	away
confidential
Code-level	visibility	&	service	tracing
Cluster	components	metrics	and	health
Network	quality	&	Log	visibility
AI-based	analytics	across	apps	&	cluster
Available	SaaS	and	on-premise
Recap	- Full-Stack
confidential
Be	the	one	who	monitors
Thanks

Monitoring a cloud native platform feature