Giter Site home page Giter Site logo

Comments (8)

88250 avatar 88250 commented on June 7, 2024

思源笔记的同步方案不是为了能支持在线实时同步的,提高同步间隔虽然可以解决这个场景需求,但是存在较大副作用:文件较多时频繁同步会占用大量系统资源,特别是移动端上会增加设备耗电。所以 30s 的间隔是个较为稳妥的设置,不建议修改。

from siyuan.

yong900630 avatar yong900630 commented on June 7, 2024

那么能否允许用户自行设定同步时间呢?对于长期使用台式电脑的人来说,根本不需要关心耗电。
大部分的思源笔记修改的地方都在文字方面,而文字方面的同步本身并不怎么占用空间和流量。

from siyuan.

88250 avatar 88250 commented on June 7, 2024

这个不只是耗电,数据量大了以后频繁同步会占用很多系统资源的。

from siyuan.

88250 avatar 88250 commented on June 7, 2024

为了大部分用户能稳定运行,不考虑开放这个配置项,如果实在要改的话估计只能考虑修改源码自行编译了。

from siyuan.

yong900630 avatar yong900630 commented on June 7, 2024

也就是说siyuan同步的时候,S3云端是记录了每一次同步的数据,然后其他设备与S3云端同步时会同步上一次同步到最近同步每一次的同步数据。
比如2024年5月10日,早上10:00 A设备开始每1分钟同步一次,一直到12:00,会产生120次同步,S3端储存了120次的同步数据。
然后B设备最近一次同步时间在10:00,然后再12:05分打开设备,进行同步,然后该次同步会120次的同步数据(即使120次同步当中很多数据,已经不需要了)

from siyuan.

88250 avatar 88250 commented on June 7, 2024

不是,同步是对比差异后增量同步的。

from siyuan.

yong900630 avatar yong900630 commented on June 7, 2024

如果是对比差异后增量同步,那么严格讲很占用资源啊。S3端是对象存储,本身不具备计算能力,那么肯定是本地设备将数据与S3端的数据比对,消耗的资源是S3端。

您这里指的消耗资源是指本地设备需要读取全部S3端数据,每个块全部比对一遍在同步吗?如果真是这样的话,随着笔记的数据增多,那么以后每次同步都会越来越卡。但是思源笔记同步速度感觉还是非常快的,我用的是第三方七牛云S3端同步。

目前我的思源笔记基本只有几百M,以文字为主+少量图片,视频采用储存视频地址的方式来减少空间的占用。

from siyuan.

88250 avatar 88250 commented on June 7, 2024

您这里指的消耗资源是指本地设备需要读取全部S3端数据,每个块全部比对一遍在同步吗?

不需要全部读取,仅读取索引,通过索引就可以对比差异了,具体代码参见 https://github.com/siyuan-note/dejavu

from siyuan.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.