Updating vendors.

1.9.x
Julio Montoya 11 years ago
parent a42b77f685
commit 9c33ca0b2a
  1. 28
      composer.lock
  2. 2
      vendor/autoload.php
  3. 1
      vendor/composer/autoload_namespaces.php
  4. 1
      vendor/composer/autoload_psr4.php
  5. 8
      vendor/composer/autoload_real.php
  6. 588
      vendor/composer/installed.json
  7. 13
      vendor/doctrine/cache/.travis.yml
  8. 0
      vendor/doctrine/cache/LICENSE
  9. 0
      vendor/doctrine/cache/README.md
  10. 2
      vendor/doctrine/cache/composer.json
  11. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/ApcCache.php
  12. 4
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/ArrayCache.php
  13. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/Cache.php
  14. 6
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/CacheProvider.php
  15. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/CouchbaseCache.php
  16. 2
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/FileCache.php
  17. 16
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/FilesystemCache.php
  18. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/MemcacheCache.php
  19. 3
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/MemcachedCache.php
  20. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/PhpFileCache.php
  21. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/RedisCache.php
  22. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/RiakCache.php
  23. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/WinCacheCache.php
  24. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/XcacheCache.php
  25. 0
      vendor/doctrine/cache/lib/Doctrine/Common/Cache/ZendDataCache.php
  26. 6
      vendor/doctrine/cache/phpunit.xml.dist
  27. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ApcCacheTest.php
  28. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ArrayCacheTest.php
  29. 1
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CacheTest.php
  30. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/CouchbaseCacheTest.php
  31. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FileCacheTest.php
  32. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/FilesystemCacheTest.php
  33. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php
  34. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/MemcachedCacheTest.php
  35. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/PhpFileCacheTest.php
  36. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RedisCacheTest.php
  37. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/RiakCacheTest.php
  38. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/WinCacheCacheTest.php
  39. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/XcacheCacheTest.php
  40. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/Common/Cache/ZendDataCacheTest.php
  41. 0
      vendor/doctrine/cache/tests/Doctrine/Tests/DoctrineTestCase.php
  42. 4
      vendor/doctrine/cache/tests/Doctrine/Tests/TestInit.php
  43. 25
      vendor/monolog/monolog/CHANGELOG.mdown
  44. 2
      vendor/monolog/monolog/LICENSE
  45. 12
      vendor/monolog/monolog/README.mdown
  46. 9
      vendor/monolog/monolog/composer.json
  47. 0
      vendor/monolog/monolog/doc/extending.md
  48. 0
      vendor/monolog/monolog/doc/sockets.md
  49. 0
      vendor/monolog/monolog/doc/usage.md
  50. 0
      vendor/monolog/monolog/phpunit.xml.dist
  51. 4
      vendor/monolog/monolog/src/Monolog/ErrorHandler.php
  52. 0
      vendor/monolog/monolog/src/Monolog/Formatter/ChromePHPFormatter.php
  53. 0
      vendor/monolog/monolog/src/Monolog/Formatter/FormatterInterface.php
  54. 0
      vendor/monolog/monolog/src/Monolog/Formatter/GelfMessageFormatter.php
  55. 27
      vendor/monolog/monolog/src/Monolog/Formatter/HtmlFormatter.php
  56. 0
      vendor/monolog/monolog/src/Monolog/Formatter/JsonFormatter.php
  57. 27
      vendor/monolog/monolog/src/Monolog/Formatter/LineFormatter.php
  58. 2
      vendor/monolog/monolog/src/Monolog/Formatter/LogglyFormatter.php
  59. 0
      vendor/monolog/monolog/src/Monolog/Formatter/LogstashFormatter.php
  60. 3
      vendor/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php
  61. 0
      vendor/monolog/monolog/src/Monolog/Formatter/WildfireFormatter.php
  62. 4
      vendor/monolog/monolog/src/Monolog/Handler/AbstractHandler.php
  63. 0
      vendor/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php
  64. 61
      vendor/monolog/monolog/src/Monolog/Handler/AmqpHandler.php
  65. 19
      vendor/monolog/monolog/src/Monolog/Handler/BufferHandler.php
  66. 12
      vendor/monolog/monolog/src/Monolog/Handler/ChromePHPHandler.php
  67. 0
      vendor/monolog/monolog/src/Monolog/Handler/CouchDBHandler.php
  68. 0
      vendor/monolog/monolog/src/Monolog/Handler/CubeHandler.php
  69. 0
      vendor/monolog/monolog/src/Monolog/Handler/DoctrineCouchDBHandler.php
  70. 20
      vendor/monolog/monolog/src/Monolog/Handler/ErrorLogHandler.php
  71. 19
      vendor/monolog/monolog/src/Monolog/Handler/FilterHandler.php
  72. 0
      vendor/monolog/monolog/src/Monolog/Handler/FingersCrossed/ActivationStrategyInterface.php
  73. 10
      vendor/monolog/monolog/src/Monolog/Handler/FingersCrossed/ChannelLevelActivationStrategy.php
  74. 4
      vendor/monolog/monolog/src/Monolog/Handler/FingersCrossed/ErrorLevelActivationStrategy.php
  75. 33
      vendor/monolog/monolog/src/Monolog/Handler/FingersCrossedHandler.php
  76. 0
      vendor/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php
  77. 2
      vendor/monolog/monolog/src/Monolog/Handler/FlowdockHandler.php
  78. 0
      vendor/monolog/monolog/src/Monolog/Handler/GelfHandler.php
  79. 0
      vendor/monolog/monolog/src/Monolog/Handler/GroupHandler.php
  80. 0
      vendor/monolog/monolog/src/Monolog/Handler/HandlerInterface.php
  81. 3
      vendor/monolog/monolog/src/Monolog/Handler/HipChatHandler.php
  82. 5
      vendor/monolog/monolog/src/Monolog/Handler/LogglyHandler.php
  83. 0
      vendor/monolog/monolog/src/Monolog/Handler/MailHandler.php
  84. 0
      vendor/monolog/monolog/src/Monolog/Handler/MissingExtensionException.php
  85. 0
      vendor/monolog/monolog/src/Monolog/Handler/MongoDBHandler.php
  86. 4
      vendor/monolog/monolog/src/Monolog/Handler/NativeMailerHandler.php
  87. 6
      vendor/monolog/monolog/src/Monolog/Handler/NewRelicHandler.php
  88. 0
      vendor/monolog/monolog/src/Monolog/Handler/NullHandler.php
  89. 10
      vendor/monolog/monolog/src/Monolog/Handler/PushoverHandler.php
  90. 2
      vendor/monolog/monolog/src/Monolog/Handler/RavenHandler.php
  91. 0
      vendor/monolog/monolog/src/Monolog/Handler/RedisHandler.php
  92. 9
      vendor/monolog/monolog/src/Monolog/Handler/RollbarHandler.php
  93. 15
      vendor/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php
  94. 2
      vendor/monolog/monolog/src/Monolog/Handler/SocketHandler.php
  95. 29
      vendor/monolog/monolog/src/Monolog/Handler/StreamHandler.php
  96. 1
      vendor/monolog/monolog/src/Monolog/Handler/SwiftMailerHandler.php
  97. 0
      vendor/monolog/monolog/src/Monolog/Handler/SyslogHandler.php
  98. 0
      vendor/monolog/monolog/src/Monolog/Handler/TestHandler.php
  99. 0
      vendor/monolog/monolog/src/Monolog/Handler/ZendMonitorHandler.php
  100. 31
      vendor/monolog/monolog/src/Monolog/Logger.php
  101. Some files were not shown because too many files have changed in this diff Show More

28
composer.lock generated

@ -393,16 +393,16 @@
},
{
"name": "sabre/vobject",
"version": "3.3.2",
"version": "3.3.3",
"source": {
"type": "git",
"url": "https://github.com/fruux/sabre-vobject.git",
"reference": "2a5c49e706454d437a9e25bdb39583a18d470399"
"reference": "de508f160e811c09b5e651909eb20b9e058a043c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/fruux/sabre-vobject/zipball/2a5c49e706454d437a9e25bdb39583a18d470399",
"reference": "2a5c49e706454d437a9e25bdb39583a18d470399",
"url": "https://api.github.com/repos/fruux/sabre-vobject/zipball/de508f160e811c09b5e651909eb20b9e058a043c",
"reference": "de508f160e811c09b5e651909eb20b9e058a043c",
"shasum": ""
},
"require": {
@ -435,9 +435,15 @@
"authors": [
{
"name": "Evert Pot",
"email": "evert@rooftopsolutions.nl",
"email": "me@evertpot.com",
"homepage": "http://evertpot.com/",
"role": "Developer"
},
{
"name": "Dominik Tobschall",
"email": "dominik@fruux.com",
"homepage": "http://tobschall.de/",
"role": "Developer"
}
],
"description": "The VObject library for PHP allows you to easily parse and manipulate iCalendar and vCard objects",
@ -449,7 +455,7 @@
"jCard",
"vCard"
],
"time": "2014-09-19 18:54:29"
"time": "2014-10-09 15:59:25"
},
{
"name": "symfony/console",
@ -769,16 +775,16 @@
},
{
"name": "twig/twig",
"version": "v1.16.0",
"version": "v1.16.1",
"source": {
"type": "git",
"url": "https://github.com/fabpot/Twig.git",
"reference": "8ce37115802e257a984a82d38254884085060024"
"reference": "7c4c01dcf578523cfcddf383641a4f12790270ec"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/fabpot/Twig/zipball/8ce37115802e257a984a82d38254884085060024",
"reference": "8ce37115802e257a984a82d38254884085060024",
"url": "https://api.github.com/repos/fabpot/Twig/zipball/7c4c01dcf578523cfcddf383641a4f12790270ec",
"reference": "7c4c01dcf578523cfcddf383641a4f12790270ec",
"shasum": ""
},
"require": {
@ -822,7 +828,7 @@
"keywords": [
"templating"
],
"time": "2014-07-05 12:19:05"
"time": "2014-10-10 14:09:53"
}
],
"packages-dev": [],

