mirror of
https://github.com/kyverno/kyverno.git
synced 2024-12-14 11:57:48 +00:00
Makefile and log (#5929)
* fix make debug-deploy Signed-off-by: Jim Bugwadia <jim@nirmata.com> * improve log messages Signed-off-by: Jim Bugwadia <jim@nirmata.com> Signed-off-by: Jim Bugwadia <jim@nirmata.com>
This commit is contained in:
parent
f2bab6bc97
commit
22c23a5692
2 changed files with 5 additions and 4 deletions
4
Makefile
4
Makefile
|
@ -650,8 +650,8 @@ release-notes:
|
|||
#########
|
||||
|
||||
.PHONY: debug-deploy
|
||||
debug-deploy: codegen-install ## Install debug manifests
|
||||
@kubectl create -f ./config/install_debug.yaml || kubectl replace -f ./config/install_debug.yaml
|
||||
debug-deploy: codegen-manifest-debug ## Install debug manifests
|
||||
@kubectl create -f ./.manifest/debug.yaml || kubectl replace -f ./.manifest/debug.yaml
|
||||
|
||||
##########
|
||||
# GITHUB #
|
||||
|
|
|
@ -95,8 +95,9 @@ func initRecorder(client dclient.Interface, eventSource Source, log logr.Logger)
|
|||
func (gen *Generator) Add(infos ...Info) {
|
||||
logger := gen.log
|
||||
|
||||
logger.V(3).Info("generating events", "count", len(infos))
|
||||
if gen.queue.Len() > gen.maxQueuedEvents {
|
||||
logger.V(5).Info("exceeds the event queue limit, dropping the event", "maxQueuedEvents", gen.maxQueuedEvents, "current size", gen.queue.Len())
|
||||
logger.V(2).Info("exceeds the event queue limit, dropping the event", "maxQueuedEvents", gen.maxQueuedEvents, "current size", gen.queue.Len())
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -104,7 +105,7 @@ func (gen *Generator) Add(infos ...Info) {
|
|||
if info.Name == "" {
|
||||
// dont create event for resources with generateName
|
||||
// as the name is not generated yet
|
||||
logger.V(4).Info("not creating an event as the resource has not been assigned a name yet", "kind", info.Kind, "name", info.Name, "namespace", info.Namespace)
|
||||
logger.V(3).Info("skipping event creation for resource without a name", "kind", info.Kind, "name", info.Name, "namespace", info.Namespace)
|
||||
continue
|
||||
}
|
||||
gen.queue.Add(info)
|
||||
|
|
Loading…
Reference in a new issue