Skip to content

move boringssl dependencies to extensions#5543

Merged
lizan merged 3 commits intoenvoyproxy:masterfrom
bdecoste:boringssl_extensions
Jan 16, 2019
Merged

move boringssl dependencies to extensions#5543
lizan merged 3 commits intoenvoyproxy:masterfrom
bdecoste:boringssl_extensions

Conversation

@bdecoste
Copy link
Copy Markdown
Contributor

@bdecoste bdecoste commented Jan 8, 2019

Signed-off-by: William DeCoste bdecoste@gmail.com

For an explanation of how to fill out the fields, please see the relevant section
in PULL_REQUESTS.md

Description: As part of the work to support openssl this PR moves all boringssl dependencies to extensions. This is one step that will enable the linking and testing of openssl with a new transport socket for openssl. Those files with boringssl dependencies were moved from common/ssl to extensions/transport_sockets/ssl with similar changes for the tests. Please see #5524 for additional context.
Risk Level: Low
Testing: Standard tests passed
Docs Changes: None
Release Notes: None
[Optional Fixes #Issue]
[Optional Deprecated:]

@PiotrSikora
Copy link
Copy Markdown
Contributor

/assign @lizan @PiotrSikora

@lizan
Copy link
Copy Markdown
Member

lizan commented Jan 8, 2019

/retest

@repokitteh-read-only
Copy link
Copy Markdown

🔨 rebuilding ci/circleci: release (failed build)

🐱

Caused by: a #5543 (comment) was created by @lizan.

see: more, trace.

@lizan
Copy link
Copy Markdown
Member

lizan commented Jan 8, 2019

At a glance this looks good, @bdecoste can you open an issue to track the overall work to make BoringSSL can be compiled out? i.e. what is the next step of this PR etc, based on the conversation in KubeCon last month.

@bdecoste
Copy link
Copy Markdown
Contributor Author

bdecoste commented Jan 8, 2019

#5545

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Ideally I think we want the namespaces to be consistent with the path, do you want to do that in this PR or in next PR? I'm fine either.

Copy link
Copy Markdown
Contributor

@PiotrSikora PiotrSikora left a comment

Choose a reason for hiding this comment

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

Could you move it to extensions/transport_sockets/tls instead, so that it matches naming we use in the API? Thanks!

Also, changing namespaces would be great.

@bdecoste
Copy link
Copy Markdown
Contributor Author

bdecoste commented Jan 9, 2019

Thanks you. Just to confirm: You want the directory changed to extensions/transport_sockets/tls and the corresponding namespace to be Envoy::Extensions::TransportSockets::Tls?

Thanks -Bill

@PiotrSikora
Copy link
Copy Markdown
Contributor

@bdecoste yes, if that's not too much work (there is already config in extensions/transport_sockets/ssl, which you'd need to move as well). Thanks!

@lizan
Copy link
Copy Markdown
Member

lizan commented Jan 9, 2019

SGTM, the transport socket is already named as tls. Thank you!

@bdecoste
Copy link
Copy Markdown
Contributor Author

bdecoste commented Jan 9, 2019

Great, thank you. I will make the changes and update the PR asap. The transport socket namespace in the extensions/transport_socket/ssl directory was Envoy::Extensions::TransportSockets::SslTransport so I will move and rename.

@bdecoste
Copy link
Copy Markdown
Contributor Author

bdecoste commented Jan 9, 2019

Do you also want me to change include/envoy/ssl and Envoy::Ssl to include/envoy/tls and Envoy::Tls? Thanks

@PiotrSikora
Copy link
Copy Markdown
Contributor

@bdecoste I don't particularly care if it's done as part of this PR or another, but it should be renamed before OpenSSL extension starts including it.

@bdecoste
Copy link
Copy Markdown
Contributor Author

bdecoste commented Jan 9, 2019

OK, thanks. I will update the include as the next PR. This one is big enough already :-)

lizan
lizan previously approved these changes Jan 11, 2019
Copy link
Copy Markdown
Member

@lizan lizan left a comment

Choose a reason for hiding this comment

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

LGTM, sorry for the delay.

@bdecoste
Copy link
Copy Markdown
Contributor Author

Thanks Lizan. As soon as this is merged, I'll put in another PR for moving the remaining file/namespaces from ssl to tls. I have this all ready and tested locally.

PiotrSikora
PiotrSikora previously approved these changes Jan 11, 2019
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nit: I think you can omit Envoy:: here (and everywhere else), Extensions::TransportSockets::Tls:: should also work, though I'm not sure if there are any style guidelines or preferences for that.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ya, I find having the full namespace is easier to read but if you want me to reduce them please let me know

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No, it's fine. Thanks.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

