From debbugs-submit-bounces@debbugs.gnu.org Mon May 11 11:06:21 2020 Received: (at 41180) by debbugs.gnu.org; 11 May 2020 15:06:21 +0000 Received: from localhost ([127.0.0.1]:52955 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jYA0a-00064d-U7 for submit@debbugs.gnu.org; Mon, 11 May 2020 11:06:21 -0400 Received: from eggs.gnu.org ([209.51.188.92]:33510) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jYA0V-00064H-UP for 41180@debbugs.gnu.org; Mon, 11 May 2020 11:06:19 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:38012) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jYA0Q-0003U8-Ig; Mon, 11 May 2020 11:06:10 -0400 Received: from [2a01:cb18:832e:5f00:fd66:fbb0:b5a6:36b6] (port=35294 helo=meru) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jYA0Q-0004oL-1Y; Mon, 11 May 2020 11:06:10 -0400 From: Mathieu Othacehe To: Jean-Baptiste Note Subject: Re: [bug#41180] [PATCH] Add cachefilesd service. References: <87v9l3zjg7.fsf@m4x.org> Date: Mon, 11 May 2020 17:06:08 +0200 In-Reply-To: <87v9l3zjg7.fsf@m4x.org> (Jean-Baptiste Note's message of "Sun, 10 May 2020 19:19:36 +0000") Message-ID: <878shywly7.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 41180 Cc: 41180@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hello Jean-Baptiste, Thanks for this service! > - I gathered that #~ / #$ kinds of suspends evaluation / forces it -- is > there documentation about this somewhere ? #~ and #$ are related to the Gexp mechanism. It's documented here: https://guix.gnu.org/manual/en/html_node/G_002dExpressions.html. > - There's something that looks like a splat operator (only seen in > conjuction with forcing evaluation in #$@) -- again i'd be interested > in more documentation about this feature -- is this a guix-specific > operator? #$@ is a shortcut for ungexp-splicing. It's also documented in the link above. It can be a bit puzzling at start, don't hesitate to ask some help on #guix channel. > - I don't understand why there are ^L separating services in the scheme > files -- is this necessary? A convention? What purpose does it serve? Yes, see the "Pagination" section in https://mumble.net/~campbell/scheme/style.txt. You can install "emacs-page-break-lines" to replace it by cleaner lines. > Regarding the patch itself: > > - i'm not entirely sure the service belongs to services/linux.scm I think it's fine. > - there are no automated tests (beyond what I have done by hand > locally!), and there's no lint, so I don't really feel confident about > it :) Are there tests for services to alleviate my fears? It would be nice to implement tests along with the new service definition. You can have a look to (gnu tests cups) module for instance. It tests the cups service by spawning a virtual-machine called a "marionette". You could create a (gnu tests cachefilesd) doing a similar job. See "Running the Test Suite" in the info page for more details on how to run the test suite. > - I've copied some other service for modprobing the required kernel > modules before launching the daemon with a one-shot shepherd > service. Frankly i'm not happy about this solution, it seems to me > that it unnecessarily pollutes the shepherd configuration; maybe some > other mechanism (graft?) adjusting the modprobe configuration could be > better (better still, autoload the file). Any guidance would be nice > (including, that this solution is sufficient for now :)) The ideal would be that cachefilesd loads the appropriated module. If this is not possible, we can discuss extending kernel-module-loader-service-type service. But for now I guess it's ok. I hope it answers your questions, I'll review the rest of the service later on. Thanks, Mathieu