{"payload":{"feedbackUrl":"https://github.com/orgs/community/discussions/53140","repo":{"id":392597661,"defaultBranch":"master","name":"logr","ownerLogin":"pohly","currentUserCanPush":false,"isFork":true,"isEmpty":false,"createdAt":"2021-08-04T07:46:44.000Z","ownerAvatar":"https://avatars.githubusercontent.com/u/22076?v=4","public":true,"private":false,"isOrgOwned":false},"refInfo":{"name":"","listCacheKey":"v0:1703172210.0","currentOid":""},"activityList":{"items":[{"before":"1baa0a893901658fb5dd2a57723f70e1c9b0b2ef","after":"7f7b7fd091c48136ddfa05906258a06c2b4f7e8a","ref":"refs/heads/slogr-api-fix","pushedAt":"2023-12-21T15:30:31.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: fix unintended API break in v0.8.0\n\nlogr v0.7.0 had slogr.NewSlogHandler. We must keep that function for API\ncompatibility. https://github.com/go-logr/logr/pull/237/files#r1434203442\naccidentally renamed it.","shortMessageHtmlLink":"slogr: fix unintended API break in v0.8.0"}},{"before":"d8a080de429094db8793beba5399458a5caddc9b","after":"1baa0a893901658fb5dd2a57723f70e1c9b0b2ef","ref":"refs/heads/slogr-api-fix","pushedAt":"2023-12-21T15:25:20.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: fix unintended API break in v0.8.0\n\nlogr v0.7.0 had slogr.NewSlogHandler. We must keep that function for API\ncompatibility. https://github.com/go-logr/logr/pull/237/files#r1434203442\naccidentally renamed it.","shortMessageHtmlLink":"slogr: fix unintended API break in v0.8.0"}},{"before":null,"after":"d8a080de429094db8793beba5399458a5caddc9b","ref":"refs/heads/slogr-api-fix","pushedAt":"2023-12-21T15:23:30.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: fix unintended API break in v0.8.0\n\nlogr v0.7.0 had slogr.NewSlogHandler. We must keep that function for API\ncompatibility. https://github.com/go-logr/logr/pull/237/files#r1434203442\naccidentally renamed it.","shortMessageHtmlLink":"slogr: fix unintended API break in v0.8.0"}},{"before":"5572aeff9c3ab8317346fd6157d9a8bde6ef3da5","after":"ffd51a49842ac6e3883b972fa0a9f180eaccae6c","ref":"refs/heads/withgroup-sink-fix","pushedAt":"2023-12-04T13:51:33.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"unit tests with full SlogSink mock implementation\n\nThis turns testLogSink into an implementation of SlogSink if slog is supported,\nthen runs through some scenarios where values get added using different APIs.\nThe end result gets compared by formatting with the slog JSON handler because\nthat is easier than writing custom code for a deep-equal comparison of slog\nattributes.\n\nThe \"with-group-and-logr-values\" is the case which was broken.","shortMessageHtmlLink":"unit tests with full SlogSink mock implementation"}},{"before":"9c561869bae5152076174332a8e1298a65c15ad8","after":"5572aeff9c3ab8317346fd6157d9a8bde6ef3da5","ref":"refs/heads/withgroup-sink-fix","pushedAt":"2023-12-04T13:23:24.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"unit tests with full SlogSink mock implementation\n\nThis turns testLogSink into an implementation of SlogSink if slog is supported,\nthen runs through some scenarios where values get added using different APIs.\nThe end result gets compared by formatting with the slog JSON handler because\nthat is easier than writing custom code for a deep-equal comparison of slog\nattributes.\n\nThe \"with-group-and-logr-values\" is the case which was broken.","shortMessageHtmlLink":"unit tests with full SlogSink mock implementation"}},{"before":null,"after":"9c561869bae5152076174332a8e1298a65c15ad8","ref":"refs/heads/withgroup-sink-fix","pushedAt":"2023-12-04T12:37:41.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"unit tests with full SlogSink mock implementation\n\nThis turns testLogSink into an implementation of SlogSink if slog is supported,\nthen runs through some scenarios where values get added using different APIs.\nThe end result gets compared by formatting with the slog JSON handler because\nthat is easier than writing custom code for a deep-equal comparison of slog\nattributes.\n\nThe \"with-group-and-logr-values\" is the case which was broken.","shortMessageHtmlLink":"unit tests with full SlogSink mock implementation"}},{"before":null,"after":"09a064eba0a130d1bbe3326e7fbc0c55776a6d5a","ref":"refs/heads/debug-level","pushedAt":"2023-12-03T15:29:54.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"define debug level and helper method\n\nTraditionally, logr has not had pre-defined levels and left the choice of\nconsistent levels to users. When Go introduced slog, some standardized numeric\nlevels were defined.\n\nlogr doesn't support levels \"more important\" than 0, but \"debug\" = 4 =\n-slog.LevelDebug is possible. To ensure alignment with slog it makes sense to\ndefine that level as a special constant (for use with V) and to have a helper\nfunction which corresponds to V(4).Info.","shortMessageHtmlLink":"define debug level and helper method"}},{"before":"ca4a15b75ca78b8f2db2de3e41b660c810ef5b9e","after":"f1edf4f6aed3da9f4599674ea66e013fd37a5446","ref":"refs/heads/slog-context-in-logr","pushedAt":"2023-11-30T20:42:09.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"support a slog.Logger pointer in a context\n\nConversion is done on demand. A program which uses either slog or logr for\nlogging remains as efficient as before. What is less efficient is storing a\nlogger of one type and then retrieving it as the other.\n\nIdeally, reusable packages should avoid using a slog.Logger and prefer\nlogr.Logger instead when retrieving a logger from a context. There is a\nsignificant amount of packages which already work that way (Kubernetes and\nrelated packages), while storing and retrieving a logr.Logger is new and not\ndone anywhere yet. Emulating existing behavior ensures better performance.","shortMessageHtmlLink":"support a slog.Logger pointer in a context"}},{"before":"9ac998326cdc223355affa6baeab839316117be4","after":"ca4a15b75ca78b8f2db2de3e41b660c810ef5b9e","ref":"refs/heads/slog-context-in-logr","pushedAt":"2023-11-30T09:04:05.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"support a slog.Logger pointer in a context\n\nConversion is done on demand. A program which uses either slog or logr for\nlogging remains as efficient as before. What is less efficient is storing a\nlogger of one type and then retrieving it as the other.\n\nIdeally, reusable packages should avoid using a slog.Logger and prefer\nlogr.Logger instead when retrieving a logger from a context. There is a\nsignificant amount of packages which already work that way (Kubernetes and\nrelated packages), while storing and retrieving a logr.Logger is new and not\ndone anywhere yet. Emulating existing behavior ensures better performance.","shortMessageHtmlLink":"support a slog.Logger pointer in a context"}},{"before":"277269c0ab51d2701b4cfe6618bcbb3cb86c7ed6","after":"9ac998326cdc223355affa6baeab839316117be4","ref":"refs/heads/slog-context-in-logr","pushedAt":"2023-11-29T17:41:59.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"document slog support in logr package\n\nThe old API isn't going away, so the matching functions cross-reference each\nother.","shortMessageHtmlLink":"document slog support in logr package"}},{"before":"4482fc755686a043389f0de24abeea8e43b8b683","after":"277269c0ab51d2701b4cfe6618bcbb3cb86c7ed6","ref":"refs/heads/slog-context-in-logr","pushedAt":"2023-11-28T20:15:15.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"document slog support in logr package\n\nThe old API isn't going away, so the matching functions cross-reference each\nother.","shortMessageHtmlLink":"document slog support in logr package"}},{"before":null,"after":"4482fc755686a043389f0de24abeea8e43b8b683","ref":"refs/heads/slog-context-in-logr","pushedAt":"2023-11-26T16:59:28.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"support a slog.Logger pointer in a context\n\nConversion is done on demand. A program which uses either slog or logr for\nlogging remains as efficient as before. What is less efficient is storing a\nlogger of one type and then retrieving it as the other.\n\nIdeally, reusable packages should avoid using a slog.Logger and prefer\nlogr.Logger instead when retrieving a logger from a context. There is a\nsignificant amount of packages which already work that way (Kubernetes and\nrelated packages), while storing and retrieving a logr.Logger is new and not\ndone anywhere yet. Emulating existing behavior ensures better performance.","shortMessageHtmlLink":"support a slog.Logger pointer in a context"}},{"before":"1d7c75de251a7ba69638a72795f7f4b83b35b696","after":"6a76263a7619af653dcdb892421bca997c1b9504","ref":"refs/heads/slog-interoperability","pushedAt":"2023-10-23T18:44:51.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"docs: interoperability with slog\n\nThis assumes that context helper\nfunctions (https://github.com/go-logr/logr/pull/213) for slog will not get\nmerged. If that is the consensus, then this documentation should be the last\nmissing piece for slog support in logr.","shortMessageHtmlLink":"docs: interoperability with slog"}},{"before":"10757e87bf537ccfca7cdca08229f03f0d5f0996","after":"1d7c75de251a7ba69638a72795f7f4b83b35b696","ref":"refs/heads/slog-interoperability","pushedAt":"2023-09-13T16:03:28.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"docs: interoperability with slog\n\nThis assumes that context helper\nfunctions (https://github.com/go-logr/logr/pull/213) for slog will not get\nmerged. If that is the consensus, then this documentation should be the last\nmissing piece for slog support in logr.","shortMessageHtmlLink":"docs: interoperability with slog"}},{"before":"e164f61f6c8445406ecfe98587f6e3f9a9cb81cb","after":"10757e87bf537ccfca7cdca08229f03f0d5f0996","ref":"refs/heads/slog-interoperability","pushedAt":"2023-09-13T11:41:30.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"docs: interoperability with slog\n\nThis assumes that context helper\nfunctions (https://github.com/go-logr/logr/pull/213) for slog will not get\nmerged. If that is the consensus, then this documentation should be the last\nmissing piece for slog support in logr.","shortMessageHtmlLink":"docs: interoperability with slog"}},{"before":"58315c26a3d33ce4ee7bf230a10c789b1eac0676","after":"e164f61f6c8445406ecfe98587f6e3f9a9cb81cb","ref":"refs/heads/slog-interoperability","pushedAt":"2023-09-13T10:02:49.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"docs: interoperability with slog\n\nThis assumes that context helper\nfunctions (https://github.com/go-logr/logr/pull/213) for slog will not get\nmerged. If that is the consensus, then this documentation should be the last\nmissing piece for slog support in logr.","shortMessageHtmlLink":"docs: interoperability with slog"}},{"before":null,"after":"58315c26a3d33ce4ee7bf230a10c789b1eac0676","ref":"refs/heads/slog-interoperability","pushedAt":"2023-09-13T10:01:37.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"docs: interoperability with slog\n\nThis assumes that context helper\nfunctions (https://github.com/go-logr/logr/pull/213) for slog will not get\nmerged. If that is the consensus, then this documentation should be the last\nmissing piece for slog support in logr.","shortMessageHtmlLink":"docs: interoperability with slog"}},{"before":"374a35adbef80713aecb77ab985dc1a7a783e8ca","after":"a53aadb60364cee46bdaabad04f16915818117e1","ref":"refs/heads/enabled-calldepth","pushedAt":"2023-09-03T18:47:57.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"Enabled: always must skip two levels\n\nklog does stack unwinding in `LogSink.Enabled` to implement per-source code\nverbosity thresholds (`-vmodule`). This worked for `logger.Info` and\n`logger.Error` because the code was written such that it matches how logr is\nimplemented (Logger.Info -> Logger.Enabled -> LogSink.Enabled).\n\nIt did not work for direct calls (`if logger.Enabled`) because then the call\nchain is `Logger.Enabled -> LogSink.Enabled`. That callchain is less common, so\nto fix this problem the callchains get arranges so that all calls go through\none additional intermediate level.\n\nThis is unnecessary extra work, but it is necessary to avoid breaking the more\ncommon normal logging calls with klog and -vmodule.","shortMessageHtmlLink":"Enabled: always must skip two levels"}},{"before":null,"after":"374a35adbef80713aecb77ab985dc1a7a783e8ca","ref":"refs/heads/enabled-calldepth","pushedAt":"2023-09-02T21:01:51.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"Enabled: always must skip two levels\n\nklog does stack unwinding in `LogSink.Enabled` to implement per-source code\nverbosity thresholds (`-vmodule`). This worked for `logger.Info` and\n`logger.Error` because the code was written such that it matches how logr is\nimplemented (Logger.Info -> Logger.Enabled -> LogSink.Enabled).\n\nIt did not work for direct calls (`if logger.Enabled`) because then the call\nchain is `Logger.Enabled -> LogSink.Enabled`. That callchain is less common, so\nto fix this problem the callchains get arranges so that all calls go through\none additional intermediate level.\n\nThis is unnecessary extra work, but it is necessary to avoid breaking the more\ncommon normal logging calls with klog and -vmodule.","shortMessageHtmlLink":"Enabled: always must skip two levels"}},{"before":null,"after":"dd6aa8712486774cf96cea1f97035a48226dd664","ref":"refs/heads/slog-context","pushedAt":"2023-08-27T20:18:46.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add context support\n\nThe normal logr API for storing and retrieving a logger is used.\nThis is necessary to ensure interoperability.\n\nThe downside is that storing a slog.Handler and retrieving it again is more\ncostly than storing and retrieving a logr.Logger, because additional\nallocations are needed.","shortMessageHtmlLink":"slogr: add context support"}},{"before":"6cb9afb27c88b9137d3f9594904e6d04a65b32f7","after":"34cdda3404e04e02fb9a04784b56c95ca70afb9e","ref":"refs/heads/slog-sink","pushedAt":"2023-08-27T17:52:53.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add SlogSink\n\nA LogSink may implement this additional interface if it wants to support\nlogging through slog better. Doing so addresses several issues:\n\n- stack unwinding gets avoided in favor of logging the pre-recorded PC\n- proper grouping of key/value pairs via WithGroup\n- verbosity levels > slog.LevelInfo can be recorded\n- less overhead\n\nA LogSink implementation which wants to provide a `New*Handler() slog.Handler`\nfunction can either implement a second type (required because the prototype of\nthe Enabled method conflicts) or use `logr.NewSlogHandler`. The latter is\nbetter because then conversion back-and-forth works. The overhead for the\nadditional wrapper should be minimal.","shortMessageHtmlLink":"slogr: add SlogSink"}},{"before":"71b33dce969d366d8865a56217e48c041c01aa98","after":"6cb9afb27c88b9137d3f9594904e6d04a65b32f7","ref":"refs/heads/slog-sink","pushedAt":"2023-08-25T13:31:18.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add SlogSink\n\nA LogSink may implement this additional interface if it wants to support\nlogging through slog better. Doing so addresses several issues:\n\n- stack unwinding gets avoided in favor of logging the pre-recorded PC\n- proper grouping of key/value pairs via WithGroup\n- verbosity levels > slog.LevelInfo can be recorded\n- less overhead\n\nA LogSink implementation which wants to provide a `New*Handler() slog.Handler`\nfunction can either implement a second type (required because the prototype of\nthe Enabled method conflicts) or use `logr.NewSlogHandler`. The latter is\nbetter because then conversion back-and-forth works. The overhead for the\nadditional wrapper should be minimal.","shortMessageHtmlLink":"slogr: add SlogSink"}},{"before":"ae8aebdb8fb50061695a184aa36e4d645218a1d6","after":"71b33dce969d366d8865a56217e48c041c01aa98","ref":"refs/heads/slog-sink","pushedAt":"2023-08-25T09:53:58.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add SlogSink\n\nA LogSink may implement this additional interface if it wants to support\nlogging through slog better. Doing so addresses several issues:\n\n- stack unwinding gets avoided in favor of logging the pre-recorded PC\n- proper grouping of key/value pairs via WithGroup\n- verbosity levels > slog.LevelInfo can be recorded\n- less overhead\n\nA LogSink implementation which wants to provide a `New*Handler() slog.Handler`\nfunction can either implement a second type (required because the prototype of\nthe Enabled method conflicts) or use `logr.NewSlogHandler`. The latter is\nbetter because then conversion back-and-forth works. The overhead for the\nadditional wrapper should be minimal.","shortMessageHtmlLink":"slogr: add SlogSink"}},{"before":"29b24ec67ea81676e1bfa131c3733512ace98fca","after":"ae8aebdb8fb50061695a184aa36e4d645218a1d6","ref":"refs/heads/slog-sink","pushedAt":"2023-08-25T07:12:41.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add SlogSink\n\nA LogSink may implement this additional interface if it wants to support\nlogging through slog better. Doing so addresses several issues:\n\n- stack unwinding gets avoided in favor of logging the pre-recorded PC\n- proper grouping of key/value pairs via WithGroup\n- verbosity levels > slog.LevelInfo can be recorded\n- less overhead\n\nA LogSink implementation which wants to provide a `New*Handler() slog.Handler`\nfunction can either implement a second type (required because the prototype of\nthe Enabled method conflicts) or use `logr.NewSlogHandler`. The latter is\nbetter because then conversion back-and-forth works. The overhead for the\nadditional wrapper should be minimal.","shortMessageHtmlLink":"slogr: add SlogSink"}},{"before":"73abb9de7a5828a8723d47874dad7de429616b0e","after":"6964a54ef8695fa8ca1949ce897c451aa62231e8","ref":"refs/heads/slog-glue","pushedAt":"2023-08-23T10:33:03.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: restore original backend when converting back and forth\n\nThis works both ways by checking whether the backend is one of our own\nwrappers. There's one exception: when the verbosity level was modified, we\ncannot use the original slog.Handler because it doesn't know about that\nmodification.\n\nThe downside is that we have to adjust the stack unwinding each time a record\nis handled, because we need the original sink without that adjustment. This\nonly gets done when actually emitting a log record, so that overhead should be\nokay. It will disappear entirely once sinks directly support writing a\nslog.Event.\n\nA second copy would work, but then that copy would need to be updated alongside\nthe other one in WithAttrs, which causes overhead along a callchain also when\nthe log record does not get emitted. The code also would be more complex.","shortMessageHtmlLink":"slogr: restore original backend when converting back and forth"}},{"before":"82c90f2c09e643b6fea764897bc0ce4221ca2173","after":"73abb9de7a5828a8723d47874dad7de429616b0e","ref":"refs/heads/slog-glue","pushedAt":"2023-08-23T10:31:01.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: restore original backend when converting back and forth\n\nThis works both ways by checking whether the backend is one of our own\nwrappers. There's one exception: when the verbosity level was modified, we\ncannot use the original slog.Handler because it doesn't know about that\nmodification.\n\nThe downside is that we have to adjust the stack unwinding each time a record\nis handled, because we need the original sink without that adjustment. This\nonly gets done when actually emitting a log record, so that overhead should be\nokay. It will disappear entirely once sinks directly support writing a\nslog.Event.\n\nA second copy would work, but then that copy would need to be updated alongside\nthe other one in WithAttrs, which causes overhead along a callchain also when\nthe log record does not get emitted. The code also would be more complex.","shortMessageHtmlLink":"slogr: restore original backend when converting back and forth"}},{"before":"fb2ab33c510a838ae0a3fbb3fd76e7ceafaecf62","after":"82c90f2c09e643b6fea764897bc0ce4221ca2173","ref":"refs/heads/slog-glue","pushedAt":"2023-08-23T10:29:51.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: restore original backend when converting back and forth\n\nThis works both ways by checking whether the backend is one of our own\nwrappers. There's one exception: when the verbosity level was modified, we\ncannot use the original slog.Handler because it doesn't know about that\nmodification.\n\nThe downside is that we have to adjust the stack unwinding each time a record\nis handled, because we need the original sink without that adjustment. This\nonly gets done when actually emitting a log record, so that overhead should be\nokay. It will disappear entirely once sinks directly support writing a\nslog.Event.\n\nA second copy would work, but then that copy would need to be updated alongside\nthe other one in WithAttrs, which causes overhead along a callchain also when\nthe log record does not get emitted. The code also would be more complex.","shortMessageHtmlLink":"slogr: restore original backend when converting back and forth"}},{"before":"b50ee609cea1c1b78e88b64821de8e92d3ef6a0d","after":"fb2ab33c510a838ae0a3fbb3fd76e7ceafaecf62","ref":"refs/heads/slog-glue","pushedAt":"2023-08-23T10:29:19.000Z","pushType":"push","commitsCount":1,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: restore original backend when converting back and forth\n\nThis works both ways by checking whether the backend is one of our own\nwrappers. There's one exception: when the verbosity level was modified, we\ncannot use the original slog.Handler because it doesn't know about that\nmodification.\n\nThe downside is that we have to adjust the stack unwinding each time a record\nis handled, because we need the original sink without that adjustment. This\nonly gets done when actually emitting a log record, so that overhead should be\nokay. It will disappear entirely once sinks directly support writing a\nslog.Event.\n\nA second copy would work, but then that copy would need to be updated alongside\nthe other one in WithAttrs, which causes overhead along a callchain also when\nthe log record does not get emitted. The code also would be more complex.","shortMessageHtmlLink":"slogr: restore original backend when converting back and forth"}},{"before":"29c63825fbfbd09f8f7f88de1517bcccc57cb076","after":"b50ee609cea1c1b78e88b64821de8e92d3ef6a0d","ref":"refs/heads/slog-glue","pushedAt":"2023-08-22T06:11:05.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add glue code for logging to slog.Handler and with slog.Logger\n\nInteroperability with log/slog from Go 1.21 includes the ability to use a\nslog.Handler as backend with logr.Logger as frontend and vice versa.\n\nThis is only the initial step. In particular writing with slog.Logger to\na logr.LogSink is not working well (time stamp and call site from\nrecord get ignored). Further work is needed to improve this.","shortMessageHtmlLink":"slogr: add glue code for logging to slog.Handler and with slog.Logger"}},{"before":"57acb9d255da28cf765d9a2b0f70c946de464d9e","after":"29c63825fbfbd09f8f7f88de1517bcccc57cb076","ref":"refs/heads/slog-glue","pushedAt":"2023-08-21T17:46:25.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"pohly","name":"Patrick Ohly","path":"/pohly","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/22076?s=80&v=4"},"commit":{"message":"slogr: add glue code for logging to slog.Handler and with slog.Logger\n\nInteroperability with log/slog from Go 1.21 includes the ability to use a\nslog.Handler as backend with logr.Logger as frontend and vice versa.\n\nThis is only the initial step. In particular writing with slog.Logger to\na logr.LogSink is not working well (time stamp and call site from\nrecord get ignored). Further work is needed to improve this.","shortMessageHtmlLink":"slogr: add glue code for logging to slog.Handler and with slog.Logger"}}],"hasNextPage":true,"hasPreviousPage":false,"activityType":"all","actor":null,"timePeriod":"all","sort":"DESC","perPage":30,"cursor":"djE6ks8AAAADz7CsgwA","startCursor":null,"endCursor":null}},"title":"Activity ยท pohly/logr"}