-
Notifications
You must be signed in to change notification settings - Fork 500
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
Adopt aggregated apiserver #1048
Conversation
@@ -0,0 +1,90 @@ | |||
# Adding New Resources in TiDB Aggregated Apiserver |
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.
A brief introduction of the usage
} | ||
|
||
// StartApiServer starts an apiserver. | ||
func StartApiServer( |
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.
AA entrypoint
|
||
// Config create an apiserver config | ||
func (o ServerOptions) Config() (*apiserver.Config, error) { | ||
if err := o.RecommendedOptions.SecureServing.MaybeDefaultWithSelfSignedCerts( |
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.
The CA issue is left for later resolution
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.
self-sign certs and skip tls verify should be enough for internal use
) | ||
|
||
// store implements a ConfigMap backed storage.Interface | ||
type store struct { |
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.
Implementation of a kube-apiserver based storage.Interface
, however, the implementation of watch
is naive and will be improved in an separated PR.
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.
add some unit tests to cover basic use cases?
/run-e2e-in-kind |
e2e is not working for this issue now, because the apiserver lib introduce a dependency
I will fix it soon, it does not block reviewing, though. |
/run-e2e-in-kind |
1 similar comment
/run-e2e-in-kind |
I've added a command to install hg in CI script. |
@cofyc Thanks! |
@@ -32,4 +32,5 @@ import ( | |||
_ "k8s.io/code-generator/cmd/openapi-gen" | |||
_ "k8s.io/code-generator/cmd/register-gen" | |||
_ "k8s.io/code-generator/cmd/set-gen" | |||
_ "github.com/kubernetes-incubator/apiserver-builder-alpha/cmd/apiregister-gen" |
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.
why not use sigs.k8s.io/apiserver-builder-alpha/cmd/apiregister-gen
?
this project is moved to https://github.com/kubernetes-sigs/apiserver-builder-alpha/ now.
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.
The pinned version v1.12 was still using the kubernetes-incubator
import path, we can use sigs.k8s.io....
after we bump the kubernetes dependencies to v1.16
because I renamed |
@cofyc Thanks for noting! |
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
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.
LGTM
Signed-off-by: Aylei <rayingecho@gmail.com>
Signed-off-by: Aylei <rayingecho@gmail.com>
/run-e2e-tests |
@cofyc @tennix @onlymellb @DanielZhangQD I've addressed the review comments and add the basic unit tests for /run-e2e-in-kind |
/run-e2e-in-kind |
Signed-off-by: Aylei <rayingecho@gmail.com>
/run-e2e-in-kind |
3 similar comments
/run-e2e-in-kind |
/run-e2e-in-kind |
/run-e2e-in-kind |
/run-e2e-in-kind |
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.
LGTM
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.
LGTM
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.
LGTM
Signed-off-by: Aylei rayingecho@gmail.com
What problem does this PR solve?
#1002
What is changed and how does it work?
Add aggregated apiserver skeleton and toolchain.
More todos are listed in the original issue #1002
Check List
Tests
Manual test
Code changes
Does this PR introduce a user-facing change?:
Here's an example about adding new resources in AA: aylei#1
To make review easier, I split this PR to multiple commits:
DataResource
as the storage of our AA: 9103ca8storage.Interface
: 209a6e1PTAL @weekface @cofyc @tennix @onlymellb @Yisaer @DanielZhangQD