morny-book/command/save.md

34 lines
1.2 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# /save
> 保存缓存数据到文件(仅[可信成员](../trusted)
<style>
@import "../stickers.css";
</style>
<font color=palevioletred>
**此工具仅限 [可信成员](../trusted) 使用**
这是一个管理类工具,它拥有操作 Morny Cono 的内部 API 的功能并导致服务器资源过载的可能
</font>
这个命令可以让所有的 *需要使用数据持久化的服务功能* 立即和磁盘同步数据。
当保存任务执行成功后,它将会返回贴纸 `ID_SAVED`
{.sticker}
![morny sticker ID_SAVED](https://stickers.sukazyo.cc/sticker/CAACAgEAAx0CSQh32gABBExuYdB_G0srfhQldRWkBYxWzCOv4-IAApooAAJ4_MYFcjuNZszfQcQjBA.png)
当失败时命令将会不反回任何东西。
不过目前 Morny 并没有任何的服务使用到了数据持久化功能。所以,这个命令可以被认为是除了返回一个贴纸以外没有用途的。
## Log 记录
作为一个管理类命令,它也拥有和 [`/exit`](./exit) 差不多的 Log 记录。不过不同的是 **`/save`** 只会在当用户没有权限时记录一条 log当用户有权限执行时将不会特定的对这个操作记录 log
```log
[INFO] 403 call save tag from user qwq [676559089]
```