ROX-26719: Refactor in preparation for Secured Cluster TLS Issuer#13000
ROX-26719: Refactor in preparation for Secured Cluster TLS Issuer#13000vladbologa merged 11 commits intomasterfrom
Conversation
|
Skipping CI for Draft Pull Request. |
|
Images are ready for the commit at 68f2130. To use with deploy scripts, first |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #13000 +/- ##
==========================================
+ Coverage 48.42% 48.46% +0.04%
==========================================
Files 2462 2468 +6
Lines 177553 177988 +435
==========================================
+ Hits 85974 86270 +296
- Misses 84656 84781 +125
- Partials 6923 6937 +14
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
ebc2110 to
b910fd5
Compare
9798dcb to
f70d284
Compare
b910fd5 to
0ce7f41
Compare
9e20f7a to
0708ae8
Compare
0ce7f41 to
de00161
Compare
0708ae8 to
18c4edb
Compare
b5bba00 to
949cad1
Compare
949cad1 to
099a365
Compare
5c1170c to
bd59c3b
Compare
vikin91
left a comment
There was a problem hiding this comment.
The change looks good and I have only minor suggestions (or questions).
Before accepting that, I would like us to give the certrequester.CertificateRequester a thought. You know better the domain, do you have any alternative candidates for naming?
sensor/kubernetes/certrefresh/localscanner/certificate_requester.go
Outdated
Show resolved
Hide resolved
sensor/kubernetes/certrefresh/localscanner/certificate_requester.go
Outdated
Show resolved
Hide resolved
|
/test ocp-4-17-nongroovy-e2e-tests |
1 similar comment
|
/test ocp-4-17-nongroovy-e2e-tests |
vikin91
left a comment
There was a problem hiding this comment.
Looks good! Thank you for improving!
In the last pass I only found a minor comment cosmetic issue.
Co-authored-by: Piotr Rygielski <114479+vikin91@users.noreply.github.com>
…3000) Co-authored-by: Piotr Rygielski <114479+vikin91@users.noreply.github.com>
Description
Another refactor PR to prepare for Secured Cluster certificates refresh, following #12825 and #13023. Like these other 2 PRs, it does not change any behaviour.
Changes in this PR
Some files are moved out of the
localscannerpackage into the more genericcertrefreshpackage (so that they can be reused for secured cluster certificate refresh):Because the
CertificateRequesterinterface (used incert_refresher.go) was tightly coupled with a gRPC call type:I introduced an intermediate type called
IssueCertsResponse, and moved it together withCertificateRequesterinto their own package (to prevent cyclic dependencies).Finally, it also moves
certrefresh/localscanner/tls_issuer.gotocertrefresh/localscanner_tls_issuer.go. This might go against the logical structure of the directories, but it'll make it easier to share some common testing code withsecuredcluster_tls_issuer(coming in a future PR), and allows me to keep some internal types unexported. It also makes instantiating this component look a bit cleaner IMO:certrefresh.NewLocalScannerTLSIssuervslocalscanner.NewLocalScannerTLSIssuerpreviously.Next steps
Following the merge of this PR, the actual implementation of certificate refresh for secured clusters will be next.
User-facing documentation
Testing and quality
Automated testing
How I validated my change
Did not add new functionality, existing tests should check for regressions.