forked from beberlei/metrics
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
28 changed files
with
474 additions
and
420 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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
composer.lock | ||
vendor | ||
/composer.lock | ||
/vendor/ |
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 |
---|---|---|
|
@@ -5,6 +5,7 @@ php: | |
- 5.4 | ||
- 5.5 | ||
- 5.6 | ||
- hhvm | ||
|
||
before_script: | ||
- composer install --dev --prefer-source |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
Upgrade from 1.x to 2.0 | ||
======================= | ||
|
||
* [BC BREAK] Collector `Beberlei\Metrics\Collector\Monolog` is renamed to `Beberlei\Metrics\Collector\Logger`. | ||
|
||
* [BC BREAK] Collector `Beberlei\Metrics\Collector\Monolog` takes a `Psr\Log\LoggerInterface`. | ||
|
||
* [BC BREAK] The bundle does not rely on `Beberlei\Metrics\Factory` and `Beberlei\Metrics\Registry` anymore. | ||
|
||
* [BC BREAK] The bundle configuration has a new "standard" key mapping. The | ||
`hostname` key for `Librato` is now `source`. The `hostname` key for `Zabbix` is | ||
now `prefix`. `hostname`, and `servername` are now `host`. `serverport` is now | ||
`port`. | ||
|
||
* [BC BREAK] The `Registry` is removed. | ||
|
||
* [BC BREAK] The `functions.php` is removed. |
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 |
---|---|---|
|
@@ -3,13 +3,25 @@ | |
"description": "Simple library to talk to metrics collector services.", | ||
"keywords": ["metrics", "logging"], | ||
"authors": [ | ||
{"name": "Benjamin Eberlei", "email": "[email protected]"} | ||
{ | ||
"name": "Benjamin Eberlei", | ||
"email": "[email protected]", | ||
"role": "Project Founder" | ||
}, | ||
{ | ||
"name": "Grégoire Pineau", | ||
"email": "[email protected]", | ||
"role": "Lead Developer" | ||
} | ||
], | ||
"license": "MIT", | ||
"suggest": { | ||
"okitsu/zabbix-sender": "For zabbix integration", | ||
"kriswallsmith/buzz": "For Librato integration" | ||
}, | ||
"require": { | ||
"psr/log": "~1.0" | ||
}, | ||
"require-dev": { | ||
"doctrine/dbal": "~2.0", | ||
"kriswallsmith/buzz": "*", | ||
|
@@ -20,15 +32,14 @@ | |
"symfony/http-kernel": "~2.3" | ||
}, | ||
"autoload": { | ||
"psr-0": { | ||
"Beberlei\\Metrics": "src/", | ||
"Beberlei\\Bundle\\MetricsBundle": "src/" | ||
}, | ||
"files": ["src/Beberlei/Metrics/functions.php"] | ||
"psr-4": { | ||
"Beberlei\\Metrics\\": "src/Beberlei/Metrics", | ||
"Beberlei\\Bundle\\MetricsBundle\\": "src/Beberlei/Bundle/MetricsBundle" | ||
} | ||
}, | ||
"extra": { | ||
"branch-alias": { | ||
"dev-master": "1.x-dev" | ||
"dev-master": "2.x-dev" | ||
} | ||
} | ||
} |
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 |
---|---|---|
@@ -1,13 +1,13 @@ | ||
<?php | ||
|
||
require_once __DIR__ . "/../vendor/autoload.php"; | ||
require_once __DIR__.'/../vendor/autoload.php'; | ||
|
||
$metrics = \Beberlei\Metrics\Factory::create('statsd'); | ||
|
||
while (true) { | ||
$metrics->increment('foo.bar'); | ||
$metrics->decrement('foo.baz'); | ||
$metrics->measure('foo', rand(1, 10)); | ||
$metrics->flush(); | ||
usleep(500); | ||
} | ||
|
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
Oops, something went wrong.