1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-06 13:16:39 +02:00

20 Commits

Author SHA1 Message Date
Jordi Boggiano
2ea3d95ca2 Make sure this works on any hostname 2017-06-19 02:00:36 +02:00
Enleur
faed450d52 Use GELF max length per field and make max length configurable in constructor 2017-04-07 13:49:54 +03:00
Christian Flothmann
b437bb928a fix Gelf message formatter tests
Version 1.4.1 is the last version compatible with PHP < 5.3.9, but
filtered all message attributes with zero string length.
2016-04-05 15:51:16 +02:00
Jordi Boggiano
6bc1a444db Truncate messages if they reach the max length of GELF messages, fixes #751 2016-04-02 13:53:47 +01:00
Jordi Boggiano
c889fb2648 CS fixes & upgrading cs fixer config 2015-11-18 17:09:46 +00:00
Jordi Boggiano
5cd99de56d Accept incomplete records in GelfMessageFormatter, closes #482 2015-03-01 13:59:22 +00:00
Thomas Ploch
dca8f5841f Normalize frames for trace items since they can contain invalid data.
Refs https://github.com/Seldaek/monolog/pull/474/files

The fix in the previous PR did not take into account that there might be object wrapped resources that would break json_encode, so the best solution would be normalizing those frames again.

@Seldaek Sorry for the inconvenience, but our graylog is still ramming up with those json_encode error messages.
2014-12-16 13:26:24 +01:00
Jordi Boggiano
2d192b0567 Skip test in hhvm 2014-12-16 11:04:16 +00:00
Jordi Boggiano
d7561931a5 Attempt to fix hhvm build 2014-12-16 10:34:35 +00:00
Thomas Ploch
00bfec630a Recursively check for resource arguments if trace is coming from internal function.
With `React` or `Guzzle`, that register stream wrappers with PHP, the traces are treated as coming from internal functions with no line and file inside the frame. But they almost always contain resources as arguments, on which the `json_encode()` call will choke (probably this should be addressed in json_encode internally, since it is very easy to cast a resource to a string).

I added a test case proving the situation and a pretty basic recursive checker for resources which just casts them as a string into the frame again.
2014-12-16 10:13:12 +01:00
Jordi Boggiano
b738a6c04c CS fixes 2014-10-17 19:12:45 +01:00
Jordi Boggiano
392ef35fd4 CS fixes 2014-03-23 20:50:26 +01:00
Benjamin Zikarsky
f0ed3d8054 Allow for both mlehner/gelf-php and graylog2/gelf-php usage 2014-02-22 16:11:33 +01:00
Benjamin Zikarsky
c8289fd654 Updated GelfHandler/GelfFormatter
Changes monolog to use the updated official graylog2/gelf-php
2013-12-28 18:57:39 +01:00
Jordi Boggiano
0f3c054dff Fix tests for 5.3 2013-10-28 10:41:17 +01:00
Tarjei Huse
b78d997638 Add logging of exception line and file path to gelf message 2013-10-27 08:29:08 +01:00
Jordi Boggiano
47eb599b4a Update tests and changelog 2013-01-11 11:23:20 +01:00
Marc Abramowitz
fd4d2556f6 Refactor GelfMessageFormatterTest and GelfHandlerTest so that they don't
fatal error when mlehner/gelf-php is not installed.

Fixes GH-78.
2012-04-26 15:37:21 -07:00
Matt Lehner
d95889a98d code cleanups as suggested by @stof 2012-04-20 13:25:38 -04:00
Matt Lehner
979c4655f9 created GelfMessageFormatter and related tests 2012-04-17 16:17:43 -04:00