kubernetes-sigs / kube-scheduler-wasm-extension

All the things to make the scheduler extendable with wasm.
Apache License 2.0
110 stars 22 forks source link

config: add support to file:// and http(s):// URIs #68

Closed evacchi closed 1 year ago

evacchi commented 1 year ago

What type of PR is this?

/kind feature

/kind api-change

What this PR does / why we need it:

Extends the current plugin config to use instead a URI. In the case of file:// the behavior is the same as it is currently. In the case of http(s):// it will fetch the URI and try to evaluate it as a wasm payload.

This PR is based on earlier work on dapr/component-contrib. See: https://github.com/dapr/components-contrib/pull/3005

Which issue(s) this PR fixes:

n/a will create if required.

Special notes for your reviewer:

n/a

Does this PR introduce a user-facing change?


Changes `PluginConfig.ConfigPath` to `PluginConfig.ConfigURL`. A local path must now be prefixed with `file://`. A local path will be of the form `file://relativepath/myfile.wasm` or `file:///absolute/path/to/myfile.wasm`.

What are the benchmark results of this change?

n/a

linux-foundation-easycla[bot] commented 1 year ago

CLA Signed

The committers listed above are authorized under a signed CLA.

k8s-ci-robot commented 1 year ago

Welcome @evacchi!

It looks like this is your first PR to kubernetes-sigs/kube-scheduler-wasm-extension 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/kube-scheduler-wasm-extension has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. :smiley:

k8s-ci-robot commented 1 year ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: evacchi, sanposhiho

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: - ~~[OWNERS](https://github.com/kubernetes-sigs/kube-scheduler-wasm-extension/blob/main/OWNERS)~~ [sanposhiho] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
codefromthecrypt commented 1 year ago

Thanks @evacchi /lgtm

codefromthecrypt commented 1 year ago

/lgtm