From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 29157 invoked from network); 11 Dec 2023 19:50:08 -0000 Received: from 9front.inri.net (168.235.81.73) by inbox.vuxu.org with ESMTPUTF8; 11 Dec 2023 19:50:08 -0000 Received: from mimir.eigenstate.org ([206.124.132.107]) by 9front; Mon Dec 11 14:46:36 -0500 2023 Received: from mimir.eigenstate.org (localhost [127.0.0.1]) by mimir.eigenstate.org (OpenSMTPD) with ESMTP id 205abb26 for <9front@9front.org>; Mon, 11 Dec 2023 11:46:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=eigenstate.org; h= message-id:to:subject:date:from:in-reply-to:mime-version :content-type:content-transfer-encoding; s=mail; bh=u7TsYhfRsS0j R4IReRTht8ULYlY=; b=IqUIYxjcf5s1c6XbmfjszOW1dj/6flWSvqcpsTVuKa4Y NNhhJycDEtcY5HsS/elKg9bl+/FiNnifO2PIBs9qykvKJoDoD+7Po1VzE5sU5+xm b0dSOrh8QFd+Lr3oOcDbw0r8qihInasLZwPnI8ZgbJjOjh2PnqyeAnN3mWkzTaE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=eigenstate.org; h=message-id :to:subject:date:from:in-reply-to:mime-version:content-type :content-transfer-encoding; q=dns; s=mail; b=gLj6KaXUXeyEoAr7x/o RJlBOp8Git/crslJY4SU9Gw8ZhGIETAy6n08irSLFs4IP9+Ik/X0Q8UaUpKg9JOg 1DSnstygiwlTd1y3bQ3+NVz4TQrQlmBiHTfr5COXpteJHQPXKv40JkZ05/Af3qZV idYMjKx43pHC3ZNj1UBTVAik= Received: from abbatoir (pool-108-6-24-2.nycmny.fios.verizon.net [108.6.24.2]) by mimir.eigenstate.org (OpenSMTPD) with ESMTPSA id 1ace8dc9 (TLSv1.2:ECDHE-RSA-AES256-SHA:256:NO) for <9front@9front.org>; Mon, 11 Dec 2023 11:46:33 -0800 (PST) Message-ID: To: 9front@9front.org Date: Mon, 11 Dec 2023 14:46:32 -0500 From: ori@eigenstate.org In-Reply-To: <8A65A33C9E3CCA551969AB24AD93D321@smtp.pobox.com> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit List-ID: <9front.9front.org> List-Help: X-Glyph: ➈ X-Bullshit: encrypted mobile database map/reduce database Subject: Re: [9front] [PATCH 6/6] ndb: document attribute name and value length constraints in BUGS section of man page Reply-To: 9front@9front.org Precedence: bulk Looking at the code, Ndbvlen seems to be a soft limit; it's only the initial allocation to save a malloc, but we can grow past it; see ndbsetval in /sys/src/libndb/ndbfree.c:29. There is a soft limit coming from Brdline, which depends on the size of the buffer in the NDB struct; maybe we should document that a line must be no longer than 8k. (This was bumped not so long ago to support the large TXT records needed by DKIM). That said, I think documenting the attribute size is a good idea. Quoth unobe@cpan.org: > Ping. > > Quoth unobe@cpan.org: > > I came across these limitations (defined in /sys/include/ndb.h as > > Ndbalen and Ndbvlen, respectively) when toying around with ndb as a > > simple database. This hopefully will save someone else some head > > scratching when the query isn't returning as it should. > > > > Quoth Romano : > > > --- > > > diff 46cf9d4eb02a3a7c2516be3053994d4fb69eb949 0b5b2d58047b698564f6b1955a31cbcc95570abb > > > --- a/sys/man/8/ndb > > > +++ b/sys/man/8/ndb > > > @@ -924,3 +924,5 @@ > > > .I Ndb > > > databases are case-sensitive; > > > ethernet addresses must be in lower-case hexadecimal. > > > +.I Ndb > > > +database attributes are constrained to 32-byte attribute names and 64-byte attribute values. > > > > > >