In general we do try to reduce the namespace length, so I have a mild preference to remove Envoy:: here if you don't mind. If you don't feel like it it's fine to merge.

Copy link
Copy Markdown
Contributor Author

@bdecoste bdecoste Jan 11, 2019

Choose a reason for hiding this comment

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

OK, I'll remove the Envoy::
Thanks

@bdecoste bdecoste dismissed stale reviews from PiotrSikora and lizan via 08d62cc January 11, 2019 20:39
@repokitteh-read-only
Copy link
Copy Markdown

🙀 Error while processing event:

evaluation error
error: finished: cannot load github.com/repokitteh/modules/lib/utils.star: error from server: {module load error GET https://api.github.com/repos/repokitteh/modules/contents/lib/utils.star: 401 Bad credentials [] map[]}
🐱

Caused by: #5543 was synchronize by bdecoste.

see: more, trace.

Copy link
Copy Markdown
Contributor

@PiotrSikora PiotrSikora left a comment

Choose a reason for hiding this comment

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

@bdecoste It looks that you've missed one file, looks good, otherwise. Thanks!

Also, please don't force push in the future, since it makes reviewing much more demanding (basically, requiring review from scratch), and GitHub doesn't send notifications for the force push, so no one knows that you've made any changes. Instead, please push multiple commits (including merge with master, if your base drifted too much). All commits are squashed during merge, so it's a single commit once merged into master.

@bdecoste
Copy link
Copy Markdown
Contributor Author

Thanks. Will not squash and force push in the future. We've (RH) have always squashed to a single commit for our other projects.

Signed-off-by: William DeCoste <bdecoste@gmail.com>
Signed-off-by: William DeCoste <bdecoste@gmail.com>
@mattklein123 mattklein123 self-assigned this Jan 15, 2019
@bdecoste
Copy link
Copy Markdown
Contributor Author

Resolved merge conflicts but had to force push to resolve.

Signed-off-by: William DeCoste <bdecoste@gmail.com>
Copy link
Copy Markdown
Contributor

@PiotrSikora PiotrSikora left a comment

Choose a reason for hiding this comment

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

Thanks!

// TODO(htuch): This needs to be made const again and/or zero copy and/or callers fixed.
std::vector<std::reference_wrapper<const TlsCertificateConfig>> tlsCertificates() const override {
std::vector<std::reference_wrapper<const TlsCertificateConfig>> configs;
std::vector<std::reference_wrapper<const Envoy::Ssl::TlsCertificateConfig>>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I still see a bunch of Envoy::Ssl in here. Is that needed for a namespace conflict? Doesn't seem like there should be?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Interfaces in include/envoy still use Envoy:Ssl, @bdecoste is going to rename those in a follow-up PR... Unless you prefer to do it in this one?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

My point was I don't think the Envoy:: is required, but if this is going to be changed in a follow up we can go ahead and just merge it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Ah, that. I focused on Ssl vs Tls and completely missed it. Yes, it probably wasn't needed.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

When @bdecoste renames Envoy::Ssl to Envoy::Tls this will conflict with Envoy::Extensions::TransportSockets::Tls, so let's just leave this as Envoy::Ssl.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the reviews and merge. I should have the next PR to complete the directory and namespace change from ssl to tls in today or tomorrow.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

To confirm... do you want me to leave include/envoy/ssl alone (i.e. Envoy::Ssl) or make the change to include/envoy/tls and Envoy::Tls and use fully qualified namespaces to avoid conflict?If we are sticking with ssl then I will put in a PR to remove the extraneous Envoy::

Thanks

@lizan lizan merged commit 568b257 into envoyproxy:master Jan 16, 2019
fredlas pushed a commit to fredlas/envoy that referenced this pull request Mar 5, 2019
*Description*: As part of the work to support openssl this PR moves all boringssl dependencies to extensions. This is one step that will enable the linking and testing of openssl with a new transport socket for openssl. Those files with boringssl dependencies were moved from common/ssl to extensions/transport_sockets/ssl with similar changes for the tests. Please see envoyproxy#5524 for additional context. 

*Risk Level*: Low
*Testing*: Standard tests passed
*Docs Changes*: None
*Release Notes*: None

Signed-off-by: William DeCoste <bdecoste@gmail.com>
Signed-off-by: Fred Douglas <fredlas@google.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.

4 participants