-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Create a CHANGELOG.md file - Add benchmark.cr to examples - Update README.md - Update Makefile for current targets
- Loading branch information
1 parent
135effc
commit 8074237
Showing
6 changed files
with
43 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Change Log | ||
|
||
All notable changes to this project will be documented in this file. | ||
This project aims to adhere to [Semantic Versioning](http://semver.org/). | ||
|
||
# 0.1.0 / 2016-04-01 | ||
|
||
- Initial release, supporting all statsd spec & extended spec for histograms and tags. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
require "benchmark" | ||
require "../src/statsd.cr" | ||
|
||
Benchmark.ips do |x| | ||
statsd = Statsd::Client.new | ||
|
||
x.report("increments") { statsd.increment "page.views" } | ||
x.report("increments w/tags") { statsd.increment "page.views", tags: ["foo:bar"] } | ||
x.report("decrements") { statsd.decrement "page.views" } | ||
x.report("gauges") { statsd.gauge("users.current", 5) } | ||
x.report("gauges w/tags") { statsd.gauge("users.current", 5, tags: ["foo:bar"]) } | ||
x.report("timing") { statsd.timing("db.query", 100) } | ||
x.report("time") { statsd.time("timed.block") { true } } | ||
end |