-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Add internal kernel API /api/sqlite/flushTransaction
#10005
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
Comments
加入内核接口应该就够了,前端可以自己包装一下?
…---原始邮件---
发件人: ***@***.***>
发送时间: 2023年12月28日(周四) 晚上6:19
收件人: ***@***.***>;
抄送: ***@***.***>;
主题: [siyuan-note/siyuan] 希望加一个API,等待当前所有DB任务都写盘后才返回。 (Issue #10005)
In what scenarios do you need this feature?
有没有可能加一个flash db的API。等待所有pending的任务都给刷盘了。
有时候调用一些API后,虽然成功了,但db里是没有相关数据的。
插件中只能等待,或者间隔地循环尝试。插件引入这种设计,比较难维护。
另外,前端是否也能提供一个接口,等待编辑器里面的事务,也发送到后端。
有时我在编辑器写入内容,到内容出现在db,这个时间不好把握。
如果前端后端都有flash 接口,那就能准确地知道,何时查db,能查到刚刚写入的数据。
Describe the optimal solution
如果加入一个flushdb类似的api.
插件中可以这样用:
await createDoc()
await flushDB()
await queryDB()
Describe the candidate solution
No response
Other information
No response
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
@88250 也行,只是我目前不知道怎么搞。后续我再研究吧。先加内核的。谢谢! |
/api/sqlite/flushTransaction
88250
added a commit
that referenced
this issue
Dec 28, 2023
88250
added a commit
that referenced
this issue
Nov 19, 2024
EightDoor
added a commit
to EightDoor/siyuan
that referenced
this issue
Nov 22, 2024
* commit '928c1d476a4b398bdee3752cc950aed85838bf8f': (148 commits) 🔖 Release v3.1.13 🐛 Automatic cleanup of the local data repo may accidentally delete snapshots siyuan-note#13203 🎨 Add internal kernel API `/api/sqlite/flushTransaction` siyuan-note#10005 🐛 Automatic cleanup of the local data repo may accidentally delete snapshots siyuan-note#13203 🎨 删除块,嵌入块中没有同步删除 💄 🔖 Release v3.1.12 ⬆️ eslint 🎨 Improve graph rendering siyuan-note#13196 🎨 siyuan-note#13143 🎨 siyuan-note#13190 📝 Update changelogs ⬆️ 🎨 Improve av option editing siyuan-note#11484 🎨 siyuan-note#13164 🎨 Support HarmonyOS NEXT system siyuan-note#13184 🎨 siyuan-note#11053 🚨 🎨 siyuan-note#11053 🎨 Support HarmonyOS NEXT system siyuan-note#13184 ...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
希望加一个API,等待当前所有DB任务都写盘后才返回。
希望加一个API,等待当前所有DB任务都写盘后才返回。
In what scenarios do you need this feature?
有没有可能加一个flash db的API。等待所有pending的任务都给刷盘了。
有时候调用一些API后,虽然成功了,但db里是没有相关数据的。
插件中只能等待,或者间隔地循环尝试。插件引入这种设计,比较难维护。
另外,前端是否也能提供一个接口,等待编辑器里面的事务,也发送到后端。
有时我在编辑器写入内容,到内容出现在db,这个时间不好把握。
如果前端后端都有flash 接口,那就能准确地知道,何时查db,能查到刚刚写入的数据。
Describe the optimal solution
如果加入一个flushdb类似的api.
插件中可以这样用:
await createDoc()
await flushDB()
await queryDB()
Describe the candidate solution
No response
Other information
No response
The text was updated successfully, but these errors were encountered: