From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ihor Radchenko Newsgroups: gmane.emacs.devel Subject: Re: persistent data feature Date: Sat, 11 Dec 2021 09:43:50 +0800 Message-ID: <877dcbncfd.fsf@localhost> References: <87tufmjyai.fsf@gnus.org> <877dcil2sj.fsf@ericabrahamsen.net> <87czm98qi1.fsf@gnu.org> <87o85tcwm0.fsf@ericabrahamsen.net> <874k7ljwkr.fsf@gnus.org> <87fsr5cuzq.fsf@ericabrahamsen.net> <878rwx8mdn.fsf@gnu.org> <87r1aphuei.fsf@gnus.org> <837dcex6ub.fsf@gnu.org> <87bl1p10js.fsf@gnus.org> <87a6h8y5j6.fsf@gnus.org> <87fsr0gssu.fsf@rfc20.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14419"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Richard Stallman , eric@ericabrahamsen.net, cesar.mena@gmail.com, emacs-devel@gnu.org, Pip Cet , Matt Armstrong , Lars Ingebrigtsen , eliz@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Dec 11 02:44:16 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mvrQu-0003YH-60 for ged-emacs-devel@m.gmane-mx.org; Sat, 11 Dec 2021 02:44:16 +0100 Original-Received: from localhost ([::1]:34478 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mvrQs-0005UN-DJ for ged-emacs-devel@m.gmane-mx.org; Fri, 10 Dec 2021 20:44:14 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:39774) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mvrPC-0003uW-O5 for emacs-devel@gnu.org; Fri, 10 Dec 2021 20:42:34 -0500 Original-Received: from [2a00:1450:4864:20::12d] (port=46969 helo=mail-lf1-x12d.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mvrPB-0004S4-AZ; Fri, 10 Dec 2021 20:42:30 -0500 Original-Received: by mail-lf1-x12d.google.com with SMTP id b1so21005480lfs.13; Fri, 10 Dec 2021 17:42:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=hNrtjiKydlVtrpa4v4UuWYXlPdFfRPjuOoUVhFlW5Hg=; b=fbcA5P3riN3LUX1w+hS63faKOjrvoVo90erlk0f/ijI4SClfg1bwuxtvtSN1sWrlKP 2+qxL1hIm2wieZbx23FVvQXpDBl+3lazfA/A5H17DZinJDfuvz2WS9yKwGI+gn+AZ1ca G6Ywuz5V7HcZUI7kzBMf5bkn9SJ69jD5RcoI2018tOM2kurNtz4O5Ta9hSNJzLFPxPKs 4XkhmBaJvFl2+wpknnjOuqjz7px+uSl6Fo791Cesp5/Arkss57ClCXkPRFYrE9JYuMNZ zeTYNu4SDldiWJcEIB2sajgSsPrkd/7TVfeXyiN/qWl4XdXIrX/s1FR3/1ia2sXSxsxg oZig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=hNrtjiKydlVtrpa4v4UuWYXlPdFfRPjuOoUVhFlW5Hg=; b=J8L5NNxSG/OnU1qqFOkO0lAItXkO5N1rUzuBbZo/eTnTCy3/WVGEbDFAm8VP66dc7l rnm57UH/RANAUSYfvVdRbzA56vcVhjpdWYkV9nhboIvDevnRosK/97Yf3ef9futax/xD Mpj9j4vwwqyClSGtbhqyvHEw2CaSMsSJNxcsAWB0fee34BWvwz9tyCm2LFUqNlbwJzJo Qg+k/LyZJKIjYHWUqxY+JkfmMMuSZVqzmUl2cXLmTmTnVtCi/yadUFIK2f8MHpH3T/lx M3knOgZMF/IRzUEnEIx8bync3t1DeuaZgz910xekVcy71/6rIw/bzxQuhNM04j+O+7xj 9c0g== X-Gm-Message-State: AOAM530oSPaPQ9f4phzIOMuB36KlP0e0v1w9MTl/iWfK5YxDudhCicke anpBhsAQWQbIjvuFLL7+tlk= X-Google-Smtp-Source: ABdhPJwZUkxaaK41L+ETgFN1quxCluWqJaVIzfTPY9TznLOeaRQRlGMRCh2ljWV5rHsMzv6fGUToWA== X-Received: by 2002:a05:6512:2521:: with SMTP id be33mr15650216lfb.524.1639186946135; Fri, 10 Dec 2021 17:42:26 -0800 (PST) Original-Received: from localhost ([158.255.2.9]) by smtp.gmail.com with ESMTPSA id w8sm465080lfe.183.2021.12.10.17.42.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Dec 2021 17:42:25 -0800 (PST) In-Reply-To: X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:1450:4864:20::12d (failed) Received-SPF: pass client-ip=2a00:1450:4864:20::12d; envelope-from=yantar92@gmail.com; helo=mail-lf1-x12d.google.com X-Spam_score_int: -10 X-Spam_score: -1.1 X-Spam_bar: - X-Spam_report: (-1.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:281635 Archived-At: Stefan Monnier writes: >> Another example is Org Roam (https://www.orgroam.com/), which uses >> sqlite to manage its index of Org metadata. > > Could you give details? > > I don't know what is Org-roam (and the above web-page describes it in > terms that don't speak to me very much). What does it store in the > database? Why did it choose to use sqlite rather than plain text > (e.g. simple personal preference on the part of the author, or was > a text file tried at first but proved too inefficient, if so which > part)? What kind of database size is common? Org-roam stores Org headline metadata like headline title, todo-state, scheduling info, properties, tags, links to other headings, etc. AFAIU, they use sqlite for easier integration with third-party tools. For example, links between headings can be visualised using existing web-libraries (see https://github.com/org-roam/org-roam-ui/blob/main/package.json) As for the DB size, I am not sure. However, it should scale with the number of headings. You may think of 10-100k headline DB records and a multiple of that number for links between headings. Best, Ihor