Skip to content

Added channel complition logs#1204

Open
Ex4amp1e wants to merge 2 commits intonetworkservicemesh:mainfrom
Ex4amp1e:add-chan-logs
Open

Added channel complition logs#1204
Ex4amp1e wants to merge 2 commits intonetworkservicemesh:mainfrom
Ex4amp1e:add-chan-logs

Conversation

@Ex4amp1e
Copy link
Copy Markdown
Member

@Ex4amp1e Ex4amp1e commented Nov 6, 2024

PR is created to investigate problem, where forwarder pod cannot be terminated in kubernates.

Logs after command to kill the pod:

2024-11-05T07:45:35.1873352Z Nov  5 06:41:44.157 [ERRO] [cmd:/bin/forwarder] <nil>
2024-11-05T07:45:35.1874253Z Nov  5 06:41:44.304 [INFO] [cmd:/bin/forwarder] [component:netNsMonitor] [inodeURL:inode://4/4026533101] stopping...

Failed job: https://github.com/networkservicemesh/integration-k8s-kind/actions/runs/11678605869/job/32518340408?pr=1039

Signed-off-by: Vladislav Byrgazov <vladislav.byrgazov@xored.com>
Copy link
Copy Markdown
Member

@denis-tingaikin denis-tingaikin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comments

main.go Outdated

// TODO - cleaner shutdown across these channels
<-ctx.Done()
log.FromContext(ctx).Infof("Completed <-ctx.Done()")
Copy link
Copy Markdown
Member

@denis-tingaikin denis-tingaikin Nov 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. please do not use formating.
  2. use more human readable logs
Suggested change
log.FromContext(ctx).Infof("Completed <-ctx.Done()")
log.FromContext(ctx).Info("Application context is done :received OS signal")

Signed-off-by: Vladislav Byrgazov <vladislav.byrgazov@xored.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants