Dropwizard is part Java framework and part Java library that assists in operating web services. The Netuitive Dropwizard integration uses a DropWizard.io netuitive
reporter to send metrics to Netuitive's Linux agent.
-
Include the appropriate Ananke library dependency. You'll also need a working StatsD (Netuitive StatsD or Etsy StatsD) integration.
-
Add
dropwizard-metrics
to your POM. There's also additional dependency formats for other build managers here.<dependency> <groupId>com.netuitive</groupId> <artifactId>dropwizard-metrics</artifactId> <version>1.0.0</version> <type>pom</type> </dependency>
-
Add the following to your Dropwizard
config.yml
file:metrics: frequency: 1 minute reporters: - type: netuitive host: netuitive-agent port: 8125
Directory | Purpose |
---|---|
src/test/docker |
Root directory for this test suite. |
src/test/docker/docker-dropwizard-example |
Dropwizard example application for testing. |
src/test/docker/docker-compose.yml |
docker-compose file used to define and launch test environment. |
- Docker version 1.10.3, build 20f81dd
docker-compose
version 1.6.2, build 4d72027- VirtualBox Version 5.0.16 r105871
dropwizard
- Example Dropwizard application with
dropwizard-metrics-netuitive
reporter (requires local gradle install to work). - Updated
config.yml
file to enablenetuitive
reporter.
- Example Dropwizard application with
netuitive-agent
- Docker Linux agent to ship data to Netuitive. Note: some environment variables need to be updated to configure the agent.
-
Run the following to start the example application and Netuitive Docker agent:
docker-compose up -d
Docker will build the dropwizard-metrics
and example project within the container from source and run the Netuitive Docker agent alongside it.
-
Change to the test docker directory, which contains a test stack definition for testing.
cd src/test/docker;
-
In that directory run:
docker-compose up -d --build
-
Now create and run your tests:
./run_tests.sh
-
Now shut down the stack:
docker-compose stop