Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

textlogger write through #363

Merged
merged 2 commits into from
Mar 1, 2023
Merged

Conversation

pohly
Copy link

@pohly pohly commented Jan 24, 2023

What this PR does / why we need it:

kubernetes/kubernetes#114672 uses the textlogger for output routing instead of the legacy code in klog. However, this changes the output for unstructured output (gets quoted) and makes it slower (double encoding).

To avoid both, this PR adds an API for setting a logger that can take formatted data from klog and then writes it directly.

Release note:

NONE

This is meant to be used with textlogger for the non-structured log calls to
avoid double encoding.
Textlogger can (but doesn't have to) be used to write klog's unstructured
output from calls like Infof directly to the output stream. This has two
advantages:
- traditional output remains exactly the same as before, which is particularly
  important for multi-line messages because those get quoted otherwise
- performance is better because re-encoding the output string is avoided
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 24, 2023
@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jan 24, 2023
@logicalhan
Copy link
Member

/assign @serathius @thockin
/triage accepted

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 26, 2023
@serathius
Copy link

Overall comment whether we need this temporary solution to avoid double encoding.

As discussed on WG meeting, I'm not necessary against performance regressions if:

  • If avoids hacks and allows more simplicity
  • Doesn't break out performance goals. For K8s our canonical performance benchmark is scalability tests. cc @wojtek-t

@pohly
Copy link
Author

pohly commented Jan 27, 2023

As discussed on WG meeting, I'm not necessary against performance regressions

It's not just the performance regressions, the output also becomes less readable. Before:

I0127 11:50:17.513183   32691 logger.go:77] Log using Infof, key: value
I0127 11:50:17.513222   32691 logger.go:83] Log with sensitive key, data: {"secret"}

With double encoding:

I0127 11:51:10.937134   33070 logger.go:77] "Log using Infof, key: value\n"
I0127 11:51:10.937207   33070 logger.go:83] "Log with sensitive key, data: {\"secret\"}\n"

I forgot to point that out in the WG meeting.

@pohly
Copy link
Author

pohly commented Jan 27, 2023

Doesn't break out performance goals. For K8s our canonical performance benchmark is scalability tests.

I consider that the "acceptance test" for logging changes. But I think we should also strive to achieve the same results with as little extra CPU cycles as possible.

@pohly pohly changed the title RFC: textlogger write through textlogger write through Feb 3, 2023
@serathius
Copy link

Overall lgtm, however name WriteKlogBuffer is little contentious. If I understand it will not be a full fledged feature, just a a temporary workaround to avoid double encoding until we migrate k/k to structured logging. At that point it will not be useful and can be removed. Is that right?

If that so WriteKlogBuffer makes somewhat sense as it a workaround for klog. However It would be clearer if it's called something like KlogEncoderBypass or something similar.

Outside of name, I think WriteKlogBuffer comment is somewhat misleading, it nicely documents the function to make it easier for use, however I don't think we should recommend using it. If the motivation that I wrote above it true, than comment should clearly state:

  • This function is a klog specific workaround to avoid double encoding.
  • It's only until k/k is migrated to structured logging, after that will be removed.
  • It should not be used by any other logger, please don't use it

@pohly
Copy link
Author

pohly commented Feb 3, 2023

If I understand it will not be a full fledged feature, just a a temporary workaround to avoid double encoding until we migrate k/k to structured logging. At that point it will not be useful and can be removed. Is that right?

Unfortunately not. It needs to become part of the klog v2 API, which means we cannot remove it even when Kubernetes itself no longer needs it.

it nicely documents the function to make it easier for use, however I don't think we should recommend using it.

As it has to become officially part of the API, we should treat it like that and document how to use it.

@pohly
Copy link
Author

pohly commented Feb 3, 2023

I've been thinking about avoiding this public API, but both klog and textlogger are designed to be completely independent from each other. They just share some internal packages.

Moving the klog state into such an internal package wouldn't help: textlogger then could provide an API to install itself there, but it would make textlogger depend on quite a bit of extra baggage - IMHO not a good solution.

@serathius
Copy link

cc @liggitt @dims who might be interested in the problem

@banjoh
Copy link

banjoh commented Feb 8, 2023

I'm keen to see how this PR progresses. I'm blocked by the same problem. I'm implementing my own logr.Logger and setting it using klog.SetLogger(logger). My log output ends up with newlines like below. NOTE: I'm not using textlogger meaning this issue will affect anyone who implements their own logger, I think.

[evans] $ ./bin/app -v=2
I0208 16:27:50.193136   72871 root.go:58] "Log message from klog\n"
I0208 16:27:50.193154   72871 root.go:59] "Info message from klog with verbosity 1\n"
I0208 16:27:50.193170   72871 root.go:60] "Infof message from klog with verbosity 1: arg1\n"

Without my logger

I0208 16:29:03.835147   73224 root.go:54] Log message from klog
I0208 16:29:03.835168   73224 root.go:55] Info message from klog with verbosity 1
I0208 16:29:03.835196   73224 root.go:56] Infof message from klog with verbosity 1: arg1

FWIW I tested using https://github.com/go-logr/stdr and https://github.com/go-logr/glogr with the same results, as I expected.

@pohly
Copy link
Author

pohly commented Feb 8, 2023

I'm keen to see how this PR progresses. I'm blocked by the same problem. I'm implementing my own logr.Logger and setting it using klog.SetLogger(logger).

So do you intend to use WriteKlogBuffer in combination with your logger? How? If you just pass through the log output unchanged, won't that lead to a mixture of different formats (klog text format, structured logging from your logger)? Is that desired?

With the intended usage in combination with textlogger, all messages would be using klog text format, so there is no such inconsistency.

@banjoh
Copy link

banjoh commented Feb 8, 2023

This is what I intend to achieve.

I would like to intercept logs (with whatever formatting they are in) and write them to a separate file (not the one created when you pass in log_file, or log_dir). Exploring the library led me to writing my own logr.Logger and passing it to klog.SetLogger(logger) where I'd have my implementation.

You ask why? Our library heavily uses k8s client-go and we would like to grab logs emitted by the library.

If you just pass through the log output unchanged, won't that lead to a mixture of different formats (klog text format, structured logging from your logger)? Is that desired?

I'm looking for the lowest denominator in the framework to intercept the logs and write elsewhere. My logger will not do any formatting. I ended up using textLogger to retain as much of the formatting as possible. By the look of things, WriteKlogBuffer looks promising.

I'm open to suggestions here.

@banjoh
Copy link

banjoh commented Feb 8, 2023

I addition to the k8s client-go dependency, we would like to use klog's verbosity levels. I know logr loggers have the same interfaces but I thought it would be better to sick with one logging implementation.

@pohly
Copy link
Author

pohly commented Feb 8, 2023

From a brief look at your LogSink implementation it seems that you should be able to use the textlogger directly?

Or what functionality is missing?

@banjoh
Copy link

banjoh commented Feb 8, 2023

Or what functionality is missing?

I'm missing the part where I can "tee" the logs elsewhere (e.g to a file). I added this change to demonstrate what I mean. Ignore the double formatting done by funcr.Formatter. Its there for demonstration purposes only.

Sample invocation

func main() {
	klog.SetLogger(logger.New(logger.Options{
		Verbosity: 1,
	}))
	klog.Info("Hello, world!")
}

Output looks like this

[evans] $ go run main.go
I0208 18:46:40.134371   89450 main.go:12] "Hello, world!\n"
TEE'd LOG:  "level"=0 "msg"="Hello, world!\n"

