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

Fix the cfg variable configuration bug. #65

Conversation

pettershao-ragilenetworks
Copy link
Contributor

Why I did it

var cfg was declared in line 62. Otherwise, the configuration will be abnormal.

How I did it

var cfg was declared in line 62. Otherwise, the configuration will be abnormal.

How to verify it

var cfg was declared in line 62. Otherwise, the configuration will be abnormal.

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111

Description for the changelog

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@pettershao-ragilenetworks
Copy link
Contributor Author

@ganglyu & @zbud-msft - Please provide your review/approval.

@ganglyu
Copy link
Contributor

ganglyu commented Nov 30, 2022

Can you explain "the configuration will be abnormal"? What's the behavior?

@pettershao-ragilenetworks
Copy link
Contributor Author

ca0e5a3d-d572-499e-be59-13b74ec6df39
2cd9ce67-6d09-4051-8002-5ff206014f82
398cb523-1c8b-4863-a72c-3efa20c47733

pls see log, it is two different variables with the same name.

@pettershao-ragilenetworks
Copy link
Contributor Author

@ganglyu

@@ -135,7 +135,6 @@ func main() {
}

opts = []grpc.ServerOption{grpc.Creds(credentials.NewTLS(tlsCfg))}
cfg := &gnmi.Config{}
cfg.Port = int64(*port)
cfg.UserAuth = userAuth
Copy link
Contributor

Choose a reason for hiding this comment

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

We only need UserAuth here, can you remove line 138, 140 and 141?

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