-
Notifications
You must be signed in to change notification settings - Fork 17
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
Feat/wk/schedule v2 #94
Conversation
Codecov Report
@@ Coverage Diff @@
## main #94 +/- ##
=======================================
Coverage 40.63% 40.63%
=======================================
Files 8 8
Lines 507 507
=======================================
Hits 206 206
Misses 296 296
Partials 5 5
Flags with carried forward coverage won't be shown. Click here to find out more. |
0ed7781
to
3f20485
Compare
21403ef
to
26d4a10
Compare
RuntimeStatus string `json:"runtimeStatus,omitempty"` | ||
} | ||
|
||
const ( |
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.
type RuntimeStatus 给个 enum 把
|
||
if instance.Status.Resource == nil { | ||
newScheduler := scheduler.NewScheduler(s.client, s.apiReader, KindNameNetReach, instance.Name, s.runtimeUniqueMatchLabelKey, logger) | ||
resource, err = newScheduler.CreateTaskRuntimeIfNotExist(ctx, &instance, instance.Spec.AgentSpec) |
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.
// comment: creat the resource and update to creating status
if instance.DeletionTimestamp != nil { | ||
s.logger.Sugar().Debugf("ignore deleting task %v", req) | ||
return ctrl.Result{}, nil | ||
} | ||
|
||
// create resource |
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.
有好几个 kind 都 复用这段 类似的代码,是否 可抽象出函数
|
||
newRecord := NewStatusHistoryRecord(startTime, int(n+1), schedulePlan) | ||
// add new round record |
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.
这个 函数中的这些 新增 代码, 是因为 原来的有 bug 么 ?
} | ||
} | ||
|
||
// let the tracker trace status |
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.
// comment:
// trace, will do things:
// the tracer will be asynchronous to update the resource status in the CR
//
@@ -0,0 +1,126 @@ | |||
// Copyright 2023 Authors of kdoctor-io | |||
// SPDX-License-Identifier: Apache-2.0 |
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.
readme.md
(1) created
(2)delete,
add corresponding E2E in test/docs |
397261a
to
6583342
Compare
Signed-off-by: Icarus9913 <icaruswu66@qq.com>
3a6437a
to
4031452
Compare
4031452
to
eae7088
Compare
Signed-off-by: Icarus9913 <icaruswu66@qq.com>
cb84163
to
e1c9c7e
Compare
No description provided.