Skip to content

Add two dependencies #302

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

Closed
wants to merge 2 commits into from
Closed

Add two dependencies #302

wants to merge 2 commits into from

Conversation

xueweiz
Copy link
Contributor

@xueweiz xueweiz commented Jun 27, 2019

This PR introduced two dependencies:

  • github.com/shirou/gopsutil/host
  • github.com/cobaugh/osrelease

They are needed in #303. I separated out the vendor changes, because they are larger while easier to
review.

They are done via:

GO111MODULE=on go get github.com/shirou/gopsutil/host
GO111MODULE=on go mod vendor
GO111MODULE=on go get github.com/cobaugh/osrelease
GO111MODULE=on go mod vendor

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jun 27, 2019
@k8s-ci-robot
Copy link
Contributor

Hi @xueweiz. Thanks for your PR.

I'm waiting for a kubernetes 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 needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jun 27, 2019
@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jun 27, 2019
@xueweiz
Copy link
Contributor Author

xueweiz commented Jun 27, 2019

/assign @wangzhen127

@wangzhen127
Copy link
Member

/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 27, 2019
@wangzhen127
Copy link
Member

What functions do you plan to use from this library? I am trying to see what is being used by kubernetes community for similar functionalities and check if there is any best practice.

@xueweiz
Copy link
Contributor Author

xueweiz commented Jun 27, 2019

btw this is still the gopsutil library (#289) we used for retrieving disk stats in #275

The library is composed of a few components (host, process, mem, disk, etc...). I only included disk last time.
Actually, maybe I should just include all of them in the vendor. Because we will probably need them in near future anyways. WDYT?

Xuewei Zhang added 2 commits June 27, 2019 16:50
This is needed to measure system uptime and kernel version.

This done via:
GO111MODULE=on go get github.com/shirou/gopsutil/host
GO111MODULE=on go mod vendor
This is needed for parsing /etc/os-release file.

This done via:
GO111MODULE=on go get github.com/cobaugh/osrelease
GO111MODULE=on go mod vendor
@xueweiz xueweiz changed the title Add github.com/shirou/gopsutil/host to vendor Add two dependencies Jun 27, 2019
@wangzhen127
Copy link
Member

Actually, maybe I should just include all of them in the vendor. Because we will probably need them in near future anyways. WDYT?

Sounds good to me.

I didn't find any similar usage in k8s. Let's use this for now. We can change to other stuff later if there is any better library.

@xueweiz
Copy link
Contributor Author

xueweiz commented Jun 28, 2019

Actually, maybe I should just include all of them in the vendor

Seems this is not very straight forward. When I do go mod vendor, it automatically drops all unused modules.

Let's just import what we use right now, and import the new ones when we need them.

@wangzhen127
Copy link
Member

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 2, 2019
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: wangzhen127, xueweiz

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 Jul 2, 2019
@wangzhen127
Copy link
Member

/hold
Are you going to merge this first and then the other one?

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 2, 2019
@xueweiz
Copy link
Contributor Author

xueweiz commented Jul 2, 2019

Yes, I plan to merge this first. Then rebase #303 , then merge #303

@xueweiz
Copy link
Contributor Author

xueweiz commented Jul 2, 2019

/retest

@k8s-ci-robot
Copy link
Contributor

@xueweiz: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags
pull-npd-e2e-kubernetes-gce-gci-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci-custom-flags
pull-npd-e2e-kubernetes-gce-gci b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci
pull-npd-e2e-kubernetes-gce-ubuntu b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@k8s-ci-robot
Copy link
Contributor

@xueweiz: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-npd-e2e-kubernetes-gce-ubuntu b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu
pull-npd-e2e-kubernetes-gce-gci-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci-custom-flags
pull-npd-e2e-kubernetes-gce-gci b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci
pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@k8s-ci-robot
Copy link
Contributor

@xueweiz: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-npd-e2e-kubernetes-gce-ubuntu b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu
pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags
pull-npd-e2e-kubernetes-gce-gci b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci
pull-npd-e2e-kubernetes-gce-gci-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci-custom-flags

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@k8s-ci-robot
Copy link
Contributor

@xueweiz: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-npd-e2e-kubernetes-gce-ubuntu b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu
pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-ubuntu-custom-flags
pull-npd-e2e-kubernetes-gce-gci-custom-flags b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci-custom-flags
pull-npd-e2e-kubernetes-gce-gci b517ea0 link /test pull-npd-e2e-kubernetes-gce-gci

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@xueweiz
Copy link
Contributor Author

xueweiz commented Jul 2, 2019

For convenience, let's just submit the vendor changes as part of #303
I'll drop this PR.

@xueweiz xueweiz closed this Jul 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
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. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm "Looks good to me", 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.

3 participants