From owner-freebsd-hackers@freebsd.org Fri Nov 20 21:18:04 2015 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 98EAEA33C42 for ; Fri, 20 Nov 2015 21:18:04 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from mx1.scaleengine.net (mx1.scaleengine.net [209.51.186.6]) by mx1.freebsd.org (Postfix) with ESMTP id 72FF21E23 for ; Fri, 20 Nov 2015 21:18:04 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from [10.1.1.2] (unknown [10.1.1.2]) (Authenticated sender: allanjude.freebsd@scaleengine.com) by mx1.scaleengine.net (Postfix) with ESMTPSA id 08B01DEE0 for ; Fri, 20 Nov 2015 21:18:03 +0000 (UTC) Subject: Re: libUCL / UCL as FreeBSD config question To: freebsd-hackers@freebsd.org References: <5B598F72-C5DD-48FD-866D-F90E117D646E@rdsor.ro> <564F6118.5030702@freebsd.org> <5576AC9A-791F-4B52-9433-32D2806D35C9@rdsor.ro> From: Allan Jude X-Enigmail-Draft-Status: N1110 Message-ID: <564F8E1F.8060600@freebsd.org> Date: Fri, 20 Nov 2015 16:18:23 -0500 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <5576AC9A-791F-4B52-9433-32D2806D35C9@rdsor.ro> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="MWvHNptkpS1nt4kgBwmx0RwXTr7leHRGK" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Nov 2015 21:18:04 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --MWvHNptkpS1nt4kgBwmx0RwXTr7leHRGK Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2015-11-20 15:46, Dan Partelly wrote: > Allan, >=20 > Thanks for clearing my confusion, and furthering my understanding on wh= ats cooking on this front. >=20 > The tool is dandy. I have another issue I want to ask about: >=20 > concurrency. Is there any support in either uclib and the tools like uc= lcmd to ensure=20 > atomic access to the ucl files ? And not on advisory level, (although i= f utilities would respect=20 > adviasory looking =E2=80=A6 it would be better than nothing). I mean so= mething on the lines > of mandatory locking.=20 >=20 > Was the question of concurrency discussed ? >=20 > Dan >=20 >=20 Most of the discussion centered around the design of the config files, and the library. My tool is in the early stages and was only briefly discussed with the goal of showing the power of UCL from an automation standpoint. Obviously uclcmd can use locking to ensure that two instances do not overlap. Updates to the file would also be atomic (save to tmpfile then rename into place), and it could check that the modification date of the file has not changed since it was read, to avoid overlapping any other access to the file. In the end, I picture it being somewhat like 'vipw' --=20 Allan Jude --MWvHNptkpS1nt4kgBwmx0RwXTr7leHRGK Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (MingW32) iQIcBAEBAgAGBQJWT44iAAoJEBmVNT4SmAt+E44P/18Z3HdKQp/gS8J0e6q7NhM0 wIPyNXX86ff88L0sCK1oljlydx+dZAcd8CwKDot7TUDixiPVrz/V20JLvY/o281w TtkHf1zVnJkYc1mVC8p/lJzAlgwCLcHqAX24PGG6NdQJIwUNtGn3xjlwSSKIIxMY tXUi8jKGaTO5A80YiyRJxkdOfZkP2wRqtaXpvv/EiI8e2O6dsEPt2aHW3k4CKB/3 6UdG8XDScvvyeKVoDhAuhkdAX9rYlZ3qWcjAYox2DFSIQeK04jV8mBGtgAXIYTYD w/9qhs1dPHGl4SLud5cJIZcUyv0PW4D/Fv85dZ1UrJulR6UaZUldtCqXeS9p7xyE 1QSeODmlDiPiPdBS9dbBWFNmTUzC3dF04klWjKabbiOzAxdtb1Znz/wJEGkafaAU u0SIA2zHe1vLhLzdQusydXuXKomZN+uDD8yOHZ+acchlxPOVq1M/7VX+HQOr2Kuj VYUgT1iYvXYrsG8+yy9ts9Tki4tuUdOWYvb9Grvhz1/VraOXIpZEwU0IQmDbGHGJ fHh/LO8CHCmlriOj9yrIwzLqN1Q0WdtS/7SU1tXD03+fFcl3MIiZp/x+XJf84PY8 b3rELsq0vpLAW2l+fY9j25ecp1xw+JQDIRf9mi9sK6DThWSSL2Owqdiwf8WxfvnP aFj4e8jKEq97YiS/UxV2 =ktsO -----END PGP SIGNATURE----- --MWvHNptkpS1nt4kgBwmx0RwXTr7leHRGK--