With your PR, I'd like to see if all I need is to implement WriteKlogBuffer instead of trying to route Info and Error calls to my logger.

@banjoh
Copy link

banjoh commented Feb 8, 2023

// The buffer will contain exactly the same data that klog normally would write
// into its own output stream(s). In particular this includes the header, if
// klog is configured to write one. The callback then can divert that data into
// its own output streams. The buffer may or may not end in a line break.

This comment is what led me to think this change might suite my needs

@pohly
Copy link
Author

pohly commented Feb 8, 2023

textlogger writes to an io.Writer, set for the config with Output. The (implicit) guarantee is that there will be one Write call per message - I probably should make that explicit in the documentation.

The implementation of that io.Writer can redirect the actual bytes however it wants. I am using that in kubernetes/kubernetes#114672 to write info messages to stdout and error messages to stderr, with buffering of info messages.

@pohly
Copy link
Author

pohly commented Feb 8, 2023

So if your goal is to redirect output, then both textlogger and this PR will be relevant for you. My point was just that you don't need to wrap textlogger in your own sink for that.

@banjoh
Copy link

banjoh commented Feb 9, 2023

My point was just that you don't need to wrap textlogger in your own sink for that.

Thanks for the call out. I'll adjust my code accordingly.

textlogger writes to an io.Writer, set for the config with Output. The (implicit) guarantee is that there will be one Write call per message - I probably should make that explicit in the documentation.

This will do the trick with my code looking like this now. Its much simpler and cleaner.

type MyWriter struct{}

func (w *MyWriter) Write(p []byte) (n int, err error) {
	// TODO: Tee my logs to other destinations using https://pkg.go.dev/io#MultiWriter
	fmt.Printf("Written: %s", p)
	return 0, nil
}

// Implementation
klog.SetLogger(textlogger.NewLogger(textlogger.NewConfig(
	textlogger.Verbosity(1),
	textlogger.Output(&logger.MyWriter{}),
)))
Written: I0209 10:10:03.647496   14593 root.go:49] "Hello World!\n"
Written: I0209 10:10:03.647514   14593 root.go:50] "Hello World! with verbosity 1\n"

As a side note, setting the output in klog like so klog.SetOutput(&logger.MyWriter{}) does not have my writer called, which I found a bit misleading. I'm not sure in what conditions it should work. Here is a simple example

package main

import (
	"fmt"

	"k8s.io/klog/v2"
)

type MyWriter struct{}
func (w *MyWriter) Write(p []byte) (n int, err error) {
	fmt.Printf("Written: %s", p)
	return 0, nil
}

func main() {
	klog.SetOutput(&MyWriter{})
	klog.Info("Hello, world!")
}
[evans] $ go run main.go
I0209 10:29:53.239060   17318 main.go:19] Hello, world!

I also noticed this comment claiming the textlogger to be experimental. Are there plans to bring the API to stability?

@pohly
Copy link
Author

pohly commented Feb 9, 2023

As a side note, setting the output in klog like so klog.SetOutput(&logger.MyWriter{}) does not have my writer called, which I found a bit misleading.

Was that when you also did klog.SetLogger? When a logger is set, klog should hand over all log entries to that logger and not use the output file.

Never mind, I didn't read carefully. SetOutput only has an effect when klog is not configured to write to stderr. With --logtostderr=false it starts using the file, potentially multiple times per log entry (!), once for each severity level. It's really baroque.

I also noticed this comment claiming the textlogger to be experimental. Are there plans to bring the API to stability?

Yes, as soon as we are confident that the API is sane and no longer needs to be changed in incompatible ways. I think it's almost there, only #368 needs to be merged first.

@banjoh
Copy link

banjoh commented Feb 20, 2023

@pohly anyway I can be of assistance here, or is this change waiting for someone to review and give a thumbs up?

@pohly
Copy link
Author

pohly commented Feb 20, 2023

Someone needs to review and decide whether it's worth adding this to klog.

@dims
Copy link
Member

dims commented Mar 1, 2023

Let's not beat ourselves up if WriteKlogBuffer doesn't feel appropriate. it's still in a separate package with a very few set of references, hoping it stays that way:
https://cs.github.com/?scopeName=All+repos&scope=&q=%2Fklog%5C%2Fv2%5C%2Ftextlogger%2F

/approve
/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 1, 2023
@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dims, pohly

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 1, 2023
@k8s-ci-robot k8s-ci-robot merged commit d7fc505 into kubernetes:main Mar 1, 2023
TylerHelmuth referenced this pull request in open-telemetry/opentelemetry-collector-contrib Dec 19, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [k8s.io/klog](https://togithub.com/kubernetes/klog) | require | major
| `v1.0.0` -> `v2.110.1` |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>kubernetes/klog (k8s.io/klog)</summary>

###
[`v2.110.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.110.1):
Prepare klog release for Kubernetes v1.29 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.100.1...v2.110.1)

#### What's Changed

- fix: SetLogger via klog.SetLogger will output an unexpected newline by
[@&#8203;aimuz](https://togithub.com/aimuz) in
[https://github.com/kubernetes/klog/pull/378](https://togithub.com/kubernetes/klog/pull/378)
- resolve comments warning by
[@&#8203;lowang-bh](https://togithub.com/lowang-bh) in
[https://github.com/kubernetes/klog/pull/379](https://togithub.com/kubernetes/klog/pull/379)
- stderrthreshold: fix flag comment by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/376](https://togithub.com/kubernetes/klog/pull/376)
- enable "go vet" checks for parameters by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/390](https://togithub.com/kubernetes/klog/pull/390)
- promote experimental code to stable by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/392](https://togithub.com/kubernetes/klog/pull/392)
- golangci-lint action by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/380](https://togithub.com/kubernetes/klog/pull/380)
- output: handle WithName like zapr does by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/391](https://togithub.com/kubernetes/klog/pull/391)
- slog support + logr 1.3.0 update by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/384](https://togithub.com/kubernetes/klog/pull/384)

#### New Contributors

- [@&#8203;aimuz](https://togithub.com/aimuz) made their first
contribution in
[https://github.com/kubernetes/klog/pull/378](https://togithub.com/kubernetes/klog/pull/378)
- [@&#8203;lowang-bh](https://togithub.com/lowang-bh) made their first
contribution in
[https://github.com/kubernetes/klog/pull/379](https://togithub.com/kubernetes/klog/pull/379)

**Full Changelog**:
kubernetes/klog@v2.100.1...v2.110.1

###
[`v2.100.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.100.1):
Prepare klog release for Kubernetes v1.28 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.90.1...v2.100.1)

#### What's Changed

