+If you want to apply as a Solutions or Sales Engineer at [Datadog](http://datadog.com) you are in the right spot. Read on, it's fun, I promise.
-# Why work at Datadog?
-We tackle some of the hardest technical problems while delivering a product that "just works" for our customers. And we are backed by some of the best VCs in NYC and the world.
+
+
-Do you want to make a difference? Are you exceptional at your job, and intrinsically motivated by it? Do you eat hard problems for breakfast and find them beautifully simple solutions by lunchtime? Do you ever wish you were there in the early days of these startups everyone is talking about?
+## The Exercise
-If so, we want to hear from you.
+Don’t forget to read the [References](https://github.com/DataDog/hiring-engineers/blob/solutions-engineer/README.md#references)
-[source](http://jobs.datadoghq.com/)
+## Questions
-# The Positions
+Please provide screenshots and code snippets for all steps.
-1. Solutions Engineer: check out the `solutions-engineer` [branch](https://github.com/DataDog/hiring-engineers/tree/solutions-engineer) of this repository.
-2. Devops Evangelist: check out the `devops-evangelist` [branch](https://github.com/DataDog/hiring-engineers/tree/devops-evangelist) of this repository.
+## Prerequisites - Setup the environment
+You can utilize any OS/host that you would like to complete this exercise. However, we recommend one of the following approaches:
-# How do I submit my results?
+* You can spin up a fresh linux VM via Vagrant or other tools so that you don’t run into any OS or dependency issues. [Here are instructions](https://github.com/DataDog/hiring-engineers/blob/solutions-engineer/README.md#vagrant) for setting up a Vagrant Ubuntu VM. We strongly recommend using minimum `v. 16.04` to avoid dependency issues.
+* You can utilize a Containerized approach with Docker for Linux and our dockerized Datadog Agent image.
-1. Fork this repository.
-2. Check out the branch that interests you.
-3. Commit your work.
-4. Submit a pull request against this upstream repository.
+Once this is ready, sign up for a trial Datadog at https://www.datadoghq.com/
-# Questions?
-File an issue in this repository.
+**Please make sure to use “Datadog Recruiting Candidate” in [the “Company” field](https://a.cl.ly/wbuPdEBy)**
+
+Then, get the Agent reporting metrics from your local machine and move on to the next section...
+
+## Collecting Metrics:
+
+* Add tags in the Agent config file and show us a screenshot of your host and its tags on the Host Map page in Datadog.
+* Install a database on your machine (MongoDB, MySQL, or PostgreSQL) and then install the respective Datadog integration for that database.
+* Create a custom Agent check that submits a metric named my_metric with a random value between 0 and 1000.
+* Change your check's collection interval so that it only submits the metric once every 45 seconds.
+* **Bonus Question** Can you change the collection interval without modifying the Python check file you created?
+
+## Visualizing Data:
+
+Utilize the Datadog API to create a Timeboard that contains:
+
+* Your custom metric scoped over your host.
+* Any metric from the Integration on your Database with the anomaly function applied.
+* Your custom metric with the rollup function applied to sum up all the points for the past hour into one bucket
+
+Please be sure, when submitting your hiring challenge, to include the script that you've used to create this Timeboard.
+
+Once this is created, access the Dashboard from your Dashboard List in the UI:
+
+* Set the Timeboard's timeframe to the past 5 minutes
+* Take a snapshot of this graph and use the @ notation to send it to yourself.
+* **Bonus Question**: What is the Anomaly graph displaying?
+
+## Monitoring Data
+
+Since you’ve already caught your test metric going above 800 once, you don’t want to have to continually watch this dashboard to be alerted when it goes above 800 again. So let’s make life easier by creating a monitor.
+
+Create a new Metric Monitor that watches the average of your custom metric (my_metric) and will alert if it’s above the following values over the past 5 minutes:
+
+* Warning threshold of 500
+* Alerting threshold of 800
+* And also ensure that it will notify you if there is No Data for this query over the past 10m.
+
+Please configure the monitor’s message so that it will:
+
+* Send you an email whenever the monitor triggers.
+* Create different messages based on whether the monitor is in an Alert, Warning, or No Data state.
+* Include the metric value that caused the monitor to trigger and host ip when the Monitor triggers an Alert state.
+* When this monitor sends you an email notification, take a screenshot of the email that it sends you.
+
+* **Bonus Question**: Since this monitor is going to alert pretty often, you don’t want to be alerted when you are out of the office. Set up two scheduled downtimes for this monitor:
+
+ * One that silences it from 7pm to 9am daily on M-F,
+ * And one that silences it all day on Sat-Sun.
+ * Make sure that your email is notified when you schedule the downtime and take a screenshot of that notification.
+
+## Collecting APM Data:
+
+Given the following Flask app (or any Python/Ruby/Go app of your choice) instrument this using Datadog’s APM solution:
+
+```python
+from flask import Flask
+import logging
+import sys
+
+# Have flask use stdout as the logger
+main_logger = logging.getLogger()
+main_logger.setLevel(logging.DEBUG)
+c = logging.StreamHandler(sys.stdout)
+formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s')
+c.setFormatter(formatter)
+main_logger.addHandler(c)
+
+app = Flask(__name__)
+
+@app.route('/')
+def api_entry():
+ return 'Entrypoint to the Application'
+
+@app.route('/api/apm')
+def apm_endpoint():
+ return 'Getting APM Started'
+
+@app.route('/api/trace')
+def trace_endpoint():
+ return 'Posting Traces'
+
+if __name__ == '__main__':
+ app.run(host='0.0.0.0', port='5050')
+```
+
+* **Note**: Using both ddtrace-run and manually inserting the Middleware has been known to cause issues. Please only use one or the other.
+
+* **Bonus Question**: What is the difference between a Service and a Resource?
+
+Provide a link and a screenshot of a Dashboard with both APM and Infrastructure Metrics.
+
+Please include your fully instrumented app in your submission, as well.
+
+## Final Question:
+
+Datadog has been used in a lot of creative ways in the past. We’ve written some blog posts about using Datadog to monitor the NYC Subway System, Pokemon Go, and even office restroom availability!
+
+Is there anything creative you would use Datadog for?
+
+## Instructions
+
+If you have a question, create an issue in this repository.
+
+To submit your answers:
+
+* Fork this repo.
+* Answer the questions in answers.md
+* Commit as much code as you need to support your answers.
+* Submit a pull request.
+* Don't forget to include links to your dashboard(s), even better links and screenshots. We recommend that you include your screenshots inline with your answers.
+
+## References
+
+### How to get started with Datadog
+
+* [Datadog overview](https://docs.datadoghq.com/)
+* [Guide to graphing in Datadog](https://docs.datadoghq.com/graphing/)
+* [Guide to monitoring in Datadog](https://docs.datadoghq.com/monitors/)
+
+### The Datadog Agent and Metrics
+
+* [Guide to the Agent](https://docs.datadoghq.com/agent/)
+* [Datadog Docker-image repo](https://hub.docker.com/r/datadog/docker-dd-agent/)
+* [Writing an Agent check](https://docs.datadoghq.com/developers/write_agent_check/)
+* [Datadog API](https://docs.datadoghq.com/api/)
+
+### APM
+
+* [Datadog Tracing Docs](https://docs.datadoghq.com/tracing)
+* [Flask Introduction](http://flask.pocoo.org/docs/0.12/quickstart/)
+
+### Vagrant
+
+* [Setting Up Vagrant](https://www.vagrantup.com/intro/getting-started/)
+
+### Other questions:
+
+* [Datadog Help Center](https://help.datadoghq.com/hc/en-us)
From 5ec2029085baeb8e4ca89ca4d4987276bcc2e480 Mon Sep 17 00:00:00 2001
From: wmeleror <102828165+wmeleror@users.noreply.github.com>
Date: Sat, 2 Apr 2022 16:57:34 -0300
Subject: [PATCH 02/37] Update README.md
---
README.md | 6 ------
1 file changed, 6 deletions(-)
diff --git a/README.md b/README.md
index c62083a3d..f6b2a1b99 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,3 @@
-If you want to apply as a Solutions or Sales Engineer at [Datadog](http://datadog.com) you are in the right spot. Read on, it's fun, I promise.
-
-
-
-
-
## The Exercise
Don’t forget to read the [References](https://github.com/DataDog/hiring-engineers/blob/solutions-engineer/README.md#references)
From 945e1037acaab1ce0aa3af52123e412d2dd80ac1 Mon Sep 17 00:00:00 2001
From: wmeleror <102828165+wmeleror@users.noreply.github.com>
Date: Sat, 2 Apr 2022 16:59:11 -0300
Subject: [PATCH 03/37] Update answers.md
---
answers.md | 151 ++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 150 insertions(+), 1 deletion(-)
diff --git a/answers.md b/answers.md
index 092b6d280..a8b09702b 100644
--- a/answers.md
+++ b/answers.md
@@ -1 +1,150 @@
-Your answers to the questions go here.
+## The Exercise
+
+
+## Questions
+
+Please provide screenshots and code snippets for all steps.
+
+## Prerequisites - Setup the environment
+
+[ok] Docker container
+
+**Please make sure to use “Datadog Recruiting Candidate” in [the “Company” field](https://a.cl.ly/wbuPdEBy)**
+
+[ok] Get API-key and install agent
+
+## Collecting Metrics:
+
+* Add tags in the Agent config file and show us a screenshot of your host and its tags on the Host Map page in Datadog.
+* Install a database on your machine (MongoDB, MySQL, or PostgreSQL) and then install the respective Datadog integration for that database.
+* Create a custom Agent check that submits a metric named my_metric with a random value between 0 and 1000.
+* Change your check's collection interval so that it only submits the metric once every 45 seconds.
+* **Bonus Question** Can you change the collection interval without modifying the Python check file you created?
+
+## Visualizing Data:
+
+Utilize the Datadog API to create a Timeboard that contains:
+
+* Your custom metric scoped over your host.
+* Any metric from the Integration on your Database with the anomaly function applied.
+* Your custom metric with the rollup function applied to sum up all the points for the past hour into one bucket
+
+Please be sure, when submitting your hiring challenge, to include the script that you've used to create this Timeboard.
+
+Once this is created, access the Dashboard from your Dashboard List in the UI:
+
+* Set the Timeboard's timeframe to the past 5 minutes
+* Take a snapshot of this graph and use the @ notation to send it to yourself.
+* **Bonus Question**: What is the Anomaly graph displaying?
+
+## Monitoring Data
+
+Since you’ve already caught your test metric going above 800 once, you don’t want to have to continually watch this dashboard to be alerted when it goes above 800 again. So let’s make life easier by creating a monitor.
+
+Create a new Metric Monitor that watches the average of your custom metric (my_metric) and will alert if it’s above the following values over the past 5 minutes:
+
+* Warning threshold of 500
+* Alerting threshold of 800
+* And also ensure that it will notify you if there is No Data for this query over the past 10m.
+
+Please configure the monitor’s message so that it will:
+
+* Send you an email whenever the monitor triggers.
+* Create different messages based on whether the monitor is in an Alert, Warning, or No Data state.
+* Include the metric value that caused the monitor to trigger and host ip when the Monitor triggers an Alert state.
+* When this monitor sends you an email notification, take a screenshot of the email that it sends you.
+
+* **Bonus Question**: Since this monitor is going to alert pretty often, you don’t want to be alerted when you are out of the office. Set up two scheduled downtimes for this monitor:
+
+ * One that silences it from 7pm to 9am daily on M-F,
+ * And one that silences it all day on Sat-Sun.
+ * Make sure that your email is notified when you schedule the downtime and take a screenshot of that notification.
+
+## Collecting APM Data:
+
+Given the following Flask app (or any Python/Ruby/Go app of your choice) instrument this using Datadog’s APM solution:
+
+```python
+from flask import Flask
+import logging
+import sys
+
+# Have flask use stdout as the logger
+main_logger = logging.getLogger()
+main_logger.setLevel(logging.DEBUG)
+c = logging.StreamHandler(sys.stdout)
+formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s')
+c.setFormatter(formatter)
+main_logger.addHandler(c)
+
+app = Flask(__name__)
+
+@app.route('/')
+def api_entry():
+ return 'Entrypoint to the Application'
+
+@app.route('/api/apm')
+def apm_endpoint():
+ return 'Getting APM Started'
+
+@app.route('/api/trace')
+def trace_endpoint():
+ return 'Posting Traces'
+
+if __name__ == '__main__':
+ app.run(host='0.0.0.0', port='5050')
+```
+
+* **Note**: Using both ddtrace-run and manually inserting the Middleware has been known to cause issues. Please only use one or the other.
+
+* **Bonus Question**: What is the difference between a Service and a Resource?
+
+Provide a link and a screenshot of a Dashboard with both APM and Infrastructure Metrics.
+
+Please include your fully instrumented app in your submission, as well.
+
+## Final Question:
+
+Datadog has been used in a lot of creative ways in the past. We’ve written some blog posts about using Datadog to monitor the NYC Subway System, Pokemon Go, and even office restroom availability!
+
+Is there anything creative you would use Datadog for?
+
+## Instructions
+
+If you have a question, create an issue in this repository.
+
+To submit your answers:
+
+* Fork this repo.
+* Answer the questions in answers.md
+* Commit as much code as you need to support your answers.
+* Submit a pull request.
+* Don't forget to include links to your dashboard(s), even better links and screenshots. We recommend that you include your screenshots inline with your answers.
+
+## References
+
+### How to get started with Datadog
+
+* [Datadog overview](https://docs.datadoghq.com/)
+* [Guide to graphing in Datadog](https://docs.datadoghq.com/graphing/)
+* [Guide to monitoring in Datadog](https://docs.datadoghq.com/monitors/)
+
+### The Datadog Agent and Metrics
+
+* [Guide to the Agent](https://docs.datadoghq.com/agent/)
+* [Datadog Docker-image repo](https://hub.docker.com/r/datadog/docker-dd-agent/)
+* [Writing an Agent check](https://docs.datadoghq.com/developers/write_agent_check/)
+* [Datadog API](https://docs.datadoghq.com/api/)
+
+### APM
+
+* [Datadog Tracing Docs](https://docs.datadoghq.com/tracing)
+* [Flask Introduction](http://flask.pocoo.org/docs/0.12/quickstart/)
+
+### Vagrant
+
+* [Setting Up Vagrant](https://www.vagrantup.com/intro/getting-started/)
+
+### Other questions:
+
+* [Datadog Help Center](https://help.datadoghq.com/hc/en-us)
From b490f014dee360a26aa8651af1e1d72ca8d6c3d9 Mon Sep 17 00:00:00 2001
From: wmeleror <102828165+wmeleror@users.noreply.github.com>
Date: Sat, 2 Apr 2022 17:02:10 -0300
Subject: [PATCH 04/37] Update answers.md
---
answers.md | 33 ++-------------------------------
1 file changed, 2 insertions(+), 31 deletions(-)
diff --git a/answers.md b/answers.md
index a8b09702b..b0247d7fe 100644
--- a/answers.md
+++ b/answers.md
@@ -1,17 +1,15 @@
## The Exercise
-## Questions
-Please provide screenshots and code snippets for all steps.
## Prerequisites - Setup the environment
-[ok] Docker container
+:heavy_check_mark: Docker container
**Please make sure to use “Datadog Recruiting Candidate” in [the “Company” field](https://a.cl.ly/wbuPdEBy)**
-[ok] Get API-key and install agent
+:heavy_check_mark: Get API-key and install agent
## Collecting Metrics:
@@ -121,30 +119,3 @@ To submit your answers:
* Submit a pull request.
* Don't forget to include links to your dashboard(s), even better links and screenshots. We recommend that you include your screenshots inline with your answers.
-## References
-
-### How to get started with Datadog
-
-* [Datadog overview](https://docs.datadoghq.com/)
-* [Guide to graphing in Datadog](https://docs.datadoghq.com/graphing/)
-* [Guide to monitoring in Datadog](https://docs.datadoghq.com/monitors/)
-
-### The Datadog Agent and Metrics
-
-* [Guide to the Agent](https://docs.datadoghq.com/agent/)
-* [Datadog Docker-image repo](https://hub.docker.com/r/datadog/docker-dd-agent/)
-* [Writing an Agent check](https://docs.datadoghq.com/developers/write_agent_check/)
-* [Datadog API](https://docs.datadoghq.com/api/)
-
-### APM
-
-* [Datadog Tracing Docs](https://docs.datadoghq.com/tracing)
-* [Flask Introduction](http://flask.pocoo.org/docs/0.12/quickstart/)
-
-### Vagrant
-
-* [Setting Up Vagrant](https://www.vagrantup.com/intro/getting-started/)
-
-### Other questions:
-
-* [Datadog Help Center](https://help.datadoghq.com/hc/en-us)
From e8e93ca18c15614f1e14b654c666d5dd580949c3 Mon Sep 17 00:00:00 2001
From: wmeleror <102828165+wmeleror@users.noreply.github.com>
Date: Sat, 2 Apr 2022 17:04:39 -0300
Subject: [PATCH 05/37] Add files via upload
---
01-Host-MapTag .png | Bin 0 -> 1058095 bytes
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 01-Host-MapTag .png
diff --git a/01-Host-MapTag .png b/01-Host-MapTag .png
new file mode 100644
index 0000000000000000000000000000000000000000..1ced4b48c217d0cd29e4d19a84c443cfb3ca4278
GIT binary patch
literal 1058095
zcmaI619)Z2)-If+W81cE8y%<9amVhME4FQ09a|mSwv7%tw*J-ooPEyz?)~mRpJ%SB
zIcH(j;5$ZDn394N0xT{p2nYy*jI_842nZY`2nfVAH1HRMXc4~<1O(pLLQG6aMof%Y
z$-&mt!pZ~$L^>=f1xn+~2&V5*vMQ<;F_?;|ZN4-DF-0Jzh;SJ(EeQ;HA~vdjc$Twr
zPh$kNniGV$y}G*aqJQZ3Z|H5`HR*p;R761F(b|fFou1HbWn5(N`AlZ=I8Kg?cd&sR
zJ6)U9>8N7)@>}@vGxDc$&`=~vxPvq2!bx|-VqZeQ;!tsN!gjOHzt^{SLLz_lSdlO}
zJ$?Vsx(y-?0s$dMa0pf+84g$n1JR|A9f1QO4i;{`iv&vxABaWRpB5Q*RLv|pOro7s
zx|tNo3gl+orvw>h7u3s!@O8mUtcQiroQ}R18?I8x6NmMU2HgkoOJxeo1aVW<-E_iW
z@;w8&Gl~69T+b$0pLU1zg41{Z^jcw{HpHPZOoAFjpCWYnAvf{C=+-)#$8)A%6n21O
zU-oE#XuB^LqsoHd5W`N!E1C3t*p@=nc@tE))X+pcUyFzXgSv&;#}{Vh>o8JSpcO2S
zTsj^>QJk6a=UzbUj-`m%XIKDCdabN@_%tADLjL-fJ&RZ-&5;AU(dpB5kK5O0>(NZ{
z=)re{+E6azkFRmuBsi=XAdyiO)2eP
zt9ObF$5+TBKa%dUamPl7tVQj%=g{V-sht6uh7xQo9kdjZt*|o}itFj;S+90djfn8u
z^xKD7-8=~z7rQv^oQ<_Z3W*gWatO!Q%)V}eQtD4M2DmCm8WSgQUVI>-Y5QdVUgAb~
z?UFWT0-gBRV&l^R`)4DM?C{wg1IZLsM%a0n3f||ssSPY8(wWw?ai61>PSla#TdO>w
zdnh)%s}_YN4$y@CC8YrZqMg+QA=-y;J>GBpZBHPVc7MFweHTsvL oJi{d$k%J$`03i!C52oS7f~
z$k4<~f)?$?3B@DkmYBU=!h&tlyTzgJKU_*AG9M}if!G6*X~{?;&51V;cQsZGhvIST
zOxCnwI2!@fJ*>^GT@q_USX^M9#@8{WU{Z5p*#=(>Ql$>glePz#NyPC20+npEf8WU>
z=Bo`xZjoJsWn11_34|BBL;K0mhsrIX!hfl5%`qFmlGv>s2uo2E#}lU9^DbxRg*!w8
zd`O(*LEf+y0b(2~T=zn!`|Duo$t4N=f$OMf3&DdqlFX$I65oc+xR`KJZsXeWpH
z#QW~c*!W~m3_SotoS@&}c08q)BIFh7){7X17a){KwU5||%;D3-_B%^a+;v*J)eSXB;cw^{9<;iWS)wJ3CB}vD{x(45
zFG@`ey1=Cf;IGYWY{!EGoniAL%o+KA=Z6{WLwiAv2RoD=D*XVPX|dN@9ZnMslCn|=
z