Vincent Langlet
c4ba76aeae
Avoid throwing an exception when the toString fails ( #1868 )
2024-04-12 10:47:57 +02:00
Jordi Boggiano
8ff4ab5c94
Add ability to indent stack traces in LineFormatter, fixes #1835
2023-10-27 16:19:09 +02:00
Jordi Boggiano
5d317e2c6f
Fix tests usage
2023-10-27 16:09:14 +02:00
Philipp Müller
1feb860c33
Added possibility to set max length for level name in LineFormatter
...
Closes #1850
2023-10-27 16:07:36 +02:00
Jordi Boggiano
70f6ca05b9
Merge branch '2.x'
2023-10-27 15:26:39 +02:00
dong
8813064010
Let indexed arrays to support inline linebreaks in LineFormatter ( #1818 )
2023-10-27 14:31:42 +02:00
Egor Korobov
ed80d53ab2
Fix fatal error in NormalizeFormatter: method_exists(): The script tried to execute a method or access a property of an incomplete object.
...
Closes #1833
Fixes #1834
2023-10-27 14:05:53 +02:00
chris
8561130215
Upgrade to phpunit 10 ( #1806 )
...
Co-authored-by: Christopher Georg <christopher.georg@sr-travel.de >
2023-06-20 15:56:11 +02:00
Luís Cobucci
69bd3637ba
Fix date/time field for GCP logging ( #1759 )
...
We introduced the formatter using the incorrect field, which was making
GCP not to extract the correct value from the payload.
This uses the field that actually maps to the expected format.
More info: https://cloud.google.com/logging/docs/structured-logging
2023-02-04 15:39:20 +01:00
Luís Cobucci
e937256eee
Fix date/time field for GCP logging ( #1758 )
...
We introduced the formatter using the incorrect field, which was making GCP not to extract the correct value from the payload.
This uses the field that actually maps to the expected format.
More info: https://cloud.google.com/logging/docs/structured-logging
2023-02-04 15:38:57 +01:00
Jordi Boggiano
6a28e9d41a
Use facility additional value and not channel to be compat with existing Monolog 3 code
2022-08-20 15:05:05 +02:00
Jordi Boggiano
5eccd17dc5
Add graylog2/gelf-php 2.x support, fixes #1747
2022-08-20 14:09:11 +02:00
Jordi Boggiano
7d31b642bd
Merge branch '2.x'
2022-07-22 16:50:53 +02:00
picass0
a7e5beda57
finishing Syslog formatter ( #1689 )
...
* feat: Syslog formatter
* feat: Syslog formatter, app name
* update syslogFormatter
* Remove legacy syntax
Co-authored-by: Dalibor Karlović <dalibor.karlovic@sigwin.hr >
Co-authored-by: Renat Gabdullin <renatobyj@gmail.com >
2022-07-22 16:17:53 +02:00
Pavel Bychko
320909a1d1
Fix replaceNewlines method to avoid replacing escaped backslashes, closes #1721 , fixes #1720
2022-07-22 16:05:32 +02:00
Jordi Boggiano
7684fae8fa
Merge branch '2.x'
2022-07-22 15:51:15 +02:00
Jordi Boggiano
cf0f4b3814
Handle __toString to serialize objects which are not json-serializable in JsonFormatter, fixes #1733
2022-07-22 15:27:46 +02:00
Jordi Boggiano
34635fdcf5
Add docs
2022-07-22 15:08:12 +02:00
Jordi Boggiano
6fdeea463c
Fix build
2022-07-22 15:07:44 +02:00
Luís Cobucci
197f534d42
Add basic support to Google Cloud Logging format ( #1719 )
...
Google Cloud Logging doesn't show the correct level log when using
JsonFormatter, making observability a bit trickier. This applies minor
tweaks to the default format, allowing log entries to be properly
represented.
There are alternative packages to this but they add fields that aren't
strictly required - also performing `debug_backtrace()` calls that are
usually not desired when in production mode.
This is a backport of https://github.com/Seldaek/monolog/pull/1690
Signed-off-by: Luís Cobucci <lcobucci@gmail.com >
2022-07-22 13:04:51 +02:00
Luís Cobucci
1ae4f609ba
Add basic support to Google Cloud Logging format ( #1690 )
...
Google Cloud Logging doesn't show the correct level log when using
JsonFormatter, making observability a bit trickier. This applies minor
tweaks to the default format, allowing log entries to be properly
represented.
There are alternative packages to this but they add fields that aren't
strictly required - also performing `debug_backtrace()` calls that are
usually not desired when in production mode.
Signed-off-by: Luís Cobucci <lcobucci@gmail.com >
2022-07-22 13:03:58 +02:00
Jordi Boggiano
b3451b008b
Merge branch '2.x' into main
2022-05-10 11:53:02 +02:00
Jordi Boggiano
1dacc790b9
Remove LevelName enum in favor of a Level::getName method, fixes #1667 ( #1668 )
2022-05-10 11:15:16 +02:00
Lito
c709906d0a
[2.X] Allow stacktraces parser on LineFormatter ( #1665 )
...
* Allow stacktraces parser on LineFormatter
* Added includeStacktraces parse tests
2022-05-09 22:37:14 +02:00
Jan-Eric Ortgies
709cb93aa6
replace deprecated method calls in GelfMessageFormatter ( #1664 )
...
- the getter/setter methods for file, level and facility are deprecated in gelf v1.1
- add those fields as additional instead, as suggested in the gelf spec (https://docs.graylog.org/v1/docs/gelf#gelf-payload-specification )
- update tests to reflect changes
2022-05-08 23:13:55 +02:00
Jordi Boggiano
1181473f4b
Merge branch '2.x' into main
2022-05-08 23:03:49 +02:00
Jordi Boggiano
bd24765917
ElasticSearch v8 support ( #1662 )
...
* ElasticSearch v8 support
* CI updates
Co-authored-by: Thomas Müller <mimmi20@live.de >
2022-05-08 22:23:46 +02:00
Jordi Boggiano
6627c092d8
Add phpstan strict rules and deprecation rules, fix all related issues
2022-04-24 11:08:10 +02:00
Jordi Boggiano
0dac87975c
Add property types to all properties where possible
2022-04-21 21:58:32 +02:00
Jordi Boggiano
7952a83e0c
Move phpdoc to native types
2022-04-20 09:21:58 +02:00
Jordi Boggiano
2695fa86cd
CI fixes
2022-04-19 22:16:53 +02:00
Jordi Boggiano
2d006a8472
Convert level/levelName to enums ( #1656 )
2022-04-19 21:49:03 +02:00
Jordi Boggiano
a3ba6445a4
Cleanups
2022-03-21 14:18:56 +01:00
Jordi Boggiano
5eb9b8ed93
Code cleanups
2022-03-21 14:18:54 +01:00
Jordi Boggiano
400effdd45
Fix some issues, bump phpunit version
2022-03-21 14:18:54 +01:00
Jordi Boggiano
22c8b19358
Add LogRecord class, drop PHP <8.1
2022-03-21 14:18:53 +01:00
Gemma Lynn
b39a394c05
Store native BSON types as-is in the MongoDB formatter ( #1620 )
2022-03-13 21:04:53 +01:00
Jordi Boggiano
4ef5da80ad
Fix CS
2021-07-04 14:04:52 +02:00
patrickkusebauch
76639ef02b
Elastica up to 7 support
2020-12-11 10:55:38 +01:00
Jordi Boggiano
9ce0431191
Add JSON_PARTIAL_OUTPUT_ON_ERROR, closes #1515
2020-12-10 16:22:24 +01:00
Jordi Boggiano
ec146b38bd
Build tweaks
2020-12-09 23:22:08 +01:00
Jordi Boggiano
35a1e4de9b
Fix php8 build
2020-07-08 20:53:16 +02:00
James Gilliland
56a8b31e4b
Assert SoapFail can handle a structured detail
2020-05-15 12:59:17 -05:00
Gabriel Caruso
6038dcb21c
JsonFormatter: add option to ignore empty context
and extra
fields
...
Similar to efe572cb10
.
2020-05-15 13:45:36 +02:00
Jordi Boggiano
f279285232
Fix tests, invalid UTF-8 is now returning �s instead of being converted to possibly valid ISO-8559-15
2020-05-11 22:18:36 +02:00
Jordi Boggiano
a8a0dbb778
Merge branch '1.x'
2019-12-20 14:53:43 +01:00
theravel
9621075c0f
Fix JSON formatting of resource type, closes #1410
2019-12-20 14:49:27 +01:00
Jordi Boggiano
4e19f3c585
Merge branch '1.x'
2019-11-13 10:58:42 +01:00
Jordi Boggiano
f97cc755af
Fix 5.3/5.4 builds
2019-11-12 22:28:59 +01:00
Jordi Boggiano
05f6ed7205
Fix php 5.3 syntax
2019-11-12 22:10:50 +01:00