@ -4,4 +4,4 @@
require_once __DIR__ . '/composer' . '/autoload_real.php';
return ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925::getLoader();
return ComposerAutoloaderInitac8e77d2000c46c1bba3290d30b50b49::getLoader();

@ -11,7 +11,6 @@ return array(
'Symfony\\Component\\Process\\' => array($vendorDir . '/symfony/process'),
'Symfony\\Component\\Filesystem\\' => array($vendorDir . '/symfony/filesystem'),
'Symfony\\Component\\Console\\' => array($vendorDir . '/symfony/console'),
'Sabre\\VObject' => array($vendorDir . '/sabre/vobject/lib'),
'Psr\\Log\\' => array($vendorDir . '/psr/log'),
'Neutron' => array($vendorDir . '/neutron/temporary-filesystem/src'),
'HttpAdapter' => array($vendorDir . '/toin0u/http-adapter/src'),

@ -6,5 +6,6 @@ $vendorDir = dirname(dirname(__FILE__));
$baseDir = dirname($vendorDir);
return array(
'Sabre\\VObject\\' => array($vendorDir . '/sabre/vobject/lib'),
'Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'),
);

@ -2,7 +2,7 @@
// autoload_real.php @generated by Composer
class ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925
class ComposerAutoloaderInitac8e77d2000c46c1bba3290d30b50b49
{
private static $loader;
@ -19,9 +19,9 @@ class ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925
return self::$loader;
}
spl_autoload_register(array('ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInitac8e77d2000c46c1bba3290d30b50b49', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
spl_autoload_unregister(array('ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInitac8e77d2000c46c1bba3290d30b50b49', 'loadClassLoader'));
$map = require __DIR__ . '/autoload_namespaces.php';
foreach ($map as $namespace => $path) {
@ -44,7 +44,7 @@ class ComposerAutoloaderInitc5ab5de8e41a56849cc6a794eb539925
}
}
function composerRequirec5ab5de8e41a56849cc6a794eb539925($file)
function composerRequireac8e77d2000c46c1bba3290d30b50b49($file)
{
require $file;
}

@ -41,82 +41,6 @@
"event-dispatcher"
]
},
{
"name": "doctrine/cache",
"version": "v1.3.0",
"version_normalized": "1.3.0.0",
"source": {
"type": "git",
"url": "https://github.com/doctrine/cache.git",
"reference": "e16d7adf45664a50fa86f515b6d5e7f670130449"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/doctrine/cache/zipball/e16d7adf45664a50fa86f515b6d5e7f670130449",
"reference": "e16d7adf45664a50fa86f515b6d5e7f670130449",
"shasum": ""
},
"require": {
"php": ">=5.3.2"
},
"conflict": {
"doctrine/common": ">2.2,<2.4"
},
"require-dev": {
"phpunit/phpunit": ">=3.7",
"satooshi/php-coveralls": "~0.6"
},
"time": "2013-10-25 19:04:14",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0.x-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"Doctrine\\Common\\Cache\\": "lib/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Jonathan H. Wage",
"email": "jonwage@gmail.com",
"homepage": "http://www.jwage.com/",
"role": "Creator"
},
{
"name": "Guilherme Blanco",
"email": "guilhermeblanco@gmail.com",
"homepage": "http://www.instaclick.com"
},
{
"name": "Roman Borschel",
"email": "roman@code-factory.org"
},
{
"name": "Benjamin Eberlei",
"email": "kontakt@beberlei.de"
},
{
"name": "Johannes Schmitt",
"email": "schmittjoh@gmail.com",
"homepage": "http://jmsyst.com",
"role": "Developer of wrapped JMSSerializerBundle"
}
],
"description": "Caching library offering an object-oriented API for many cache backends",
"homepage": "http://www.doctrine-project.org",
"keywords": [
"cache",
"caching"
]
},
{
"name": "psr/log",
"version": "1.0.0",
@ -288,53 +212,88 @@
]
},
{
"name": "monolog/monolog",
"version": "1.9.1",
"version_normalized": "1.9.1.0",
"name": "neutron/temporary-filesystem",
"version": "2.1.1",
"version_normalized": "2.1.1.0",
"source": {
"type": "git",
"url": "https://github.com/Seldaek/monolog.git",
"reference": "65026b610f8c19e61d7242f600530677b0466aac"
"url": "https://github.com/romainneutron/Temporary-Filesystem.git",
"reference": "6b21fa99fd452efea16b9a7adb7304ccfff854d0"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/Seldaek/monolog/zipball/65026b610f8c19e61d7242f600530677b0466aac",
"reference": "65026b610f8c19e61d7242f600530677b0466aac",
"url": "https://api.github.com/repos/romainneutron/Temporary-Filesystem/zipball/6b21fa99fd452efea16b9a7adb7304ccfff854d0",
"reference": "6b21fa99fd452efea16b9a7adb7304ccfff854d0",
"shasum": ""
},
"require": {
"php": ">=5.3.0",
"psr/log": "~1.0"
"symfony/filesystem": "~2.0"
},
"require-dev": {
"aws/aws-sdk-php": "~2.4, >2.4.8",
"doctrine/couchdb": "~1.0@dev",
"graylog2/gelf-php": "~1.0",
"phpunit/phpunit": "~3.7.0",
"raven/raven": "~0.5",
"ruflin/elastica": "0.90.*"
"phpunit/phpunit": "~3.7"
},
"time": "2013-10-10 10:58:09",
"type": "library",
"installation-source": "dist",
"autoload": {
"psr-0": {
"Neutron": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Romain Neutron",
"email": "imprec@gmail.com",
"homepage": "http://www.lickmychip.com/"
}
],
"description": "Symfony filesystem extension to handle temporary files"
},
{
"name": "toin0u/http-adapter",
"version": "1.0.3",
"version_normalized": "1.0.3.0",
"source": {
"type": "git",
"url": "https://github.com/toin0u/HttpAdapter.git",
"reference": "29253948d446bc3afc29897ac67b4cd01f56cd10"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/toin0u/HttpAdapter/zipball/29253948d446bc3afc29897ac67b4cd01f56cd10",
"reference": "29253948d446bc3afc29897ac67b4cd01f56cd10",
"shasum": ""
},
"require": {
"ext-curl": "*",
"php": ">=5.3.0"
},
"require-dev": {
"guzzle/guzzle": "@stable",
"kriswallsmith/buzz": "@stable",
"satooshi/php-coveralls": "~0.6",
"zendframework/zendframework": "~2.1"
},
"suggest": {
"aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB",
"doctrine/couchdb": "Allow sending log messages to a CouchDB server",
"ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)",
"ext-mongo": "Allow sending log messages to a MongoDB server",
"graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server",
"raven/raven": "Allow sending log messages to a Sentry server",
"rollbar/rollbar": "Allow sending log messages to Rollbar",
"ruflin/elastica": "Allow sending log messages to an Elastic Search server"
"guzzle/guzzle": "Enabling Guzzle allows you to use the GuzzleHttpAdapter",
"kriswallsmith/buzz": "Enabling Buzz allows you to use the BuzzHttpAdapter",
"zendframework/zendframework": "Enabling Zend Http allows you to use the ZendHttpAdapter"
},
"time": "2014-04-24 13:29:03",
"time": "2013-05-26 18:18:11",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.9.x-dev"
"dev-master": "1.0-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-4": {
"Monolog\\": "src/Monolog"
"psr-0": {
"HttpAdapter": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
@ -343,47 +302,57 @@
],
"authors": [
{
"name": "Jordi Boggiano",
"email": "j.boggiano@seld.be",
"homepage": "http://seld.be",
"name": "Antoine Corcy",
"email": "contact@sbin.dk",
"homepage": "http://sbin.dk",
"role": "Developer"
}
],
"description": "Sends your logs to files, sockets, inboxes, databases and various web services",
"homepage": "http://github.com/Seldaek/monolog",
"description": "HttpAdapter PHP 5.3+ library",
"homepage": "https://github.com/toin0u/HttpAdapter",
"keywords": [
"log",
"logging",
"psr-3"
"adapter",
"http"
]
},
{
"name": "neutron/temporary-filesystem",
"version": "2.1.1",
"version_normalized": "2.1.1.0",
"name": "toin0u/digitalocean",
"version": "1.4.2",
"version_normalized": "1.4.2.0",
"source": {
"type": "git",
"url": "https://github.com/romainneutron/Temporary-Filesystem.git",
"reference": "6b21fa99fd452efea16b9a7adb7304ccfff854d0"
"url": "https://github.com/toin0u/DigitalOcean.git",
"reference": "fb460785207fa4029217eef489508b9ed6c61b00"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/romainneutron/Temporary-Filesystem/zipball/6b21fa99fd452efea16b9a7adb7304ccfff854d0",
"reference": "6b21fa99fd452efea16b9a7adb7304ccfff854d0",
"url": "https://api.github.com/repos/toin0u/DigitalOcean/zipball/fb460785207fa4029217eef489508b9ed6c61b00",
"reference": "fb460785207fa4029217eef489508b9ed6c61b00",
"shasum": ""
},
"require": {
"symfony/filesystem": "~2.0"
"php": ">=5.3.0",
"symfony/console": "~2.3",
"symfony/yaml": "~2.3",
"toin0u/http-adapter": "~1.0"
},
"require-dev": {
"phpunit/phpunit": "~3.7"
"satooshi/php-coveralls": "~0.6"
},
"time": "2013-10-10 10:58:09",
"time": "2014-01-14 22:20:56",
"bin": [
"digitalocean"
],
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.4-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"Neutron": "src"
"DigitalOcean": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
@ -392,94 +361,113 @@
],
"authors": [
{
"name": "Romain Neutron",
"email": "imprec@gmail.com",
"homepage": "http://www.lickmychip.com/"
"name": "Antoine Corcy",
"email": "contact@sbin.dk",
"homepage": "http://sbin.dk",
"role": "Developer"
}
],
"description": "Symfony filesystem extension to handle temporary files"
"description": "DigitalOcean API PHP 5.3+ library",
"homepage": "https://github.com/toin0u/DigitalOcean",
"keywords": [
"Cloud Hosting",
"SSD",
"api",
"digitalocean",
"vps"
]
},
{
"name": "sabre/vobject",
"version": "3.2.2",
"version_normalized": "3.2.2.0",
"name": "doctrine/cache",
"version": "v1.3.1",
"version_normalized": "1.3.1.0",
"source": {
"type": "git",
"url": "https://github.com/fruux/sabre-vobject.git",
"reference": "a829266cebcaccf602bde3af2c7e85a952034a16"
"url": "https://github.com/doctrine/cache.git",
"reference": "cf483685798a72c93bf4206e3dd6358ea07d64e7"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/fruux/sabre-vobject/zipball/a829266cebcaccf602bde3af2c7e85a952034a16",
"reference": "a829266cebcaccf602bde3af2c7e85a952034a16",
"url": "https://api.github.com/repos/doctrine/cache/zipball/cf483685798a72c93bf4206e3dd6358ea07d64e7",
"reference": "cf483685798a72c93bf4206e3dd6358ea07d64e7",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
"php": ">=5.3.1"
"php": ">=5.3.2"
},
"conflict": {
"doctrine/common": ">2.2,<2.4"
},
"require-dev": {
"phpunit/phpunit": "*"
"phpunit/phpunit": ">=3.7",
"satooshi/php-coveralls": "~0.6"
},
"time": "2014-05-07 20:02:21",
"bin": [
"bin/vobject",
"bin/generate_vcards"
],
"time": "2014-09-17 14:24:04",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "3.2.x-dev"
"dev-master": "1.4.x-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"Sabre\\VObject": "lib/"
"Doctrine\\Common\\Cache\\": "lib/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
"MIT"
],
"authors": [
{
"name": "Evert Pot",
"email": "evert@rooftopsolutions.nl",
"homepage": "http://evertpot.com/",
"role": "Developer"
"name": "Roman Borschel",
"email": "roman@code-factory.org"
},
{
"name": "Benjamin Eberlei",
"email": "kontakt@beberlei.de"
},
{
"name": "Guilherme Blanco",
"email": "guilhermeblanco@gmail.com"
},
{
"name": "Jonathan Wage",
"email": "jonwage@gmail.com"
},
{
"name": "Johannes Schmitt",
"email": "schmittjoh@gmail.com"
}
],
"description": "The VObject library for PHP allows you to easily parse and manipulate iCalendar and vCard objects",
"homepage": "https://github.com/fruux/sabre-vobject",
"description": "Caching library offering an object-oriented API for many cache backends",
"homepage": "http://www.doctrine-project.org",
"keywords": [
"VObject",
"iCalendar",
"jCal",
"jCard",
"vCard"
"cache",
"caching"
]
},
{
"name": "symfony/filesystem",
"version": "v2.5.0",
"version_normalized": "2.5.0.0",
"version": "v2.5.5",
"version_normalized": "2.5.5.0",
"target-dir": "Symfony/Component/Filesystem",
"source": {
"type": "git",
"url": "https://github.com/symfony/Filesystem.git",
"reference": "98e831eac836a0a5911626ce82684155f21d0e4d"
"reference": "4e62fab0060a826561c78b665925b37c870c45f5"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Filesystem/zipball/98e831eac836a0a5911626ce82684155f21d0e4d",
"reference": "98e831eac836a0a5911626ce82684155f21d0e4d",
"url": "https://api.github.com/repos/symfony/Filesystem/zipball/4e62fab0060a826561c78b665925b37c870c45f5",
"reference": "4e62fab0060a826561c78b665925b37c870c45f5",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
"time": "2014-04-16 10:36:21",
"time": "2014-09-22 09:14:18",
"type": "library",
"extra": {
"branch-alias": {
@ -497,40 +485,46 @@
"MIT"
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com",
"homepage": "http://fabien.potencier.org",
"role": "Lead Developer"
},
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "Symfony Filesystem Component",
"homepage": "http://symfony.com"
},
{
"name": "symfony/process",
"version": "v2.5.0",
"version_normalized": "2.5.0.0",
"target-dir": "Symfony/Component/Process",
"name": "symfony/console",
"version": "v2.5.5",
"version_normalized": "2.5.5.0",
"target-dir": "Symfony/Component/Console",
"source": {
"type": "git",
"url": "https://github.com/symfony/Process.git",
"reference": "5d7d78e23894544740219e006320678cfa4cd45b"
"url": "https://github.com/symfony/Console.git",
"reference": "ca053eaa031c93afb68a71e4eb1f4168dfd4a661"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Process/zipball/5d7d78e23894544740219e006320678cfa4cd45b",
"reference": "5d7d78e23894544740219e006320678cfa4cd45b",
"url": "https://api.github.com/repos/symfony/Console/zipball/ca053eaa031c93afb68a71e4eb1f4168dfd4a661",
"reference": "ca053eaa031c93afb68a71e4eb1f4168dfd4a661",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
"time": "2014-05-23 09:02:52",
"require-dev": {
"psr/log": "~1.0",
"symfony/event-dispatcher": "~2.1"
},
"suggest": {
"psr/log": "For using the console logger",
"symfony/event-dispatcher": ""
},
"time": "2014-09-25 09:53:56",
"type": "library",
"extra": {
"branch-alias": {
@ -540,7 +534,7 @@
"installation-source": "dist",
"autoload": {
"psr-0": {
"Symfony\\Component\\Process\\": ""
"Symfony\\Component\\Console\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
@ -548,61 +542,48 @@
"MIT"
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com",
"homepage": "http://fabien.potencier.org",
"role": "Lead Developer"
},
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "Symfony Process Component",
"description": "Symfony Console Component",
"homepage": "http://symfony.com"
},
{
"name": "toin0u/http-adapter",
"version": "1.0.3",
"version_normalized": "1.0.3.0",
"name": "symfony/yaml",
"version": "v2.5.5",
"version_normalized": "2.5.5.0",
"target-dir": "Symfony/Component/Yaml",
"source": {
"type": "git",
"url": "https://github.com/toin0u/HttpAdapter.git",
"reference": "29253948d446bc3afc29897ac67b4cd01f56cd10"
"url": "https://github.com/symfony/Yaml.git",
"reference": "b1dbc53593b98c2d694ebf383660ac9134d30b96"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/toin0u/HttpAdapter/zipball/29253948d446bc3afc29897ac67b4cd01f56cd10",
"reference": "29253948d446bc3afc29897ac67b4cd01f56cd10",
"url": "https://api.github.com/repos/symfony/Yaml/zipball/b1dbc53593b98c2d694ebf383660ac9134d30b96",
"reference": "b1dbc53593b98c2d694ebf383660ac9134d30b96",
"shasum": ""
},
"require": {
"ext-curl": "*",
"php": ">=5.3.0"
},
"require-dev": {
"guzzle/guzzle": "@stable",
"kriswallsmith/buzz": "@stable",
"satooshi/php-coveralls": "~0.6",
"zendframework/zendframework": "~2.1"
},
"suggest": {
"guzzle/guzzle": "Enabling Guzzle allows you to use the GuzzleHttpAdapter",
"kriswallsmith/buzz": "Enabling Buzz allows you to use the BuzzHttpAdapter",
"zendframework/zendframework": "Enabling Zend Http allows you to use the ZendHttpAdapter"
"php": ">=5.3.3"
},
"time": "2013-05-26 18:18:11",
"time": "2014-09-22 09:14:18",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
"dev-master": "2.5-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"HttpAdapter": "src/"
"Symfony\\Component\\Yaml\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
@ -611,57 +592,70 @@
],
"authors": [
{
"name": "Antoine Corcy",
"email": "contact@sbin.dk",
"homepage": "http://sbin.dk",
"role": "Developer"
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "HttpAdapter PHP 5.3+ library",
"homepage": "https://github.com/toin0u/HttpAdapter",
"keywords": [
"adapter",
"http"
]
"description": "Symfony Yaml Component",
"homepage": "http://symfony.com"
},
{
"name": "symfony/console",
"version": "v2.5.0",
"version_normalized": "2.5.0.0",
"target-dir": "Symfony/Component/Console",
"name": "monolog/monolog",
"version": "1.11.0",
"version_normalized": "1.11.0.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/Console.git",
"reference": "ef4ca73b0b3a10cbac653d3ca482d0cdd4502b2c"
"url": "https://github.com/Seldaek/monolog.git",
"reference": "ec3961874c43840e96da3a8a1ed20d8c73d7e5aa"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Console/zipball/ef4ca73b0b3a10cbac653d3ca482d0cdd4502b2c",
"reference": "ef4ca73b0b3a10cbac653d3ca482d0cdd4502b2c",
"url": "https://api.github.com/repos/Seldaek/monolog/zipball/ec3961874c43840e96da3a8a1ed20d8c73d7e5aa",
"reference": "ec3961874c43840e96da3a8a1ed20d8c73d7e5aa",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
"php": ">=5.3.0",
"psr/log": "~1.0"
},
"provide": {
"psr/log-implementation": "1.0.0"
},
"require-dev": {
"psr/log": "~1.0",
"symfony/event-dispatcher": "~2.1"
"aws/aws-sdk-php": "~2.4, >2.4.8",
"doctrine/couchdb": "~1.0@dev",
"graylog2/gelf-php": "~1.0",
"phpunit/phpunit": "~3.7.0",
"raven/raven": "~0.5",
"ruflin/elastica": "0.90.*",
"videlalvaro/php-amqplib": "~2.4"
},
"suggest": {
"psr/log": "For using the console logger",
"symfony/event-dispatcher": ""
"aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB",
"doctrine/couchdb": "Allow sending log messages to a CouchDB server",
"ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)",
"ext-mongo": "Allow sending log messages to a MongoDB server",
"graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server",
"raven/raven": "Allow sending log messages to a Sentry server",
"rollbar/rollbar": "Allow sending log messages to Rollbar",
"ruflin/elastica": "Allow sending log messages to an Elastic Search server",
"videlalvaro/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib"
},
"time": "2014-05-22 08:54:24",
"time": "2014-09-30 13:30:58",
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "2.5-dev"
"dev-master": "1.11.x-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"Symfony\\Component\\Console\\": ""
"psr-4": {
"Monolog\\": "src/Monolog"
}
},
"notification-url": "https://packagist.org/downloads/",
@ -670,39 +664,39 @@
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com",
"homepage": "http://fabien.potencier.org",
"role": "Lead Developer"
},
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
"name": "Jordi Boggiano",
"email": "j.boggiano@seld.be",
"homepage": "http://seld.be"
}
],
"description": "Symfony Console Component",
"homepage": "http://symfony.com"
"description": "Sends your logs to files, sockets, inboxes, databases and various web services",
"homepage": "http://github.com/Seldaek/monolog",
"keywords": [
"log",
"logging",
"psr-3"
]
},
{
"name": "symfony/yaml",
"version": "v2.5.0",
"version_normalized": "2.5.0.0",
"target-dir": "Symfony/Component/Yaml",
"name": "symfony/process",
"version": "v2.5.5",
"version_normalized": "2.5.5.0",
"target-dir": "Symfony/Component/Process",
"source": {
"type": "git",
"url": "https://github.com/symfony/Yaml.git",
"reference": "b4b09c68ec2f2727574544ef0173684281a5033c"
"url": "https://github.com/symfony/Process.git",
"reference": "8a1ec96c4e519cee0fb971ea48a1eb7369dda54b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Yaml/zipball/b4b09c68ec2f2727574544ef0173684281a5033c",
"reference": "b4b09c68ec2f2727574544ef0173684281a5033c",
"url": "https://api.github.com/repos/symfony/Process/zipball/8a1ec96c4e519cee0fb971ea48a1eb7369dda54b",
"reference": "8a1ec96c4e519cee0fb971ea48a1eb7369dda54b",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
"time": "2014-05-16 14:25:18",
"time": "2014-09-23 05:25:11",
"type": "library",
"extra": {
"branch-alias": {
@ -712,7 +706,7 @@
"installation-source": "dist",
"autoload": {
"psr-0": {
"Symfony\\Component\\Yaml\\": ""
"Symfony\\Component\\Process\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
@ -720,101 +714,105 @@
"MIT"
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com",
"homepage": "http://fabien.potencier.org",
"role": "Lead Developer"
},
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "Symfony Yaml Component",
"description": "Symfony Process Component",
"homepage": "http://symfony.com"
},
{
"name": "toin0u/digitalocean",
"version": "1.4.2",
"version_normalized": "1.4.2.0",
"name": "sabre/vobject",
"version": "3.3.3",
"version_normalized": "3.3.3.0",
"source": {
"type": "git",
"url": "https://github.com/toin0u/DigitalOcean.git",
"reference": "fb460785207fa4029217eef489508b9ed6c61b00"
"url": "https://github.com/fruux/sabre-vobject.git",
"reference": "de508f160e811c09b5e651909eb20b9e058a043c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/toin0u/DigitalOcean/zipball/fb460785207fa4029217eef489508b9ed6c61b00",
"reference": "fb460785207fa4029217eef489508b9ed6c61b00",
"url": "https://api.github.com/repos/fruux/sabre-vobject/zipball/de508f160e811c09b5e651909eb20b9e058a043c",
"reference": "de508f160e811c09b5e651909eb20b9e058a043c",
"shasum": ""
},
"require": {
"php": ">=5.3.0",
"symfony/console": "~2.3",
"symfony/yaml": "~2.3",
"toin0u/http-adapter": "~1.0"
"ext-mbstring": "*",
"php": ">=5.3.1"
},
"require-dev": {
"satooshi/php-coveralls": "~0.6"
"phpunit/phpunit": "*",
"squizlabs/php_codesniffer": "*"
},
"time": "2014-01-14 22:20:56",
"time": "2014-10-09 15:59:25",
"bin": [
"digitalocean"
"bin/vobject",
"bin/generate_vcards"
],
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.4-dev"
"dev-master": "3.2.x-dev"
}
},
"installation-source": "dist",
"autoload": {
"psr-0": {
"DigitalOcean": "src/"
"psr-4": {
"Sabre\\VObject\\": "lib/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
"BSD-3-Clause"
],
"authors": [
{
"name": "Antoine Corcy",
"email": "contact@sbin.dk",
"homepage": "http://sbin.dk",
"name": "Evert Pot",
"email": "me@evertpot.com",
"homepage": "http://evertpot.com/",
"role": "Developer"
},
{
"name": "Dominik Tobschall",
"email": "dominik@fruux.com",
"homepage": "http://tobschall.de/",
"role": "Developer"
}
],
"description": "DigitalOcean API PHP 5.3+ library",
"homepage": "https://github.com/toin0u/DigitalOcean",
"description": "The VObject library for PHP allows you to easily parse and manipulate iCalendar and vCard objects",
"homepage": "http://sabre.io/vobject/",
"keywords": [
"Cloud Hosting",
"SSD",
"api",
"digitalocean",
"vps"
"VObject",
"iCalendar",
"jCal",
"jCard",
"vCard"
]
},
{
"name": "twig/twig",
"version": "v1.16.0",
"version_normalized": "1.16.0.0",
"version": "v1.16.1",
"version_normalized": "1.16.1.0",
"source": {
"type": "git",
"url": "https://github.com/fabpot/Twig.git",
"reference": "8ce37115802e257a984a82d38254884085060024"
"reference": "7c4c01dcf578523cfcddf383641a4f12790270ec"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/fabpot/Twig/zipball/8ce37115802e257a984a82d38254884085060024",
"reference": "8ce37115802e257a984a82d38254884085060024",
"url": "https://api.github.com/repos/fabpot/Twig/zipball/7c4c01dcf578523cfcddf383641a4f12790270ec",
"reference": "7c4c01dcf578523cfcddf383641a4f12790270ec",
"shasum": ""
},
"require": {
"php": ">=5.2.4"
},
"time": "2014-07-05 12:19:05",
"time": "2014-10-10 14:09:53",
"type": "library",
"extra": {
"branch-alias": {

@ -4,6 +4,8 @@ php:
- 5.3
- 5.4
- 5.5
- 5.6
- hhvm
services:
- riak
@ -12,15 +14,18 @@ services:
- redis-server
before_script:
- pecl install redis
- pecl install riak-beta
- sh -c "if [ `php-config --vernum` -ge 50500 ] ; then pecl config-set preferred_state beta; printf "yes\n" | pecl install apcu ; else echo 'extension="apc.so"' >> ./tests/travis/php.ini ;fi"
- sh -c "if [ $TRAVIS_PHP_VERSION != 'hhvm' ]; then pecl install riak-beta; fi"
- sh -c "if [[ $TRAVIS_PHP_VERSION != 'hhvm' && `php-config --vernum` -ge 50500 ]] ; then pecl config-set preferred_state beta; printf "yes\n" | pecl install apcu ; else echo 'extension="apc.so"' >> ./tests/travis/php.ini ;fi"
- composer self-update
- composer --prefer-source --dev install
- phpenv config-add ./tests/travis/php.ini
- sh -c "if [ $TRAVIS_PHP_VERSION != 'hhvm' ]; then phpenv config-add ./tests/travis/php.ini; fi"
script:
- ./vendor/bin/phpunit -c ./tests/travis/phpunit.travis.xml -v
after_script:
- php vendor/bin/coveralls -v
matrix:
allow_failures:
- php: hhvm

@ -27,7 +27,7 @@
},
"extra": {
"branch-alias": {
"dev-master": "1.0.x-dev"
"dev-master": "1.4.x-dev"
}
}
}

@ -42,7 +42,7 @@ class ArrayCache extends CacheProvider
*/
protected function doFetch($id)
{
return (isset($this->data[$id])) ? $this->data[$id] : false;
return $this->doContains($id) ? $this->data[$id] : false;
}
/**
@ -50,7 +50,7 @@ class ArrayCache extends CacheProvider
*/
protected function doContains($id)
{
return isset($this->data[$id]);
return isset($this->data[$id]) || array_key_exists($id, $this->data);
}
/**

@ -43,7 +43,7 @@ abstract class CacheProvider implements Cache
/**
* The namespace version.
*
* @var string
* @var integer|null
*/
private $namespaceVersion;
@ -162,7 +162,7 @@ abstract class CacheProvider implements Cache
/**
* Returns the namespace version.
*
* @return string
* @return integer
*/
private function getNamespaceVersion()
{
@ -189,7 +189,7 @@ abstract class CacheProvider implements Cache
*
* @param string $id The id of the cache entry to fetch.
*
* @return string|bool The cached data or FALSE, if no cache entry exists for the given id.
* @return string|boolean The cached data or FALSE, if no cache entry exists for the given id.
*/
abstract protected function doFetch($id);

@ -130,7 +130,7 @@ abstract class FileCache extends CacheProvider
protected function doGetStats()
{
$usage = 0;
foreach ($this->getIterator() as $name => $file) {
foreach ($this->getIterator() as $file) {
$usage += $file->getSize();
}

@ -105,9 +105,21 @@ class FilesystemCache extends FileCache
$filepath = pathinfo($filename, PATHINFO_DIRNAME);
if ( ! is_dir($filepath)) {
mkdir($filepath, 0777, true);
if (false === @mkdir($filepath, 0777, true) && !is_dir($filepath)) {
return false;
}
} elseif ( ! is_writable($filepath)) {
return false;
}
$tmpFile = tempnam($filepath, basename($filename));
if ((file_put_contents($tmpFile, $lifeTime . PHP_EOL . $data) !== false) && @rename($tmpFile, $filename)) {
@chmod($filename, 0666 & ~umask());
return true;
}
return file_put_contents($filename, $lifeTime . PHP_EOL . $data) !== false;
return false;
}
}

@ -24,7 +24,8 @@ use \Memcached;
/**
* Memcached cache provider.
*
* @link www.doctrine-project.org
* @since 2.2
* @author Benjamin Eberlei <kontakt@beberlei.de>
* @author Guilherme Blanco <guilhermeblanco@hotmail.com>
* @author Jonathan Wage <jonwage@gmail.com>

@ -22,10 +22,4 @@
<directory>./lib/Doctrine/</directory>
</whitelist>
</filter>
<groups>
<exclude>
<group>performance</group>
</exclude>
</groups>
</phpunit>

@ -37,6 +37,7 @@ abstract class CacheTest extends \Doctrine\Tests\DoctrineTestCase
'integer' => array(1),
'float' => array(1.5),
'object' => array(new ArrayObject()),
'null' => array(null),
);
}

@ -2,8 +2,6 @@
/*
* This file bootstraps the test environment.
*/
namespace Doctrine\Tests;
error_reporting(E_ALL | E_STRICT);
if (file_exists(__DIR__ . '/../../../vendor/autoload.php')) {
@ -13,7 +11,7 @@ if (file_exists(__DIR__ . '/../../../vendor/autoload.php')) {
// installed as a dependency in `vendor`
$classLoader = require __DIR__ . '/../../../../../autoload.php';
} else {
throw new \Exception('Can\'t find autoload.php. Did you install dependencies via composer?');
throw new Exception('Can\'t find autoload.php. Did you install dependencies via Composer?');
}
/* @var $classLoader \Composer\Autoload\ClassLoader */

@ -1,3 +1,28 @@
### 1.11.0 (2014-09-30)
* Break: The NewRelicHandler extra and context data are now prefixed with extra_ and context_ to avoid clashes. Watch out if you have scripts reading those from the API and rely on names
* Added WhatFailureGroupHandler to suppress any exception coming from the wrapped handlers and avoid chain failures if a logging service fails
* Added MandrillHandler to send emails via the Mandrillapp.com API
* Added SlackHandler to log records to a Slack.com account
* Added FleepHookHandler to log records to a Fleep.io account
* Added LogglyHandler::addTag to allow adding tags to an existing handler
* Added $ignoreEmptyContextAndExtra to LineFormatter to avoid empty [] at the end
* Added $useLocking to StreamHandler and RotatingFileHandler to enable flock() while writing
* Added support for PhpAmqpLib in the AmqpHandler
* Added FingersCrossedHandler::clear and BufferHandler::clear to reset them between batches in long running jobs
* Added support for adding extra fields from $_SERVER in the WebProcessor
* Fixed support for non-string values in PrsLogMessageProcessor
* Fixed SwiftMailer messages being sent with the wrong date in long running scripts
* Fixed minor PHP 5.6 compatibility issues
* Fixed BufferHandler::close being called twice
### 1.10.0 (2014-06-04)
* Added Logger::getHandlers() and Logger::getProcessors() methods
* Added $passthruLevel argument to FingersCrossedHandler to let it always pass some records through even if the trigger level is not reached
* Added support for extra data in NewRelicHandler
* Added $expandNewlines flag to the ErrorLogHandler to create multiple log entries when a message has multiple lines
### 1.9.1 (2014-04-24)
* Fixed regression in RotatingFileHandler file permissions

@ -1,4 +1,4 @@
Copyright (c) Jordi Boggiano
Copyright (c) 2011-2014 Jordi Boggiano
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

@ -3,6 +3,7 @@ Monolog - Logging for PHP 5.3+ [![Build Status](https://secure.travis-ci.org/Sel
[![Total Downloads](https://poser.pugx.org/monolog/monolog/downloads.png)](https://packagist.org/packages/monolog/monolog)
[![Latest Stable Version](https://poser.pugx.org/monolog/monolog/v/stable.png)](https://packagist.org/packages/monolog/monolog)
[![Reference Status](https://www.versioneye.com/php/monolog:monolog/reference_badge.svg)](https://www.versioneye.com/php/monolog:monolog/references)
Monolog sends your logs to files, sockets, inboxes, databases and various
@ -13,6 +14,8 @@ This library implements the [PSR-3](https://github.com/php-fig/fig-standards/blo
interface that you can type-hint against in your own libraries to keep
a maximum of interoperability. You can also use it in your applications to
make sure you can always use another compatible logger at a later time.
As of 1.11.0 Monolog public APIs will also accept PSR-3 log levels.
Internally Monolog still uses its own level scheme since it predates PSR-3.
Usage
-----
@ -120,6 +123,9 @@ Handlers
- _PushoverHandler_: Sends mobile notifications via the [Pushover](https://www.pushover.net/) API.
- _HipChatHandler_: Logs records to a [HipChat](http://hipchat.com) chat room using its API.
- _FlowdockHandler_: Logs records to a [Flowdock](https://www.flowdock.com/) account.
- _SlackHandler_: Logs records to a [Slack](https://www.slack.com/) account.
- _MandrillHandler_: Sends emails via the Mandrill API using a [`Swift_Message`](http://swiftmailer.org/) instance.
- _FleepHookHandler_: Logs records to a [Fleep](https://fleep.io/) conversation using Webhooks.
### Log specific servers and networked logging
@ -180,6 +186,10 @@ Handlers
to the wrapped handler.
- _TestHandler_: Used for testing, it records everything that is sent to it and
has accessors to read out the information.
- _WhatFailureGroupHandler_: This handle extends the _GroupHandler_ ignoring
exceptions raised by each child handler. This allows you to ignore issues
where a remote tcp connection may have died but you do not want your entire
application to crash and may wish to continue to log to other handlers.
Formatters
----------
@ -192,7 +202,7 @@ Formatters
- _WildfireFormatter_: Used to format log records into the Wildfire/FirePHP protocol, only useful for the FirePHPHandler.
- _ChromePHPFormatter_: Used to format log records into the ChromePHP format, only useful for the ChromePHPHandler.
- _GelfMessageFormatter_: Used to format log records into Gelf message instances, only useful for the GelfHandler.
- _LogstashFormatter_: Used to format log records into [logstash](http://logstash.net/) event json, useful for any handler listed under inputs [here](http://logstash.net/docs/1.1.5/).
- _LogstashFormatter_: Used to format log records into [logstash](http://logstash.net/) event json, useful for any handler listed under inputs [here](http://logstash.net/docs/latest).
- _ElasticaFormatter_: Used to format log records into an Elastica\Document object, only useful for the ElasticSearchHandler.
- _LogglyFormatter_: Used to format log records into Loggly messages, only useful for the LogglyHandler.
- _FlowdockFormatter_: Used to format log records into Flowdock messages, only useful for the FlowdockHandler.

@ -22,13 +22,15 @@
"raven/raven": "~0.5",
"ruflin/elastica": "0.90.*",
"doctrine/couchdb": "~1.0@dev",
"aws/aws-sdk-php": "~2.4, >2.4.8"
"aws/aws-sdk-php": "~2.4, >2.4.8",
"videlalvaro/php-amqplib": "~2.4"
},
"suggest": {
"graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server",
"raven/raven": "Allow sending log messages to a Sentry server",
"doctrine/couchdb": "Allow sending log messages to a CouchDB server",
"ruflin/elastica": "Allow sending log messages to an Elastic Search server",
"videlalvaro/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib",
"ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)",
"ext-mongo": "Allow sending log messages to a MongoDB server",
"aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB",
@ -37,9 +39,12 @@
"autoload": {
"psr-4": {"Monolog\\": "src/Monolog"}
},
"provide": {
"psr/log-implementation": "1.0.0"
},
"extra": {
"branch-alias": {
"dev-master": "1.9.x-dev"
"dev-master": "1.11.x-dev"
}
}
}

@ -142,7 +142,7 @@ class ErrorHandler
}
$level = isset($this->errorLevelMap[$code]) ? $this->errorLevelMap[$code] : LogLevel::CRITICAL;
$this->logger->log($level, self::codeToString($code).': '.$message, array('file' => $file, 'line' => $line));
$this->logger->log($level, self::codeToString($code).': '.$message, array('code' => $code, 'message' => $message, 'file' => $file, 'line' => $line));
if ($this->previousErrorHandler === true) {
return false;
@ -163,7 +163,7 @@ class ErrorHandler
$this->logger->log(
$this->fatalLevel === null ? LogLevel::ALERT : $this->fatalLevel,
'Fatal Error ('.self::codeToString($lastError['type']).'): '.$lastError['message'],
array('file' => $lastError['file'], 'line' => $lastError['line'])
array('code' => $lastError['type'], 'message' => $lastError['message'], 'file' => $lastError['file'], 'line' => $lastError['line'])
);
}
}

@ -46,14 +46,17 @@ class HtmlFormatter extends NormalizerFormatter
/**
* Creates an HTML table row
*
* @param string $th Row header content
* @param string $td Row standard cell content
* @param string $th Row header content
* @param string $td Row standard cell content
* @param bool $escapeTd false if td content must not be html escaped
* @return string
*/
private function addRow($th, $td = ' ')
private function addRow($th, $td = ' ', $escapeTd = true)
{
$th = htmlspecialchars($th, ENT_NOQUOTES, 'UTF-8');
$td = '<pre>'.htmlspecialchars($td, ENT_NOQUOTES, 'UTF-8').'</pre>';
if ($escapeTd) {
$td = '<pre>'.htmlspecialchars($td, ENT_NOQUOTES, 'UTF-8').'</pre>';
}
return "<tr style=\"padding: 4px;spacing: 0;text-align: left;\">\n<th style=\"background: #cccccc\" width=\"100px\">$th:</th>\n<td style=\"padding: 4px;spacing: 0;text-align: left;background: #eeeeee\">".$td."</td>\n</tr>";
}
@ -83,13 +86,23 @@ class HtmlFormatter extends NormalizerFormatter
$output .= '<table cellspacing="1" width="100%">';
$output .= $this->addRow('Message', (string) $record['message']);
$output .= $this->addRow('Time', $record['datetime']->format('Y-m-d\TH:i:s.uO'));
$output .= $this->addRow('Time', $record['datetime']->format($this->dateFormat));
$output .= $this->addRow('Channel', $record['channel']);
if ($record['context']) {
$output .= $this->addRow('Context', $this->convertToString($record['context']));
$embeddedTable = '<table cellspacing="1" width="100%">';
foreach ($record['context'] as $key => $value) {
$embeddedTable .= $this->addRow($key, $this->convertToString($value));
}
$embeddedTable .= '</table>';
$output .= $this->addRow('Context', $embeddedTable, false);
}
if ($record['extra']) {
$output .= $this->addRow('Extra', $this->convertToString($record['extra']));
$embeddedTable = '<table cellspacing="1" width="100%">';
foreach ($record['extra'] as $key => $value) {
$embeddedTable .= $this->addRow($key, $this->convertToString($value));
}
$embeddedTable .= '</table>';
$output .= $this->addRow('Extra', $embeddedTable, false);
}
return $output.'</table>';

@ -27,16 +27,19 @@ class LineFormatter extends NormalizerFormatter
protected $format;
protected $allowInlineLineBreaks;
protected $ignoreEmptyContextAndExtra;
/**
* @param string $format The format of the message
* @param string $dateFormat The format of the timestamp: one supported by DateTime::format
* @param bool $allowInlineLineBreaks Whether to allow inline line breaks in log entries
* @param string $format The format of the message
* @param string $dateFormat The format of the timestamp: one supported by DateTime::format
* @param bool $allowInlineLineBreaks Whether to allow inline line breaks in log entries
* @param bool $ignoreEmptyContextAndExtra
*/
public function __construct($format = null, $dateFormat = null, $allowInlineLineBreaks = false)
public function __construct($format = null, $dateFormat = null, $allowInlineLineBreaks = false, $ignoreEmptyContextAndExtra = false)
{
$this->format = $format ?: static::SIMPLE_FORMAT;
$this->allowInlineLineBreaks = $allowInlineLineBreaks;
$this->ignoreEmptyContextAndExtra = $ignoreEmptyContextAndExtra;
parent::__construct($dateFormat);
}
@ -48,12 +51,26 @@ class LineFormatter extends NormalizerFormatter
$vars = parent::format($record);
$output = $this->format;
foreach ($vars['extra'] as $var => $val) {
if (false !== strpos($output, '%extra.'.$var.'%')) {
$output = str_replace('%extra.'.$var.'%', $this->replaceNewlines($this->convertToString($val)), $output);
unset($vars['extra'][$var]);
}
}
if ($this->ignoreEmptyContextAndExtra) {
if (empty($vars['context'])) {
unset($vars['context']);
$output = str_replace('%context%', '', $output);
}
if (empty($vars['extra'])) {
unset($vars['extra']);
$output = str_replace('%extra%', '', $output);
}
}
foreach ($vars as $var => $val) {
if (false !== strpos($output, '%'.$var.'%')) {
$output = str_replace('%'.$var.'%', $this->replaceNewlines($this->convertToString($val)), $output);
@ -108,6 +125,6 @@ class LineFormatter extends NormalizerFormatter
return $str;
}
return preg_replace('{[\r\n]+}', ' ', $str);
return strtr($str, array("\r\n" => ' ', "\r" => ' ', "\n" => ' '));
}
}

@ -38,7 +38,7 @@ class LogglyFormatter extends JsonFormatter
public function format(array $record)
{
if (isset($record["datetime"]) && ($record["datetime"] instanceof \DateTime)) {
$record["timestamp"] = $record["datetime"]->format("c");
$record["timestamp"] = $record["datetime"]->format("Y-m-d\TH:i:s.uO");
// TODO 2.0 unset the 'datetime' parameter, retained for BC
}

@ -30,6 +30,9 @@ class NormalizerFormatter implements FormatterInterface
public function __construct($dateFormat = null)
{
$this->dateFormat = $dateFormat ?: static::SIMPLE_DATE;
if (!function_exists('json_encode')) {
throw new \RuntimeException('PHP\'s json extension is required to use Monolog\'s NormalizerFormatter');
}
}
/**

@ -37,7 +37,7 @@ abstract class AbstractHandler implements HandlerInterface
*/
public function __construct($level = Logger::DEBUG, $bubble = true)
{
$this->level = $level;
$this->setLevel($level);
$this->bubble = $bubble;
}
@ -123,7 +123,7 @@ abstract class AbstractHandler implements HandlerInterface
*/
public function setLevel($level)
{
$this->level = $level;
$this->level = Logger::toMonologLevel($level);
return $this;
}

@ -13,24 +13,38 @@ namespace Monolog\Handler;
use Monolog\Logger;
use Monolog\Formatter\JsonFormatter;
use PhpAmqpLib\Message\AMQPMessage;
use PhpAmqpLib\Channel\AMQPChannel;
use AMQPExchange;
class AmqpHandler extends AbstractProcessingHandler
{
/**
* @var \AMQPExchange $exchange
* @var AMQPExchange|AMQPChannel $exchange
*/
protected $exchange;
/**
* @param \AMQPExchange $exchange AMQP exchange, ready for use
* @param string $exchangeName
* @param int $level
* @param bool $bubble Whether the messages that are handled can bubble up the stack or not
* @var string
*/
public function __construct(\AMQPExchange $exchange, $exchangeName = 'log', $level = Logger::DEBUG, $bubble = true)
protected $exchangeName;
/**
* @param AMQPExchange|AMQPChannel $exchange AMQPExchange (php AMQP ext) or PHP AMQP lib channel, ready for use
* @param string $exchangeName
* @param int $level
* @param bool $bubble Whether the messages that are handled can bubble up the stack or not
*/
public function __construct($exchange, $exchangeName = 'log', $level = Logger::DEBUG, $bubble = true)
{
if ($exchange instanceof AMQPExchange) {
$exchange->setName($exchangeName);
} elseif ($exchange instanceof AMQPChannel) {
$this->exchangeName = $exchangeName;
} else {
throw new \InvalidArgumentException('PhpAmqpLib\Channel\AMQPChannel or AMQPExchange instance required');
}
$this->exchange = $exchange;
$this->exchange->setName($exchangeName);
parent::__construct($level, $bubble);
}
@ -44,19 +58,34 @@ class AmqpHandler extends AbstractProcessingHandler
$routingKey = sprintf(
'%s.%s',
// TODO 2.0 remove substr call
substr($record['level_name'], 0, 4),
$record['channel']
);
$this->exchange->publish(
$data,
strtolower($routingKey),
0,
array(
'delivery_mode' => 2,
'Content-type' => 'application/json'
)
);
if ($this->exchange instanceof AMQPExchange) {
$this->exchange->publish(
$data,
strtolower($routingKey),
0,
array(
'delivery_mode' => 2,
'Content-type' => 'application/json'
)
);
} else {
$this->exchange->basic_publish(
new AMQPMessage(
(string) $data,
array(
'delivery_mode' => 2,
'content_type' => 'application/json'
)
),
$this->exchangeName,
strtolower($routingKey)
);
}
}
/**

@ -88,8 +88,14 @@ class BufferHandler extends AbstractHandler
}
$this->handler->handleBatch($this->buffer);
$this->bufferSize = 0;
$this->buffer = array();
$this->clear();
}
public function __destruct()
{
// suppress the parent behavior since we already have register_shutdown_function()
// to call close(), and the reference contained there will prevent this from being
// GC'd until the end of the request
}
/**
@ -99,4 +105,13 @@ class BufferHandler extends AbstractHandler
{
$this->flush();
}
/**
* Clears the buffer without flushing any messages down to the wrapped handler.
*/
public function clear()
{
$this->bufferSize = 0;
$this->buffer = array();
}
}

@ -50,6 +50,18 @@ class ChromePHPHandler extends AbstractProcessingHandler
protected static $sendHeaders = true;
/**
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
*/
public function __construct($level = Logger::DEBUG, $bubble = true)
{
parent::__construct($level, $bubble);
if (!function_exists('json_encode')) {
throw new \RuntimeException('PHP\'s json extension is required to use Monolog\'s ChromePHPHandler');
}
}
/**
* {@inheritdoc}
*/

@ -25,13 +25,15 @@ class ErrorLogHandler extends AbstractProcessingHandler
const SAPI = 4;
protected $messageType;
protected $expandNewlines;
/**
* @param integer $messageType Says where the error should go.
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param integer $messageType Says where the error should go.
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param Boolean $expandNewlines If set to true, newlines in the message will be expanded to be take multiple log entries
*/
public function __construct($messageType = self::OPERATING_SYSTEM, $level = Logger::DEBUG, $bubble = true)
public function __construct($messageType = self::OPERATING_SYSTEM, $level = Logger::DEBUG, $bubble = true, $expandNewlines = false)
{
parent::__construct($level, $bubble);
@ -41,6 +43,7 @@ class ErrorLogHandler extends AbstractProcessingHandler
}
$this->messageType = $messageType;
$this->expandNewlines = $expandNewlines;
}
/**
@ -67,6 +70,13 @@ class ErrorLogHandler extends AbstractProcessingHandler
*/
protected function write(array $record)
{
error_log((string) $record['formatted'], $this->messageType);
if ($this->expandNewlines) {
$lines = preg_split('{[\r\n]+}', (string) $record['formatted']);
foreach ($lines as $line) {
error_log($line, $this->messageType);
}
} else {
error_log((string) $record['formatted'], $this->messageType);
}
}
}

@ -1,5 +1,14 @@
<?php
/*
* This file is part of the Monolog package.
*
* (c) Jordi Boggiano <j.boggiano@seld.be>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Monolog\Handler;
use Monolog\Logger;
@ -24,7 +33,7 @@ class FilterHandler extends AbstractHandler
/**
* Minimum level for logs that are passes to handler
*
* @var int
* @var int[]
*/
protected $acceptedLevels;
@ -63,11 +72,13 @@ class FilterHandler extends AbstractHandler
public function setAcceptedLevels($minLevelOrList = Logger::DEBUG, $maxLevel = Logger::EMERGENCY)
{
if (is_array($minLevelOrList)) {
$acceptedLevels = $minLevelOrList;
$acceptedLevels = array_map('Monolog\Logger::toMonologLevel', $minLevelOrList);
} else {
$acceptedLevels = array_filter(Logger::getLevels(), function ($level) use ($minLevelOrList, $maxLevel) {
$minLevelOrList = Logger::toMonologLevel($minLevelOrList);
$maxLevel = Logger::toMonologLevel($maxLevel);
$acceptedLevels = array_values(array_filter(Logger::getLevels(), function ($level) use ($minLevelOrList, $maxLevel) {
return $level >= $minLevelOrList && $level <= $maxLevel;
});
}));
}
$this->acceptedLevels = array_flip($acceptedLevels);
}

@ -11,6 +11,8 @@
namespace Monolog\Handler\FingersCrossed;
use Monolog\Logger;
/**
* Channel and Error level based monolog activation strategy. Allows to trigger activation
* based on level per channel. e.g. trigger activation on level 'ERROR' by default, except
@ -37,13 +39,13 @@ class ChannelLevelActivationStrategy implements ActivationStrategyInterface
private $channelToActionLevel;
/**
* @param int $defaultActionLevel The default action level to be used if the record's category doesn't match any
* @param array $categoryToActionLevel An array that maps channel names to action levels.
* @param int $defaultActionLevel The default action level to be used if the record's category doesn't match any
* @param array $channelToActionLevel An array that maps channel names to action levels.
*/
public function __construct($defaultActionLevel, $channelToActionLevel = array())
{
$this->defaultActionLevel = $defaultActionLevel;
$this->channelToActionLevel = $channelToActionLevel;
$this->defaultActionLevel = Logger::toMonologLevel($defaultActionLevel);
$this->channelToActionLevel = array_map('Monolog\Logger::toMonologLevel', $channelToActionLevel);
}
public function isHandlerActivated(array $record)

@ -11,6 +11,8 @@
namespace Monolog\Handler\FingersCrossed;
use Monolog\Logger;
/**
* Error level based activation strategy.
*
@ -22,7 +24,7 @@ class ErrorLevelActivationStrategy implements ActivationStrategyInterface
public function __construct($actionLevel)
{
$this->actionLevel = $actionLevel;
$this->actionLevel = Logger::toMonologLevel($actionLevel);
}
public function isHandlerActivated(array $record)

@ -35,6 +35,7 @@ class FingersCrossedHandler extends AbstractHandler
protected $bufferSize;
protected $buffer = array();
protected $stopBuffering;
protected $passthruLevel;
/**
* @param callable|HandlerInterface $handler Handler or factory callable($record, $fingersCrossedHandler).
@ -42,8 +43,9 @@ class FingersCrossedHandler extends AbstractHandler
* @param int $bufferSize How many entries should be buffered at most, beyond that the oldest items are removed from the buffer.
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param Boolean $stopBuffering Whether the handler should stop buffering after being triggered (default true)
* @param int $passthruLevel Minimum level to always flush to handler on close, even if strategy not triggered
*/
public function __construct($handler, $activationStrategy = null, $bufferSize = 0, $bubble = true, $stopBuffering = true)
public function __construct($handler, $activationStrategy = null, $bufferSize = 0, $bubble = true, $stopBuffering = true, $passthruLevel = null)
{
if (null === $activationStrategy) {
$activationStrategy = new ErrorLevelActivationStrategy(Logger::WARNING);
@ -59,6 +61,7 @@ class FingersCrossedHandler extends AbstractHandler
$this->bufferSize = $bufferSize;
$this->bubble = $bubble;
$this->stopBuffering = $stopBuffering;
$this->passthruLevel = $passthruLevel;
}
/**
@ -108,6 +111,23 @@ class FingersCrossedHandler extends AbstractHandler
return false === $this->bubble;
}
/**
* {@inheritdoc}
*/
public function close()
{
if (null !== $this->passthruLevel) {
$level = $this->passthruLevel;
$this->buffer = array_filter($this->buffer, function ($record) use ($level) {
return $record['level'] >= $level;
});
if (count($this->buffer) > 0) {
$this->handler->handleBatch($this->buffer);
$this->buffer = array();
}
}
}
/**
* Resets the state of the handler. Stops forwarding records to the wrapped handler.
*/
@ -115,4 +135,15 @@ class FingersCrossedHandler extends AbstractHandler
{
$this->buffering = true;
}
/**
* Clears the buffer without flushing any messages down to the wrapped handler.
*
* It also resets the handler to its initial buffering state.
*/
public function clear()
{
$this->buffer = array();
$this->reset();
}
}

@ -53,7 +53,7 @@ class FlowdockHandler extends SocketHandler
*
* @param array $record
*/
public function write(array $record)
protected function write(array $record)
{
parent::write($record);

@ -165,7 +165,7 @@ class HipChatHandler extends SocketHandler
*
* @param array $record
*/
public function write(array $record)
protected function write(array $record)
{
parent::write($record);
$this->closeSocket();
@ -209,7 +209,6 @@ class HipChatHandler extends SocketHandler
{
$batchRecord = null;
$batchRecords = array();
$batchedMessages = array();
$messages = array();
$formattedMessages = array();
$level = 0;

@ -46,6 +46,11 @@ class LogglyHandler extends AbstractProcessingHandler
$this->tag = $tag;
}
public function addTag($tag)
{
$this->tag = (strlen($this->tag) > 0) ? $this->tag .','. $tag : $tag;
}
protected function write(array $record)
{
$this->send($record["formatted"], self::ENDPOINT_SINGLE);

@ -22,8 +22,8 @@ use Monolog\Logger;
class NativeMailerHandler extends MailHandler
{
/**
* The email address to which the message is delivered
* @var string
* The email addresses to which the message will be sent
* @var array
*/
protected $to;

@ -60,7 +60,11 @@ class NewRelicHandler extends AbstractProcessingHandler
}
foreach ($record['context'] as $key => $parameter) {
newrelic_add_custom_parameter($key, $parameter);
newrelic_add_custom_parameter('context_' . $key, $parameter);
}
foreach ($record['extra'] as $key => $parameter) {
newrelic_add_custom_parameter('extra_' . $key, $parameter);
}
}

@ -65,8 +65,8 @@ class PushoverHandler extends SocketHandler
$this->token = $token;
$this->users = (array) $users;
$this->title = $title ?: gethostname();
$this->highPriorityLevel = $highPriorityLevel;
$this->emergencyLevel = $emergencyLevel;
$this->highPriorityLevel = Logger::toMonologLevel($highPriorityLevel);
$this->emergencyLevel = Logger::toMonologLevel($emergencyLevel);
$this->retry = $retry;
$this->expire = $expire;
}
@ -93,11 +93,11 @@ class PushoverHandler extends SocketHandler
'timestamp' => $timestamp
);
if ($record['level'] >= $this->emergencyLevel) {
if (isset($record['level']) && $record['level'] >= $this->emergencyLevel) {
$dataArray['priority'] = 2;
$dataArray['retry'] = $this->retry;
$dataArray['expire'] = $this->expire;
} elseif ($record['level'] >= $this->highPriorityLevel) {
} elseif (isset($record['level']) && $record['level'] >= $this->highPriorityLevel) {
$dataArray['priority'] = 1;
}
@ -121,7 +121,7 @@ class PushoverHandler extends SocketHandler
return $header;
}
public function write(array $record)
protected function write(array $record)
{
foreach ($this->users as $user) {
$this->user = $user;

@ -17,7 +17,7 @@ use Monolog\Logger;
use Raven_Client;
/**
* Handler to send messages to a Sentry (https://github.com/dcramer/sentry) server
* Handler to send messages to a Sentry (https://github.com/getsentry/sentry) server
* using raven-php (https://github.com/getsentry/raven-php)
*
* @author Marc Abramowitz <marc@marc-abramowitz.com>

@ -1,5 +1,14 @@
<?php
/*
* This file is part of the Monolog package.
*
* (c) Jordi Boggiano <j.boggiano@seld.be>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Monolog\Handler;
use RollbarNotifier;

@ -32,13 +32,14 @@ class RotatingFileHandler extends StreamHandler
protected $dateFormat;
/**
* @param string $filename
* @param integer $maxFiles The maximal amount of files to keep (0 means unlimited)
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param int $filePermissions Optional file permissions (default (0644) are only for owner read/write)
* @param string $filename
* @param integer $maxFiles The maximal amount of files to keep (0 means unlimited)
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param int|null $filePermission Optional file permissions (default (0644) are only for owner read/write)
* @param Boolean $useLocking Try to lock log file before doing any writes
*/
public function __construct($filename, $maxFiles = 0, $level = Logger::DEBUG, $bubble = true, $filePermission = null)
public function __construct($filename, $maxFiles = 0, $level = Logger::DEBUG, $bubble = true, $filePermission = null, $useLocking = false)
{
$this->filename = $filename;
$this->maxFiles = (int) $maxFiles;
@ -46,7 +47,7 @@ class RotatingFileHandler extends StreamHandler
$this->filenameFormat = '{filename}-{date}';
$this->dateFormat = 'Y-m-d';
parent::__construct($this->getTimedFilename(), $level, $bubble, $filePermission);
parent::__construct($this->getTimedFilename(), $level, $bubble, $filePermission, $useLocking);
}
/**

@ -49,7 +49,7 @@ class SocketHandler extends AbstractProcessingHandler
* @throws \UnexpectedValueException
* @throws \RuntimeException
*/
public function write(array $record)
protected function write(array $record)
{
$this->connectIfNotConnected();
$data = $this->generateDataStream($record);

@ -26,23 +26,30 @@ class StreamHandler extends AbstractProcessingHandler
protected $url;
private $errorMessage;
protected $filePermission;
protected $useLocking;
/**
* @param string $stream
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param int $filePermissions Optional file permissions (default (0644) are only for owner read/write)
* @param resource|string $stream
* @param integer $level The minimum logging level at which this handler will be triggered
* @param Boolean $bubble Whether the messages that are handled can bubble up the stack or not
* @param int|null $filePermission Optional file permissions (default (0644) are only for owner read/write)
* @param Boolean $useLocking Try to lock log file before doing any writes
*
* @throws InvalidArgumentException If stream is not a resource or string
*/
public function __construct($stream, $level = Logger::DEBUG, $bubble = true, $filePermission = null)
public function __construct($stream, $level = Logger::DEBUG, $bubble = true, $filePermission = null, $useLocking = false)
{
parent::__construct($level, $bubble);
if (is_resource($stream)) {
$this->stream = $stream;
} else {
} elseif (is_string($stream)) {
$this->url = $stream;
} else {
throw new \InvalidArgumentException('A stream must either be a resource or a string.');
}
$this->filePermission = $filePermission;
$this->useLocking = $useLocking;
}
/**
@ -77,7 +84,17 @@ class StreamHandler extends AbstractProcessingHandler
throw new \UnexpectedValueException(sprintf('The stream or file "%s" could not be opened: '.$this->errorMessage, $this->url));
}
}
if ($this->useLocking) {
// ignoring errors here, there's not much we can do about them
flock($this->stream, LOCK_EX);
}
fwrite($this->stream, (string) $record['formatted']);
if ($this->useLocking) {
flock($this->stream, LOCK_UN);
}
}
private function customErrorHandler($code, $msg)

@ -49,6 +49,7 @@ class SwiftMailerHandler extends MailHandler
{
$message = clone $this->message;
$message->setBody($content);
$message->setDate(time());
$this->mailer->send($message);
}

@ -172,6 +172,14 @@ class Logger implements LoggerInterface
return array_shift($this->handlers);
}
/**
* @return HandlerInterface[]
*/
public function getHandlers()
{
return $this->handlers;
}
/**
* Adds a processor on to the stack.
*
@ -199,6 +207,14 @@ class Logger implements LoggerInterface
return array_shift($this->processors);
}
/**
* @return callable[]
*/
public function getProcessors()
{
return $this->processors;
}
/**
* Adds a log record.
*
@ -372,6 +388,21 @@ class Logger implements LoggerInterface
return static::$levels[$level];
}
/**
* Converts PSR-3 levels to Monolog ones if necessary
*
* @param string|int Level number (monolog) or name (PSR-3)
* @return int
*/
public static function toMonologLevel($level)
{
if (is_string($level) && defined(__CLASS__.'::'.strtoupper($level))) {
return constant(__CLASS__.'::'.strtoupper($level));
}
return $level;
}
/**
* Checks whether the Logger has a handler that listens on the given level
*

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save