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

Add Inject interface chain elem #18

Merged
merged 5 commits into from
Jul 23, 2020

Conversation

lvfxx
Copy link
Member

@lvfxx lvfxx commented Jul 14, 2020

Add injectServer that moves network interface to and from a Client's pod network namespace. This server was initially written for sdk-sriov and now is moved in this repo for reuse

Signed-off-by: Sergey Semenov <sergey.semenov@xored.com>
Signed-off-by: Sergey Semenov <sergey.semenov@xored.com>
@lvfxx lvfxx force-pushed the inject-interface-chain-elem branch from ed3bfbe to 7803857 Compare July 14, 2020 05:31
Signed-off-by: Sergey Semenov <sergey.semenov@xored.com>
@lvfxx lvfxx force-pushed the inject-interface-chain-elem branch from 9946957 to 2069e16 Compare July 14, 2020 06:15
Signed-off-by: Sergey Semenov <sergey.semenov@xored.com>
@lvfxx lvfxx force-pushed the inject-interface-chain-elem branch from 0b7b881 to ada7cab Compare July 21, 2020 06:25
}
log.Entry(ctx).Infof("Moved network interface %s into the Client's namespace for connection %s", ifaceName, request.GetConnection().GetId())

return next.Server(ctx).Request(ctx, request)
Copy link
Contributor

Choose a reason for hiding this comment

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

We should check if next return Error, we need to move interface back.

}

// NewServer - returns a new networkservice.NetworkServiceServer that moves given network interface into the Client's
// pod network namespace on Request and back to Forwarder's network namespace on Close
Copy link
Contributor

Choose a reason for hiding this comment

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

Document requirements.

Signed-off-by: Sergey Semenov <sergey.semenov@xored.com>
@haiodo haiodo merged commit 1e0a836 into networkservicemesh:master Jul 23, 2020
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.

3 participants