- expose logBridge via NewStandardLog() by
[@&#8203;mikedanese](https://togithub.com/mikedanese) in
[https://github.com/kubernetes/klog/pull/369](https://togithub.com/kubernetes/klog/pull/369)
- add Format wrapper by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/374](https://togithub.com/kubernetes/klog/pull/374)
- JSON as fallback encoding by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/375](https://togithub.com/kubernetes/klog/pull/375)

#### New Contributors

- [@&#8203;mikedanese](https://togithub.com/mikedanese) made their first
contribution in
[https://github.com/kubernetes/klog/pull/369](https://togithub.com/kubernetes/klog/pull/369)

**Full Changelog**:
kubernetes/klog@v2.90.1...v2.100.1

###
[`v2.90.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.90.1):
Prepare klog release for Kubernetes v1.27 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.90.0...v2.90.1)

#### What's Changed

- buffer: restore dropping of too large buffers by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/366](https://togithub.com/kubernetes/klog/pull/366)
- ktesting improvements by [@&#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/365](https://togithub.com/kubernetes/klog/pull/365)
- ktesting + textlogger config api by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/368](https://togithub.com/kubernetes/klog/pull/368)
- textlogger write through by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/363](https://togithub.com/kubernetes/klog/pull/363)

**Full Changelog**:
kubernetes/klog@v2.90.0...v2.90.1

###
[`v2.90.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.90.0):
Prepare klog release for Kubernetes v1.27 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.80.1...v2.90.0)

#### What's Changed

- klog: benchmark the overhead when logging is off by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/355](https://togithub.com/kubernetes/klog/pull/355)
- improve textlogger by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/362](https://togithub.com/kubernetes/klog/pull/362)

**Full Changelog**:
kubernetes/klog@v2.80.1...v2.90.0

##### There are some API differences from previous version

    k8s.io/klog/v2/klogr contains incompatible changes:
     - klogger.Enabled: removed
     - klogger.Error: removed
     - klogger.Info: removed

    k8s.io/klog/v2/test contains incompatible changes:
     - InitKlog: changed from func() to func(testing.TB) *flag.FlagSet

###
[`v2.80.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.80.1):
Prepare klog release for Kubernetes v1.26 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.80.0...v2.80.1)

#### What's Changed

- InitFlags concurrency fix by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/349](https://togithub.com/kubernetes/klog/pull/349)

**Full Changelog**:
kubernetes/klog@v2.80.0...v2.80.1

###
[`v2.80.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.80.0):
Prepare klog release for Kubernetes v1.26 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.70.1...v2.80.0)

#### What's Changed

- OWNERS: add harshanarayana by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/342](https://togithub.com/kubernetes/klog/pull/342)
- kvlistformat: fix the issue with display marshalled value for non
string type by
[@&#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/344](https://togithub.com/kubernetes/klog/pull/344)
- Bump version of golang to 1.19 and drop older versions by
[@&#8203;dims](https://togithub.com/dims) in
[https://github.com/kubernetes/klog/pull/345](https://togithub.com/kubernetes/klog/pull/345)

**Full Changelog**:
kubernetes/klog@v2.70.1...v2.80.0

###
[`v2.70.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.70.1):
Prepare klog release for Kubernetes v1.25 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.70.0...v2.70.1)

#### What's Changed

- ktesting: handle test completion by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/337](https://togithub.com/kubernetes/klog/pull/337)
- contextual logging: enable by default again by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/341](https://togithub.com/kubernetes/klog/pull/341)

**Full Changelog**:
kubernetes/klog@v2.70.0...v2.70.1

###
[`v2.70.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.70.0):
Prepare klog release for Kubernetes v1.25 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.60.1...v2.70.0)

#### What's Changed

- logcheck: contextual logging + enhanced checks by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/297](https://togithub.com/kubernetes/klog/pull/297)
- hack/tools: drop dependency on golangci-lint by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/313](https://togithub.com/kubernetes/klog/pull/313)
- StopFlushDaemon: document flushing on shutdown by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/314](https://togithub.com/kubernetes/klog/pull/314)
- logcheck: fix detection of invalid \* regexp in filter by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/315](https://togithub.com/kubernetes/klog/pull/315)
- README.md: clarify -logtostderr by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/319](https://togithub.com/kubernetes/klog/pull/319)
- Trim duplicates by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/324](https://togithub.com/kubernetes/klog/pull/324)
- replace KObjs with KObjSlice by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/322](https://togithub.com/kubernetes/klog/pull/322)
- support logr.Marshaler by [@&#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/325](https://togithub.com/kubernetes/klog/pull/325)
- internal: remove unused TrimDuplicates by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/326](https://togithub.com/kubernetes/klog/pull/326)
- save and restore state by [@&#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/320](https://togithub.com/kubernetes/klog/pull/320)
- GitHub: use apidiff with more recent Go by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/329](https://togithub.com/kubernetes/klog/pull/329)
- remove hack/tools by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/330](https://togithub.com/kubernetes/klog/pull/330)
- GIT-331: fix shadowing key from the kv pair by
[@&#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/332](https://togithub.com/kubernetes/klog/pull/332)
- klog.Fatal backtrace revert by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/328](https://togithub.com/kubernetes/klog/pull/328)
- ktesting: capture log data in memory by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/327](https://togithub.com/kubernetes/klog/pull/327)
- GIT-275: add tests for int and struct keys by
[@&#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/333](https://togithub.com/kubernetes/klog/pull/333)

#### New Contributors

- [@&#8203;harshanarayana](https://togithub.com/harshanarayana) made
their first contribution in
[https://github.com/kubernetes/klog/pull/332](https://togithub.com/kubernetes/klog/pull/332)

**Full Changelog**:
kubernetes/klog@v2.60.1...v2.70.0

###
[`v2.60.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.60.1):
Prepare klog release for Kubernetes v1.24 (Take 6)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.60.0...v2.60.1)

#### What's Changed

- Cleanup OWNERS file by
[@&#8203;serathius](https://togithub.com/serathius) in
[https://github.com/kubernetes/klog/pull/309](https://togithub.com/kubernetes/klog/pull/309)
- dependencies: avoid k8s.io/utils, fork clock code instead by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/310](https://togithub.com/kubernetes/klog/pull/310)
- promote contextual logging APIs to stable by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/311](https://togithub.com/kubernetes/klog/pull/311)

**Full Changelog**:
kubernetes/klog@v2.60.0...v2.60.1

###
[`v2.60.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.60.0):
Prepare klog release for Kubernetes v1.24 (Take 5)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.2...v2.60.0)

#### What's Changed

- SetContextualLogger: remove unintentionally merged API call by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/308](https://togithub.com/kubernetes/klog/pull/308)

**Full Changelog**:
kubernetes/klog@v2.50.2...v2.60.0

###
[`v2.50.2`](https://togithub.com/kubernetes/klog/compare/v2.50.1...v2.50.2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.1...v2.50.2)

###
[`v2.50.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.50.1):
Prepare klog release for Kubernetes v1.24 (Take 4)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.0...v2.50.1)

#### What's Changed

- SetLoggerWithOptions: support flushing by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/306](https://togithub.com/kubernetes/klog/pull/306)

**Full Changelog**:
kubernetes/klog@v2.50.0...v2.50.1

###
[`v2.50.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.50.0):
Prepare klog release for Kubernetes v1.24 (Take 3)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.40.1...v2.50.0)

#### What's Changed

- Panic on empty info with custom logr by
[@&#8203;jklaw90](https://togithub.com/jklaw90) in
[https://github.com/kubernetes/klog/pull/283](https://togithub.com/kubernetes/klog/pull/283)
- Add missing Depth logging functions. by
[@&#8203;s3rj1k](https://togithub.com/s3rj1k) in
[https://github.com/kubernetes/klog/pull/280](https://togithub.com/kubernetes/klog/pull/280)
- fix typo in klog.go by
[@&#8203;cocaccola](https://togithub.com/cocaccola) in
[https://github.com/kubernetes/klog/pull/270](https://togithub.com/kubernetes/klog/pull/270)
- Update README.md by
[@&#8203;noaabarki](https://togithub.com/noaabarki) in
[https://github.com/kubernetes/klog/pull/281](https://togithub.com/kubernetes/klog/pull/281)
- log filter: ignored by V, used during log call by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/290](https://togithub.com/kubernetes/klog/pull/290)
- SetLogger/ClearLogger/SetLogFilter cleanup by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/289](https://togithub.com/kubernetes/klog/pull/289)
- fixes for PR
[#&#8203;280](https://togithub.com/kubernetes/klog/issues/280),
refactoring, textlogger, unit test by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/287](https://togithub.com/kubernetes/klog/pull/287)
- klogr verbosity by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/295](https://togithub.com/kubernetes/klog/pull/295)
- test: fix Go version matrix by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/298](https://togithub.com/kubernetes/klog/pull/298)
- handle panics in MarshalLog, Error, String by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/299](https://togithub.com/kubernetes/klog/pull/299)
- Fix goroutine leak: make flushDaemon stoppable by
[@&#8203;katexochen](https://togithub.com/katexochen) in
[https://github.com/kubernetes/klog/pull/293](https://togithub.com/kubernetes/klog/pull/293)
- structured logging: replacing Fatal/Exit/etc. without loss of flushing
by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/303](https://togithub.com/kubernetes/klog/pull/303)
- contextual logging by [@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/296](https://togithub.com/kubernetes/klog/pull/296)
- remove side effects of tests by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/305](https://togithub.com/kubernetes/klog/pull/305)
- tests: stop testing with Go 1.14 by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/304](https://togithub.com/kubernetes/klog/pull/304)

#### New Contributors

- [@&#8203;jklaw90](https://togithub.com/jklaw90) made their first
contribution in
[https://github.com/kubernetes/klog/pull/283](https://togithub.com/kubernetes/klog/pull/283)
- [@&#8203;s3rj1k](https://togithub.com/s3rj1k) made their first
contribution in
[https://github.com/kubernetes/klog/pull/280](https://togithub.com/kubernetes/klog/pull/280)
- [@&#8203;cocaccola](https://togithub.com/cocaccola) made their first
contribution in
[https://github.com/kubernetes/klog/pull/270](https://togithub.com/kubernetes/klog/pull/270)
- [@&#8203;noaabarki](https://togithub.com/noaabarki) made their first
contribution in
[https://github.com/kubernetes/klog/pull/281](https://togithub.com/kubernetes/klog/pull/281)
- [@&#8203;katexochen](https://togithub.com/katexochen) made their first
contribution in
[https://github.com/kubernetes/klog/pull/293](https://togithub.com/kubernetes/klog/pull/293)

**Full Changelog**:
kubernetes/klog@v2.40.1...v2.50.0

###
[`v2.40.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.40.1):
Prepare klog release for Kubernetes v1.24 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.40.0...v2.40.1)

#### What's Changed

- Using OS targeted go files to separate out the username logic. by
[@&#8203;phillipsj](https://togithub.com/phillipsj) in
[https://github.com/kubernetes/klog/pull/271](https://togithub.com/kubernetes/klog/pull/271)
- Recover from nil pointers when logging by
[@&#8203;dims](https://togithub.com/dims) in
[https://github.com/kubernetes/klog/pull/279](https://togithub.com/kubernetes/klog/pull/279)

#### New Contributors

- [@&#8203;phillipsj](https://togithub.com/phillipsj) made their first
contribution in
[https://github.com/kubernetes/klog/pull/271](https://togithub.com/kubernetes/klog/pull/271)

**Full Changelog**:
kubernetes/klog@v2.40.0...v2.40.1

###
[`v2.40.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.40.0):
Prepare klog release for Kubernetes v1.24

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.30.0...v2.40.0)

#### What's Changed

- structured logging: support values with line breaks by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/273](https://togithub.com/kubernetes/klog/pull/273)
- Fix klog lock release on panic error by
[@&#8203;astraw99](https://togithub.com/astraw99) in
[https://github.com/kubernetes/klog/pull/272](https://togithub.com/kubernetes/klog/pull/272)
- add format test for KObjs by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/276](https://togithub.com/kubernetes/klog/pull/276)
- add Verbose.InfoSDepth by [@&#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/277](https://togithub.com/kubernetes/klog/pull/277)

#### Known Issues

-
[https://github.com/kubernetes/klog/issues/278](https://togithub.com/kubernetes/klog/issues/278)

#### New Contributors

- [@&#8203;astraw99](https://togithub.com/astraw99) made their first
contribution in
[https://github.com/kubernetes/klog/pull/272](https://togithub.com/kubernetes/klog/pull/272)

**Full Changelog**:
kubernetes/klog@v2.30.0...v2.40.0

###
[`v2.30.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.30.0):
Prepare klog release for Kubernetes v1.23 (take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.20.0...v2.30.0)

#### What's Changed

- Fix logcheck exit function by
[@&#8203;luyou86](https://togithub.com/luyou86) in
[https://github.com/kubernetes/klog/pull/265](https://togithub.com/kubernetes/klog/pull/265)
- custom marshaler for ObjectRef by
[@&#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/266](https://togithub.com/kubernetes/klog/pull/266)

#### New Contributors

- [@&#8203;luyou86](https://togithub.com/luyou86) made their first
contribution in
[https://github.com/kubernetes/klog/pull/265](https://togithub.com/kubernetes/klog/pull/265)

**Full Changelog**:
kubernetes/klog@v2.20.0...v2.30.0

###
[`v2.20.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.20.0):
Prepare klog release for Kubernetes v1.23

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.10.0...v2.20.0)

Changes are here :
kubernetes/klog@v2.10.0...v2.20.0

since we moved to logr v1.0.0, there are incompatible changes:

    - klogger.Enabled: changed from func() bool to func(int) bool
- klogger.Info: changed from func(string, ...interface{}) to func(int,
string, ...interface{})
    - klogger.V: removed
- klogger.WithCallDepth: changed from func(int)
github.com/go-logr/logr.Logger to func(int)
github.com/go-logr/logr.LogSink
- klogger.WithName: changed from func(string)
github.com/go-logr/logr.Logger to func(string)
github.com/go-logr/logr.LogSink
- klogger.WithValues: changed from func(...interface{})
github.com/go-logr/logr.Logger to func(...interface{})
github.com/go-logr/logr.LogSink

[`83653a6`](https://togithub.com/kubernetes/klog/commit/83653a6deebf)
Update to newest versions of golang 1.17.x
[`d648c2e`](https://togithub.com/kubernetes/klog/commit/d648c2e42d30)
fix file-based filtering symbolization
[`8ee3d65`](https://togithub.com/kubernetes/klog/commit/8ee3d652c96b)
export ClearLogger
[`4171f3c`](https://togithub.com/kubernetes/klog/commit/4171f3c1be1b)
Switching to logr tag v1.0.0
[`9ab3c2b`](https://togithub.com/kubernetes/klog/commit/9ab3c2b56cb2)
add serathius as approvers of klog

###
[`v2.10.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.10.0):
One more change to support 1.22 release

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.9.0...v2.10.0)

Changes are here :
kubernetes/klog@v2.9.0...v2.10.0

new function added:

    func KObjs(arg interface{}) []ObjectRef

###
[`v2.9.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.9.0):
Prepare release for Kubernetes v1.22

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.8.0...v2.9.0)

Changes are here :
kubernetes/klog@v2.8.0...v2.9.0

[`6a9ef3f`](https://togithub.com/kubernetes/klog/commit/6a9ef3fa9a15)
fix typo
[`59f7cb5`](https://togithub.com/kubernetes/klog/commit/59f7cb505f58)
fix byte array display in InfoS and ErrorS
[`cf22f1e`](https://togithub.com/kubernetes/klog/commit/cf22f1e79721)
Call logr with call depth
[`e95c7e3`](https://togithub.com/kubernetes/klog/commit/e95c7e303755)
make SetLogger thread-safe
[`2728fe1`](https://togithub.com/kubernetes/klog/commit/2728fe192acc)
check usage of format specifier in structured log func
[`a18bc97`](https://togithub.com/kubernetes/klog/commit/a18bc976a212)
Fix by pr suggestions
[`4e4135c`](https://togithub.com/kubernetes/klog/commit/4e4135c3dd8a)
Add check for InfoS & ErrorS parameters

###
[`v2.8.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.8.0):
Bug fixes for structured logging for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.7.0...v2.8.0)

###
[`v2.7.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.7.0):
Miscellaneous fixes for structured logging for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.6.0...v2.7.0)

Changes are here :
kubernetes/klog@v2.6.0...v2.7.0

###
[`v2.6.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.6.0):
Adding a linter for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.5.0...v2.6.0)

Changes are here :
kubernetes/klog@v2.5.0...v2.6.0

please see
https://github.com/kubernetes/klog/tree/master/hack/tools/logcheck

###
[`v2.5.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.5.0):
Prepare release for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.4.0...v2.5.0)

Changes are here :
kubernetes/klog@v2.4.0...v2.5.0

klog.go has new API:

+func ErrorSDepth(depth int, err error, msg string, keysAndValues
...interface{}) {
+func InfoSDepth(depth int, msg string, keysAndValues ...interface{}) {

klogr/klogr.go has new API:

    func (l klogger) WithCallDepth(depth int) logr.Logger {
    func NewWithOptions(options ...Option) logr.Logger {
    func WithFormat(format Format) Option {

###
[`v2.4.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.4.0):
Prepare release for Kubernetes v1.20

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.3.0...v2.4.0)

Changes are here :
kubernetes/klog@v2.3.0...v2.4.0

###
[`v2.3.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.3.0):
Fix Typo-ed Method Error -&gt; ErrorS

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.2.0...v2.3.0)

Changes are here :
kubernetes/klog@v2.2.0...v2.3.0

###
[`v2.2.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.2.0):
Dependency update and bugfix for InfoS

[Compare
Source](https://togithub.com/kubernetes/klog/compare/2.1.0...v2.2.0)

- [`2e691eb`](https://togithub.com/kubernetes/klog/commit/2e691eb3eeb3)
Fix missing fields in verbose InfoS
- [`966c986`](https://togithub.com/kubernetes/klog/commit/966c98681ca0)
feat use go-logr v0.2.0

Changes are here :
kubernetes/klog@v2.1.0...v2.2.0

###
[`v2.1.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.1.0):
Better support for Structured Logging

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.0.0...2.1.0)

We are now enforcing API compatibility, added Windows based tests, and
have tweaked the structured logging methods after some real world
experience updating kubernetes main repo.

- [`bbd9ca1`](https://togithub.com/kubernetes/klog/commit/bbd9ca1) Add
tests for error in InfoS
- [`1ccc0e1`](https://togithub.com/kubernetes/klog/commit/1ccc0e1) fix
imported bug time encode format form kvlistFormat
- [`dd4d1a6`](https://togithub.com/kubernetes/klog/commit/dd4d1a6) fix
typo in README.md
- [`49123d4`](https://togithub.com/kubernetes/klog/commit/49123d4)
ErrorS(nil, ...) should call loggr.Error(nil, ...)
- [`5b199cd`](https://togithub.com/kubernetes/klog/commit/5b199cd) Fix
documentation for V(level)
- [`d1eb30f`](https://togithub.com/kubernetes/klog/commit/d1eb30f) Add
apidiff script to check go signature changes
- [`dc505bf`](https://togithub.com/kubernetes/klog/commit/dc505bf)
Switch slack channel to #klog
- [`a47ebb9`](https://togithub.com/kubernetes/klog/commit/a47ebb9) Add
example for co-existence of klog v1 and v2
- [`134f148`](https://togithub.com/kubernetes/klog/commit/134f148)
logName(): lazily lookup userName instead of on init()
- [`db06a1b`](https://togithub.com/kubernetes/klog/commit/db06a1b) fix
serialization of special html chars
- [`5727d2a`](https://togithub.com/kubernetes/klog/commit/5727d2a) Fix
Windows integration tests
- [`edbc1d3`](https://togithub.com/kubernetes/klog/commit/edbc1d3)
test(\*): TestRollover failed randomly on Windows
- [`6f99060`](https://togithub.com/kubernetes/klog/commit/6f99060) Add
LogToStderr, a programatic way to log exclusively to stderr or not

###
[`v2.0.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.0.0):
Release to support Kubernetes v1.19

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v1.0.0...v2.0.0)

Beware of type change: `Verbose`

New Methods:

-   `SetLogger` (override logger to set a custom implementation)
-   `InfoS` (structured logging)
-   `ErrorS` (structured logging)

Changes are here :
kubernetes/klog@v2.0.0-rc.1...v2.0.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "on tuesday" (UTC), Automerge - At any
time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/open-telemetry/opentelemetry-collector-contrib).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy44Ny4yIiwidXBkYXRlZEluVmVyIjoiMzcuODcuMiIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: opentelemetrybot <107717825+opentelemetrybot@users.noreply.github.com>
Co-authored-by: Yang Song <songy23@users.noreply.github.com>
Co-authored-by: Tyler Helmuth <12352919+TylerHelmuth@users.noreply.github.com>
cparkins referenced this pull request in AmadeusITGroup/opentelemetry-collector-contrib Jan 10, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [k8s.io/klog](https://togithub.com/kubernetes/klog) | require | major
| `v1.0.0` -> `v2.110.1` |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>kubernetes/klog (k8s.io/klog)</summary>

###
[`v2.110.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.110.1):
Prepare klog release for Kubernetes v1.29 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.100.1...v2.110.1)

#### What's Changed

- fix: SetLogger via klog.SetLogger will output an unexpected newline by
[@&open-telemetry#8203;aimuz](https://togithub.com/aimuz) in
[https://github.com/kubernetes/klog/pull/378](https://togithub.com/kubernetes/klog/pull/378)
- resolve comments warning by
[@&open-telemetry#8203;lowang-bh](https://togithub.com/lowang-bh) in
[https://github.com/kubernetes/klog/pull/379](https://togithub.com/kubernetes/klog/pull/379)
- stderrthreshold: fix flag comment by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/376](https://togithub.com/kubernetes/klog/pull/376)
- enable "go vet" checks for parameters by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/390](https://togithub.com/kubernetes/klog/pull/390)
- promote experimental code to stable by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/392](https://togithub.com/kubernetes/klog/pull/392)
- golangci-lint action by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/380](https://togithub.com/kubernetes/klog/pull/380)
- output: handle WithName like zapr does by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/391](https://togithub.com/kubernetes/klog/pull/391)
- slog support + logr 1.3.0 update by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/384](https://togithub.com/kubernetes/klog/pull/384)

#### New Contributors

- [@&open-telemetry#8203;aimuz](https://togithub.com/aimuz) made their first
contribution in
[https://github.com/kubernetes/klog/pull/378](https://togithub.com/kubernetes/klog/pull/378)
- [@&open-telemetry#8203;lowang-bh](https://togithub.com/lowang-bh) made their first
contribution in
[https://github.com/kubernetes/klog/pull/379](https://togithub.com/kubernetes/klog/pull/379)

**Full Changelog**:
kubernetes/klog@v2.100.1...v2.110.1

###
[`v2.100.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.100.1):
Prepare klog release for Kubernetes v1.28 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.90.1...v2.100.1)

#### What's Changed

- expose logBridge via NewStandardLog() by
[@&open-telemetry#8203;mikedanese](https://togithub.com/mikedanese) in
[https://github.com/kubernetes/klog/pull/369](https://togithub.com/kubernetes/klog/pull/369)
- add Format wrapper by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/374](https://togithub.com/kubernetes/klog/pull/374)
- JSON as fallback encoding by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/375](https://togithub.com/kubernetes/klog/pull/375)

#### New Contributors

- [@&open-telemetry#8203;mikedanese](https://togithub.com/mikedanese) made their first
contribution in
[https://github.com/kubernetes/klog/pull/369](https://togithub.com/kubernetes/klog/pull/369)

**Full Changelog**:
kubernetes/klog@v2.90.1...v2.100.1

###
[`v2.90.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.90.1):
Prepare klog release for Kubernetes v1.27 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.90.0...v2.90.1)

#### What's Changed

- buffer: restore dropping of too large buffers by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/366](https://togithub.com/kubernetes/klog/pull/366)
- ktesting improvements by [@&open-telemetry#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/365](https://togithub.com/kubernetes/klog/pull/365)
- ktesting + textlogger config api by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/368](https://togithub.com/kubernetes/klog/pull/368)
- textlogger write through by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/363](https://togithub.com/kubernetes/klog/pull/363)

**Full Changelog**:
kubernetes/klog@v2.90.0...v2.90.1

###
[`v2.90.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.90.0):
Prepare klog release for Kubernetes v1.27 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.80.1...v2.90.0)

#### What's Changed

- klog: benchmark the overhead when logging is off by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/355](https://togithub.com/kubernetes/klog/pull/355)
- improve textlogger by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/362](https://togithub.com/kubernetes/klog/pull/362)

**Full Changelog**:
kubernetes/klog@v2.80.1...v2.90.0

##### There are some API differences from previous version

    k8s.io/klog/v2/klogr contains incompatible changes:
     - klogger.Enabled: removed
     - klogger.Error: removed
     - klogger.Info: removed

    k8s.io/klog/v2/test contains incompatible changes:
     - InitKlog: changed from func() to func(testing.TB) *flag.FlagSet

###
[`v2.80.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.80.1):
Prepare klog release for Kubernetes v1.26 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.80.0...v2.80.1)

#### What's Changed

- InitFlags concurrency fix by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/349](https://togithub.com/kubernetes/klog/pull/349)

**Full Changelog**:
kubernetes/klog@v2.80.0...v2.80.1

###
[`v2.80.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.80.0):
Prepare klog release for Kubernetes v1.26 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.70.1...v2.80.0)

#### What's Changed

- OWNERS: add harshanarayana by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/342](https://togithub.com/kubernetes/klog/pull/342)
- kvlistformat: fix the issue with display marshalled value for non
string type by
[@&open-telemetry#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/344](https://togithub.com/kubernetes/klog/pull/344)
- Bump version of golang to 1.19 and drop older versions by
[@&open-telemetry#8203;dims](https://togithub.com/dims) in
[https://github.com/kubernetes/klog/pull/345](https://togithub.com/kubernetes/klog/pull/345)

**Full Changelog**:
kubernetes/klog@v2.70.1...v2.80.0

###
[`v2.70.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.70.1):
Prepare klog release for Kubernetes v1.25 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.70.0...v2.70.1)

#### What's Changed

- ktesting: handle test completion by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/337](https://togithub.com/kubernetes/klog/pull/337)
- contextual logging: enable by default again by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/341](https://togithub.com/kubernetes/klog/pull/341)

**Full Changelog**:
kubernetes/klog@v2.70.0...v2.70.1

###
[`v2.70.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.70.0):
Prepare klog release for Kubernetes v1.25 (Take 1)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.60.1...v2.70.0)

#### What's Changed

- logcheck: contextual logging + enhanced checks by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/297](https://togithub.com/kubernetes/klog/pull/297)
- hack/tools: drop dependency on golangci-lint by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/313](https://togithub.com/kubernetes/klog/pull/313)
- StopFlushDaemon: document flushing on shutdown by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/314](https://togithub.com/kubernetes/klog/pull/314)
- logcheck: fix detection of invalid \* regexp in filter by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/315](https://togithub.com/kubernetes/klog/pull/315)
- README.md: clarify -logtostderr by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/319](https://togithub.com/kubernetes/klog/pull/319)
- Trim duplicates by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/324](https://togithub.com/kubernetes/klog/pull/324)
- replace KObjs with KObjSlice by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/322](https://togithub.com/kubernetes/klog/pull/322)
- support logr.Marshaler by [@&open-telemetry#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/325](https://togithub.com/kubernetes/klog/pull/325)
- internal: remove unused TrimDuplicates by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/326](https://togithub.com/kubernetes/klog/pull/326)
- save and restore state by [@&open-telemetry#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/320](https://togithub.com/kubernetes/klog/pull/320)
- GitHub: use apidiff with more recent Go by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/329](https://togithub.com/kubernetes/klog/pull/329)
- remove hack/tools by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/330](https://togithub.com/kubernetes/klog/pull/330)
- GIT-331: fix shadowing key from the kv pair by
[@&open-telemetry#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/332](https://togithub.com/kubernetes/klog/pull/332)
- klog.Fatal backtrace revert by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/328](https://togithub.com/kubernetes/klog/pull/328)
- ktesting: capture log data in memory by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/327](https://togithub.com/kubernetes/klog/pull/327)
- GIT-275: add tests for int and struct keys by
[@&open-telemetry#8203;harshanarayana](https://togithub.com/harshanarayana) in
[https://github.com/kubernetes/klog/pull/333](https://togithub.com/kubernetes/klog/pull/333)

#### New Contributors

- [@&open-telemetry#8203;harshanarayana](https://togithub.com/harshanarayana) made
their first contribution in
[https://github.com/kubernetes/klog/pull/332](https://togithub.com/kubernetes/klog/pull/332)

**Full Changelog**:
kubernetes/klog@v2.60.1...v2.70.0

###
[`v2.60.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.60.1):
Prepare klog release for Kubernetes v1.24 (Take 6)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.60.0...v2.60.1)

#### What's Changed

- Cleanup OWNERS file by
[@&open-telemetry#8203;serathius](https://togithub.com/serathius) in
[https://github.com/kubernetes/klog/pull/309](https://togithub.com/kubernetes/klog/pull/309)
- dependencies: avoid k8s.io/utils, fork clock code instead by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/310](https://togithub.com/kubernetes/klog/pull/310)
- promote contextual logging APIs to stable by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/311](https://togithub.com/kubernetes/klog/pull/311)

**Full Changelog**:
kubernetes/klog@v2.60.0...v2.60.1

###
[`v2.60.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.60.0):
Prepare klog release for Kubernetes v1.24 (Take 5)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.2...v2.60.0)

#### What's Changed

- SetContextualLogger: remove unintentionally merged API call by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/308](https://togithub.com/kubernetes/klog/pull/308)

**Full Changelog**:
kubernetes/klog@v2.50.2...v2.60.0

###
[`v2.50.2`](https://togithub.com/kubernetes/klog/compare/v2.50.1...v2.50.2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.1...v2.50.2)

###
[`v2.50.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.50.1):
Prepare klog release for Kubernetes v1.24 (Take 4)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.50.0...v2.50.1)

#### What's Changed

- SetLoggerWithOptions: support flushing by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/306](https://togithub.com/kubernetes/klog/pull/306)

**Full Changelog**:
kubernetes/klog@v2.50.0...v2.50.1

###
[`v2.50.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.50.0):
Prepare klog release for Kubernetes v1.24 (Take 3)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.40.1...v2.50.0)

#### What's Changed

- Panic on empty info with custom logr by
[@&open-telemetry#8203;jklaw90](https://togithub.com/jklaw90) in
[https://github.com/kubernetes/klog/pull/283](https://togithub.com/kubernetes/klog/pull/283)
- Add missing Depth logging functions. by
[@&open-telemetry#8203;s3rj1k](https://togithub.com/s3rj1k) in
[https://github.com/kubernetes/klog/pull/280](https://togithub.com/kubernetes/klog/pull/280)
- fix typo in klog.go by
[@&open-telemetry#8203;cocaccola](https://togithub.com/cocaccola) in
[https://github.com/kubernetes/klog/pull/270](https://togithub.com/kubernetes/klog/pull/270)
- Update README.md by
[@&open-telemetry#8203;noaabarki](https://togithub.com/noaabarki) in
[https://github.com/kubernetes/klog/pull/281](https://togithub.com/kubernetes/klog/pull/281)
- log filter: ignored by V, used during log call by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/290](https://togithub.com/kubernetes/klog/pull/290)
- SetLogger/ClearLogger/SetLogFilter cleanup by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/289](https://togithub.com/kubernetes/klog/pull/289)
- fixes for PR
[#&open-telemetry#8203;280](https://togithub.com/kubernetes/klog/issues/280),
refactoring, textlogger, unit test by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/287](https://togithub.com/kubernetes/klog/pull/287)
- klogr verbosity by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/295](https://togithub.com/kubernetes/klog/pull/295)
- test: fix Go version matrix by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/298](https://togithub.com/kubernetes/klog/pull/298)
- handle panics in MarshalLog, Error, String by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/299](https://togithub.com/kubernetes/klog/pull/299)
- Fix goroutine leak: make flushDaemon stoppable by
[@&open-telemetry#8203;katexochen](https://togithub.com/katexochen) in
[https://github.com/kubernetes/klog/pull/293](https://togithub.com/kubernetes/klog/pull/293)
- structured logging: replacing Fatal/Exit/etc. without loss of flushing
by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/303](https://togithub.com/kubernetes/klog/pull/303)
- contextual logging by [@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/296](https://togithub.com/kubernetes/klog/pull/296)
- remove side effects of tests by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/305](https://togithub.com/kubernetes/klog/pull/305)
- tests: stop testing with Go 1.14 by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/304](https://togithub.com/kubernetes/klog/pull/304)

#### New Contributors

- [@&open-telemetry#8203;jklaw90](https://togithub.com/jklaw90) made their first
contribution in
[https://github.com/kubernetes/klog/pull/283](https://togithub.com/kubernetes/klog/pull/283)
- [@&open-telemetry#8203;s3rj1k](https://togithub.com/s3rj1k) made their first
contribution in
[https://github.com/kubernetes/klog/pull/280](https://togithub.com/kubernetes/klog/pull/280)
- [@&open-telemetry#8203;cocaccola](https://togithub.com/cocaccola) made their first
contribution in
[https://github.com/kubernetes/klog/pull/270](https://togithub.com/kubernetes/klog/pull/270)
- [@&open-telemetry#8203;noaabarki](https://togithub.com/noaabarki) made their first
contribution in
[https://github.com/kubernetes/klog/pull/281](https://togithub.com/kubernetes/klog/pull/281)
- [@&open-telemetry#8203;katexochen](https://togithub.com/katexochen) made their first
contribution in
[https://github.com/kubernetes/klog/pull/293](https://togithub.com/kubernetes/klog/pull/293)

**Full Changelog**:
kubernetes/klog@v2.40.1...v2.50.0

###
[`v2.40.1`](https://togithub.com/kubernetes/klog/releases/tag/v2.40.1):
Prepare klog release for Kubernetes v1.24 (Take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.40.0...v2.40.1)

#### What's Changed

- Using OS targeted go files to separate out the username logic. by
[@&open-telemetry#8203;phillipsj](https://togithub.com/phillipsj) in
[https://github.com/kubernetes/klog/pull/271](https://togithub.com/kubernetes/klog/pull/271)
- Recover from nil pointers when logging by
[@&open-telemetry#8203;dims](https://togithub.com/dims) in
[https://github.com/kubernetes/klog/pull/279](https://togithub.com/kubernetes/klog/pull/279)

#### New Contributors

- [@&open-telemetry#8203;phillipsj](https://togithub.com/phillipsj) made their first
contribution in
[https://github.com/kubernetes/klog/pull/271](https://togithub.com/kubernetes/klog/pull/271)

**Full Changelog**:
kubernetes/klog@v2.40.0...v2.40.1

###
[`v2.40.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.40.0):
Prepare klog release for Kubernetes v1.24

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.30.0...v2.40.0)

#### What's Changed

- structured logging: support values with line breaks by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/273](https://togithub.com/kubernetes/klog/pull/273)
- Fix klog lock release on panic error by
[@&open-telemetry#8203;astraw99](https://togithub.com/astraw99) in
[https://github.com/kubernetes/klog/pull/272](https://togithub.com/kubernetes/klog/pull/272)
- add format test for KObjs by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/276](https://togithub.com/kubernetes/klog/pull/276)
- add Verbose.InfoSDepth by [@&open-telemetry#8203;pohly](https://togithub.com/pohly)
in
[https://github.com/kubernetes/klog/pull/277](https://togithub.com/kubernetes/klog/pull/277)

#### Known Issues

-
[https://github.com/kubernetes/klog/issues/278](https://togithub.com/kubernetes/klog/issues/278)

#### New Contributors

- [@&open-telemetry#8203;astraw99](https://togithub.com/astraw99) made their first
contribution in
[https://github.com/kubernetes/klog/pull/272](https://togithub.com/kubernetes/klog/pull/272)

**Full Changelog**:
kubernetes/klog@v2.30.0...v2.40.0

###
[`v2.30.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.30.0):
Prepare klog release for Kubernetes v1.23 (take 2)

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.20.0...v2.30.0)

#### What's Changed

- Fix logcheck exit function by
[@&open-telemetry#8203;luyou86](https://togithub.com/luyou86) in
[https://github.com/kubernetes/klog/pull/265](https://togithub.com/kubernetes/klog/pull/265)
- custom marshaler for ObjectRef by
[@&open-telemetry#8203;pohly](https://togithub.com/pohly) in
[https://github.com/kubernetes/klog/pull/266](https://togithub.com/kubernetes/klog/pull/266)

#### New Contributors

- [@&open-telemetry#8203;luyou86](https://togithub.com/luyou86) made their first
contribution in
[https://github.com/kubernetes/klog/pull/265](https://togithub.com/kubernetes/klog/pull/265)

**Full Changelog**:
kubernetes/klog@v2.20.0...v2.30.0

###
[`v2.20.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.20.0):
Prepare klog release for Kubernetes v1.23

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.10.0...v2.20.0)

Changes are here :
kubernetes/klog@v2.10.0...v2.20.0

since we moved to logr v1.0.0, there are incompatible changes:

    - klogger.Enabled: changed from func() bool to func(int) bool
- klogger.Info: changed from func(string, ...interface{}) to func(int,
string, ...interface{})
    - klogger.V: removed
- klogger.WithCallDepth: changed from func(int)
github.com/go-logr/logr.Logger to func(int)
github.com/go-logr/logr.LogSink
- klogger.WithName: changed from func(string)
github.com/go-logr/logr.Logger to func(string)
github.com/go-logr/logr.LogSink
- klogger.WithValues: changed from func(...interface{})
github.com/go-logr/logr.Logger to func(...interface{})
github.com/go-logr/logr.LogSink

[`83653a6`](https://togithub.com/kubernetes/klog/commit/83653a6deebf)
Update to newest versions of golang 1.17.x
[`d648c2e`](https://togithub.com/kubernetes/klog/commit/d648c2e42d30)
fix file-based filtering symbolization
[`8ee3d65`](https://togithub.com/kubernetes/klog/commit/8ee3d652c96b)
export ClearLogger
[`4171f3c`](https://togithub.com/kubernetes/klog/commit/4171f3c1be1b)
Switching to logr tag v1.0.0
[`9ab3c2b`](https://togithub.com/kubernetes/klog/commit/9ab3c2b56cb2)
add serathius as approvers of klog

###
[`v2.10.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.10.0):
One more change to support 1.22 release

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.9.0...v2.10.0)

Changes are here :
kubernetes/klog@v2.9.0...v2.10.0

new function added:

    func KObjs(arg interface{}) []ObjectRef

###
[`v2.9.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.9.0):
Prepare release for Kubernetes v1.22

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.8.0...v2.9.0)

Changes are here :
kubernetes/klog@v2.8.0...v2.9.0

[`6a9ef3f`](https://togithub.com/kubernetes/klog/commit/6a9ef3fa9a15)
fix typo
[`59f7cb5`](https://togithub.com/kubernetes/klog/commit/59f7cb505f58)
fix byte array display in InfoS and ErrorS
[`cf22f1e`](https://togithub.com/kubernetes/klog/commit/cf22f1e79721)
Call logr with call depth
[`e95c7e3`](https://togithub.com/kubernetes/klog/commit/e95c7e303755)
make SetLogger thread-safe
[`2728fe1`](https://togithub.com/kubernetes/klog/commit/2728fe192acc)
check usage of format specifier in structured log func
[`a18bc97`](https://togithub.com/kubernetes/klog/commit/a18bc976a212)
Fix by pr suggestions
[`4e4135c`](https://togithub.com/kubernetes/klog/commit/4e4135c3dd8a)
Add check for InfoS & ErrorS parameters

###
[`v2.8.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.8.0):
Bug fixes for structured logging for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.7.0...v2.8.0)

###
[`v2.7.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.7.0):
Miscellaneous fixes for structured logging for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.6.0...v2.7.0)

Changes are here :
kubernetes/klog@v2.6.0...v2.7.0

###
[`v2.6.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.6.0):
Adding a linter for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.5.0...v2.6.0)

Changes are here :
kubernetes/klog@v2.5.0...v2.6.0

please see
https://github.com/kubernetes/klog/tree/master/hack/tools/logcheck

###
[`v2.5.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.5.0):
Prepare release for Kubernetes v1.21

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.4.0...v2.5.0)

Changes are here :
kubernetes/klog@v2.4.0...v2.5.0

klog.go has new API:

+func ErrorSDepth(depth int, err error, msg string, keysAndValues
...interface{}) {
+func InfoSDepth(depth int, msg string, keysAndValues ...interface{}) {

klogr/klogr.go has new API:

    func (l klogger) WithCallDepth(depth int) logr.Logger {
    func NewWithOptions(options ...Option) logr.Logger {
    func WithFormat(format Format) Option {

###
[`v2.4.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.4.0):
Prepare release for Kubernetes v1.20

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.3.0...v2.4.0)

Changes are here :
kubernetes/klog@v2.3.0...v2.4.0

###
[`v2.3.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.3.0):
Fix Typo-ed Method Error -&gt; ErrorS

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.2.0...v2.3.0)

Changes are here :
kubernetes/klog@v2.2.0...v2.3.0

###
[`v2.2.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.2.0):
Dependency update and bugfix for InfoS

[Compare
Source](https://togithub.com/kubernetes/klog/compare/2.1.0...v2.2.0)

- [`2e691eb`](https://togithub.com/kubernetes/klog/commit/2e691eb3eeb3)
Fix missing fields in verbose InfoS
- [`966c986`](https://togithub.com/kubernetes/klog/commit/966c98681ca0)
feat use go-logr v0.2.0

Changes are here :
kubernetes/klog@v2.1.0...v2.2.0

###
[`v2.1.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.1.0):
Better support for Structured Logging

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v2.0.0...2.1.0)

We are now enforcing API compatibility, added Windows based tests, and
have tweaked the structured logging methods after some real world
experience updating kubernetes main repo.

- [`bbd9ca1`](https://togithub.com/kubernetes/klog/commit/bbd9ca1) Add
tests for error in InfoS
- [`1ccc0e1`](https://togithub.com/kubernetes/klog/commit/1ccc0e1) fix
imported bug time encode format form kvlistFormat
- [`dd4d1a6`](https://togithub.com/kubernetes/klog/commit/dd4d1a6) fix
typo in README.md
- [`49123d4`](https://togithub.com/kubernetes/klog/commit/49123d4)
ErrorS(nil, ...) should call loggr.Error(nil, ...)
- [`5b199cd`](https://togithub.com/kubernetes/klog/commit/5b199cd) Fix
documentation for V(level)
- [`d1eb30f`](https://togithub.com/kubernetes/klog/commit/d1eb30f) Add
apidiff script to check go signature changes
- [`dc505bf`](https://togithub.com/kubernetes/klog/commit/dc505bf)
Switch slack channel to #klog
- [`a47ebb9`](https://togithub.com/kubernetes/klog/commit/a47ebb9) Add
example for co-existence of klog v1 and v2
- [`134f148`](https://togithub.com/kubernetes/klog/commit/134f148)
logName(): lazily lookup userName instead of on init()
- [`db06a1b`](https://togithub.com/kubernetes/klog/commit/db06a1b) fix
serialization of special html chars
- [`5727d2a`](https://togithub.com/kubernetes/klog/commit/5727d2a) Fix
Windows integration tests
- [`edbc1d3`](https://togithub.com/kubernetes/klog/commit/edbc1d3)
test(\*): TestRollover failed randomly on Windows
- [`6f99060`](https://togithub.com/kubernetes/klog/commit/6f99060) Add
LogToStderr, a programatic way to log exclusively to stderr or not

###
[`v2.0.0`](https://togithub.com/kubernetes/klog/releases/tag/v2.0.0):
Release to support Kubernetes v1.19

[Compare
Source](https://togithub.com/kubernetes/klog/compare/v1.0.0...v2.0.0)

Beware of type change: `Verbose`

New Methods:

-   `SetLogger` (override logger to set a custom implementation)
-   `InfoS` (structured logging)
-   `ErrorS` (structured logging)

Changes are here :
kubernetes/klog@v2.0.0-rc.1...v2.0.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "on tuesday" (UTC), Automerge - At any
time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/open-telemetry/opentelemetry-collector-contrib).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy44Ny4yIiwidXBkYXRlZEluVmVyIjoiMzcuODcuMiIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: opentelemetrybot <107717825+opentelemetrybot@users.noreply.github.com>
Co-authored-by: Yang Song <songy23@users.noreply.github.com>
Co-authored-by: Tyler Helmuth <12352919+TylerHelmuth@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants