Skip to content
This repository has been archived by the owner on Jun 26, 2023. It is now read-only.

[Kubectl-MTB] Added packages, cli structure and one benchmark #794

Merged
merged 7 commits into from
Jun 11, 2020

Conversation

phoenixking25
Copy link
Contributor

/assign @JimBugwadia

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jun 7, 2020
@k8s-ci-robot
Copy link
Contributor

Hi @phoenixking25. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jun 7, 2020
@phoenixking25 phoenixking25 changed the title [MTB] Added Benchmark and Benchmark-suite package WIP [MTB] Added Benchmark and Benchmark-suite package Jun 8, 2020
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 8, 2020
@phoenixking25 phoenixking25 changed the title WIP [MTB] Added Benchmark and Benchmark-suite package WIP [Kubectl-MTB] Added packages and cli structure Jun 8, 2020
@k8s-ci-robot k8s-ci-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jun 8, 2020
@phoenixking25 phoenixking25 changed the title WIP [Kubectl-MTB] Added packages and cli structure [Kubectl-MTB] Added packages and cli structure Jun 8, 2020
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 8, 2020
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Jun 9, 2020
@phoenixking25 phoenixking25 changed the title [Kubectl-MTB] Added packages and cli structure [Kubectl-MTB] Added packages, cli structure and one benchmark Jun 10, 2020
@JimBugwadia
Copy link
Contributor

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jun 11, 2020

Run: func(cmd *cobra.Command, args []string) {
if len(benchmarks) == 0 {
fmt.Println("No Benchmarks to get.")
Copy link
Contributor

Choose a reason for hiding this comment

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

change to "No benchmarks found."


var getCmd = &cobra.Command{
Use: "get",
Short: "List the Multi-Tenancy Benchmarks",
Copy link
Contributor

Choose a reason for hiding this comment

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

Change to "Display one or many benchmarks." to match kubectl messages

// rootCmd represents the base command when called without any subcommands
rootCmd = &cobra.Command{
Use: "kubectl-mtb",
Short: "Multi-Tenancy Benchmarking",
Copy link
Contributor

Choose a reason for hiding this comment

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

Change to "Multi-Tenancy Benchmarks"

os.Exit(1)
}

impersonateServiceAccount := "system:serviceaccount:" + tenantNamespace + ":" + tenant
Copy link
Contributor

Choose a reason for hiding this comment

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

remove assumption on using "system:serviceaccount". The user can pass in a name with "system:serviceaccount:namespace:..." if they want to use a service account for tests.

}

// GetTotalBenchmarks returns count of benchmarks in Benchmark Suite
func (bs *BenchmarkSuite) GetTotalBenchmarks() int {
Copy link
Contributor

Choose a reason for hiding this comment

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

rename to "Totals"

}

// AddBenchmark appends the benchmark in the BenchmarkSuite
func (bs *BenchmarkSuite) AddBenchmark(benchmark *benchmark.Benchmark) {
Copy link
Contributor

Choose a reason for hiding this comment

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

rename to "Add"

}

// GetBenchmarksOfProfileLevel return slice of Benchmarks of Profile level given in input
func (bs *BenchmarkSuite) GetBenchmarksOfProfileLevel(pl int) []*benchmark.Benchmark {
Copy link
Contributor

Choose a reason for hiding this comment

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

rename to "ProfileLevel"

@JimBugwadia
Copy link
Contributor

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jun 11, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JimBugwadia, phoenixking25

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 11, 2020
@k8s-ci-robot k8s-ci-robot merged commit 1394030 into kubernetes-retired:master Jun 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants