-
Notifications
You must be signed in to change notification settings - Fork 297
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: add docs about preheat console (#1072)
* docs: add preheat docs Signed-off-by: 赵安家 <[email protected]>
- Loading branch information
Showing
5 changed files
with
125 additions
and
4 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,65 @@ | ||
# WIP console | ||
# console | ||
|
||
TODO | ||
Use preheat console for preheating. | ||
First access Dragonfly Manager Console e.g. `http://dragonfly-manager:8080/service/task` | ||
and create preheat task for preheating. | ||
|
||
If the `scheduler_cluster_ids` does not selected, it means to preheat all scheduler clusters. | ||
|
||
![add-preheat-job](../images/manager-console/add-preheat-job.png) | ||
|
||
View preheat task list. | ||
|
||
![preheat-list](../images/manager-console/preheat-list.png) | ||
|
||
View preheat task details by Click `Description`. | ||
|
||
![preheat-list](../images/manager-console/preheat-job-detail.png) | ||
|
||
## FAQ | ||
|
||
### Create preheat task throw error | ||
|
||
If create preheat task throw error,html alert `http error`,network response http status code is `500`, | ||
Check whether Redis has write permission. | ||
|
||
Dragonfly Manager error logs like: | ||
|
||
```bash | ||
2022-02-15T08:30:01.123Z ERROR job/preheat.go:159 create preheat group job failed | ||
READONLY You can't write against a read only replica. | ||
d7y.io/dragonfly/v2/manager/job.(*preheat).createGroupJob | ||
/go/src/d7y.io/dragonfly/v2/manager/job/preheat.go:159 | ||
d7y.io/dragonfly/v2/manager/job.(*preheat).CreatePreheat | ||
/go/src/d7y.io/dragonfly/v2/manager/job/preheat.go:128 | ||
d7y.io/dragonfly/v2/manager/service.(*rest).CreatePreheatJob | ||
/go/src/d7y.io/dragonfly/v2/manager/service/job.go:71 | ||
d7y.io/dragonfly/v2/manager/handlers.(*Handlers).CreateJob | ||
/go/src/d7y.io/dragonfly/v2/manager/handlers/job.go:40 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
d7y.io/dragonfly/v2/manager/middlewares.Error.func1 | ||
/go/src/d7y.io/dragonfly/v2/manager/middlewares/error.go:42 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.CustomRecoveryWithWriter.func1 | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:99 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.LoggerWithConfig.func1 | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:241 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/mcuadros/go-gin-prometheus.(*Prometheus).HandlerFunc.func1 | ||
/go/pkg/mod/github.com/mcuadros/[email protected]/middleware.go:364 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.(*Engine).handleHTTPRequest | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:555 | ||
github.com/gin-gonic/gin.(*Engine).ServeHTTP | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:511 | ||
net/http.serverHandler.ServeHTTP | ||
/usr/local/go/src/net/http/server.go:2878 | ||
net/http.(*conn).serve | ||
/usr/local/go/src/net/http/server.go:1929 | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,62 @@ | ||
# WIP console | ||
# console | ||
|
||
TODO | ||
用户使用 Dragonfly Manager Console 进行预热。 | ||
首先访问 Dragonfly Manager Console e.g. `http://dragonfly-manager:8080/service/task` 创建预热任务。 | ||
|
||
如果不选择 `Scheduler Cluster` 则是对所有 Scheduler 进行预热。 | ||
|
||
![add-preheat-job](../../en/images/manager-console/add-preheat-job.png) | ||
|
||
查看预热任务列表 | ||
|
||
![preheat-list](../../en/images/manager-console/preheat-list.png) | ||
|
||
点击 `Description` 查看预热详情 | ||
|
||
![preheat-list](../../en/images/manager-console/preheat-job-detail.png) | ||
|
||
## FAQ | ||
|
||
### 创建预热任务报错 | ||
|
||
如果创建预热任务报错,接口返回500,页面提示 `http error`,需要排查 redis 是否具有写权限。 | ||
Dragonfly Manager 日志报错类似 | ||
|
||
```bash | ||
2022-02-15T08:30:01.123Z ERROR job/preheat.go:159 create preheat group job failed | ||
READONLY You can't write against a read only replica. | ||
d7y.io/dragonfly/v2/manager/job.(*preheat).createGroupJob | ||
/go/src/d7y.io/dragonfly/v2/manager/job/preheat.go:159 | ||
d7y.io/dragonfly/v2/manager/job.(*preheat).CreatePreheat | ||
/go/src/d7y.io/dragonfly/v2/manager/job/preheat.go:128 | ||
d7y.io/dragonfly/v2/manager/service.(*rest).CreatePreheatJob | ||
/go/src/d7y.io/dragonfly/v2/manager/service/job.go:71 | ||
d7y.io/dragonfly/v2/manager/handlers.(*Handlers).CreateJob | ||
/go/src/d7y.io/dragonfly/v2/manager/handlers/job.go:40 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
d7y.io/dragonfly/v2/manager/middlewares.Error.func1 | ||
/go/src/d7y.io/dragonfly/v2/manager/middlewares/error.go:42 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.CustomRecoveryWithWriter.func1 | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/recovery.go:99 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.LoggerWithConfig.func1 | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/logger.go:241 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/mcuadros/go-gin-prometheus.(*Prometheus).HandlerFunc.func1 | ||
/go/pkg/mod/github.com/mcuadros/[email protected]/middleware.go:364 | ||
github.com/gin-gonic/gin.(*Context).Next | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/context.go:168 | ||
github.com/gin-gonic/gin.(*Engine).handleHTTPRequest | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:555 | ||
github.com/gin-gonic/gin.(*Engine).ServeHTTP | ||
/go/pkg/mod/github.com/gin-gonic/[email protected]/gin.go:511 | ||
net/http.serverHandler.ServeHTTP | ||
/usr/local/go/src/net/http/server.go:2878 | ||
net/http.(*conn).serve | ||
/usr/local/go/src/net/http/server.go:1929 | ||
``` |