-
Notifications
You must be signed in to change notification settings - Fork 19
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
[sdk-vpp#314] Use token ID key from api #227
[sdk-vpp#314] Use token ID key from api #227
Conversation
577204f
to
21873d0
Compare
if !ok { | ||
logger.Infof("no token id present for client connection %v", conn) | ||
return next.Server(ctx).Request(ctx, request) | ||
return nil, errors.New("no token ID provided") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pperiyasamy
What do you think of returning an error in such case and so using it with a switchcase
server for the complex chains?
Example of usage with switchcase - https://github.com/networkservicemesh/sdk-vpp/blob/70d7b5353d50c9c81b5de0978d4d040cc22a4d18/pkg/networkservice/chains/xconnectns/server.go#L119-L124.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes @Bolodya1997, this is a perfect case for using switch case chain element, I will change this and adapt sdk-ovs to use switch case chain element to align for this change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Bolodya1997 raised a review in sdk-ovs
to address this with switchcase
networkservicemesh/sdk-ovs#16, so please go ahead with returning an error here.
21873d0
to
61efa2d
Compare
@Bolodya1997 Could you resolve conflicts? |
@Bolodya1997 How are things going looking at just doing the endpoint Switch approach in cmd-forwarder-vpp ? |
…esourcepool.TokenID Signed-off-by: Vladimir Popov <vladimir.popov@xored.com>
61efa2d
to
6d36aa7
Compare
Everything is great:
We still need this PR to |
@Bolodya1997 Why does sdk-vpp need to know anything about DeviceTokenID? |
It is a PR to |
Doh... apologies :) |
…k-sriov@main PR link: networkservicemesh/sdk-sriov#227 Commit: 05bb114 Author: Ed Warnicke Date: 2021-09-13 10:19:09 -0500 Message: - Merge pull request #227 from Bolodya1997/sdk-vpp#314/token-id-key Signed-off-by: NSMBot <nsmbot@networkservicmesh.io>
…k-sriov@main PR link: networkservicemesh/sdk-sriov#227 Commit: 05bb114 Author: Ed Warnicke Date: 2021-09-13 10:19:09 -0500 Message: - Merge pull request #227 from Bolodya1997/sdk-vpp#314/token-id-key Signed-off-by: NSMBot <nsmbot@networkservicmesh.io>
…k-sriov@main PR link: networkservicemesh/sdk-sriov#227 Commit: 05bb114 Author: Ed Warnicke Date: 2021-09-13 10:19:09 -0500 Message: - Merge pull request #227 from Bolodya1997/sdk-vpp#314/token-id-key Signed-off-by: NSMBot <nsmbot@networkservicmesh.io>
…k-sriov@main PR link: networkservicemesh/sdk-sriov#227 Commit: 05bb114 Author: Ed Warnicke Date: 2021-09-13 10:19:09 -0500 Message: - Merge pull request #227 from Bolodya1997/sdk-vpp#314/token-id-key Signed-off-by: NSMBot <nsmbot@networkservicmesh.io>
Description
Starts SR-IOV token ID mechanism parameter from
api
.Depends on networkservicemesh/api#110.
Issue link
Needed for networkservicemesh/sdk-vpp#314.
How Has This Been Tested?
Added unit testing to coverCovered by existing unit testingTypes of changes