kubernetes-sigs / kube-scheduler-wasm-extension

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

Support EventRecorder #83

Closed Gekko0114 closed 3 months ago

Gekko0114 commented 5 months ago

What type of PR is this?

/kind feature

Optionally add one or more of the following kinds if applicable: /kind api-change

What this PR does / why we need it:

Support EventRecorder

Which issue(s) this PR fixes:

Part of #73

Special notes for your reviewer:

Does this PR introduce a user-facing change?

Support EventRecorder

What are the benchmark results of this change?

goos: darwin
goarch: amd64
pkg: sigs.k8s.io/kube-scheduler-wasm-extension/internal/e2e/scheduler
cpu: Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
                                      │  before.txt  │              after.txt               │
                                      │    sec/op    │    sec/op      vs base               │
Example_NodeNumber/Simple/New-4         188.5m ± 10%    200.2m ±  8%        ~ (p=0.485 n=6)
Example_NodeNumber/Simple/Run-4         616.8µ ± 71%    322.9µ ± 24%  -47.64% (p=0.026 n=6)
Example_NodeNumber/Simple_Log/New-4     299.5m ± 31%    210.5m ± 29%        ~ (p=0.093 n=6)
Example_NodeNumber/Simple_Log/Run-4     393.9µ ± 28%    305.7µ ± 18%  -22.38% (p=0.015 n=6)
Example_NodeNumber/Advanced/New-4       258.5m ± 45%    248.6m ± 65%        ~ (p=1.000 n=6)
Example_NodeNumber/Advanced/Run-4       94.82µ ± 33%   129.47µ ± 28%  +36.54% (p=0.015 n=6)
Example_NodeNumber/Advanced_Log/New-4   258.6m ± 13%    299.3m ± 21%        ~ (p=0.132 n=6)
Example_NodeNumber/Advanced_Log/Run-4   99.73µ ± 21%   126.66µ ± 10%  +27.01% (p=0.002 n=6)
geomean                                 7.367m          6.890m         -6.48%
Gekko0114 commented 4 months ago

/assign @sanposhiho ,

Created a PR. PTAL. Thanks,

Gekko0114 commented 4 months ago

/assign /assign @sanposhiho

sanposhiho commented 4 months ago

Sorry for the delay, will review it in this weekend hopefully.

Gekko0114 commented 4 months ago

@sanposhiho , Thanks for your review. Fixed it. PTAL when you have time (it's not urgent)

Gekko0114 commented 4 months ago

Hi @sanposhiho @codefromthecrypt Thanks for your suggestions. Based on the discussion, I removed handle. PTAL when you have time.

sanposhiho commented 4 months ago

I'm curious to see the benchmark result, can you update your PR description, following the instruction: https://github.com/kubernetes-sigs/kube-scheduler-wasm-extension/blob/73a62c8e1abe3e0efe6c523610b3cc270cdcd1f0/.github/PULL_REQUEST_TEMPLATE.md#L53-L65

Gekko0114 commented 4 months ago

@sanposhiho, Thanks for your review. PTAL again when you have time.

Gekko0114 commented 3 months ago

/label tide/merge-method-squash

k8s-ci-robot commented 3 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Gekko0114, 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