Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
Closed #269. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#event-1800023513___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
Meanwhile this patch adds a --queryformat modifier to generate UUID's from tag values, which is an entirely orthogonal and mostly non-intrusive usage case than converting hdrNum/tagNum to an octet string. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#issuecomment-323139109___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
Changing indices to be octets (rather than integers) is a prerequisite to using UUID's as a join key. There are many problems (endianness, exposure of hdrNum/tagNum in the RPM API) that need to be solved to use a UUID as an octet string for LMDB (and for BDB). See other issues for work-in-progress. Ideally, a UUIDv1 (which has time ordered properties) should be used as the retrieval key throughout all RPM backend databases. One of the immediately obvious and useful side effects is that "rpm -qa" will present results in install order by default, which is more deterministic (and less confusing imho) than random hash bucket iteration returns. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#issuecomment-323138470___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
>From @n3npq: > UUID's will be the starting point for a RPM+LMDB implementation used as > header retrieval keys. It didn't seem like you used this with the LMDB implementation (ed9de1992f5e1c23e8d8dbd61325a1e0070f2c72), though you mention it as a starting point. I'm guessing you're not currently using it? Or did I miss something? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#issuecomment-323047808___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
The rpm_uuid.patch is now applied to an RPM tree at [https://github.com/rpm5/rpm/commit/c8c72fb195790dfa2d40c20ca597d9cc2b75](url) -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#issuecomment-320530188___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
[rpm_uuid.patch.gz](https://github.com/rpm-software-management/rpm/files/1163437/rpm_uuid.patch.gz) -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269#issuecomment-316801741___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
[Rpm-maint] [rpm-software-management/rpm] Adding header tag formats to generate UUIDS (#269)
UUID's provide a common format for identification and database retrieval. The attached patch adds a header tag format to RPM queries. - UUIDv1 time stamps (for events like build/install times): ``` $ ./rpm -q --qf '%{buildtime:uuidv1}\n' bash c60fd500-bc0a-11e7-804e-003048b801de ``` - UUIDv3 namespace identifiers based on MD5 (like package/header digests) ``` $ ./rpm -q --qf '%{sigmd5:uuidv3}\n' bash c24fd63e-14c4-32d1-84f5-168a1f2908db ``` - UUIDv4 random nonces (overkill because random, but added for completeness) ``` $ ./rpm -q --qf '%{sigmd5:uuidv4}\n' bash b7a15d96-c4cd-4e41-8598-6463375cb39f ``` - UUIDv5 namespace identifiers based on SHA1 (like package/header digests) ``` $ ./rpm -q --qf '%{sigmd5:uuidv5}\n' bash 9292a557-f445-5f36-9b79-8e79a6efaaa2 ``` The UUIDv3/UUIDv5 name spaces can be configured through optional macros (defaults below) ``` %_uuid_authhttp://rpm.org %_uuid_path/packages ``` For reference, the actual text used for, say, Sha1header, in a namespace UUID looks like ``` http://rpm.org/packages/Sha1header/ ``` Essentially a prefix (to make the namespace unique) of %_uuid_auth and %_uuid_path followed by a tag name and a tag value. UUID's will be the starting point for a RPM+LMDB implementation used as header retrieval keys. You will need the acinclude.m4 file from issue #257 to use the patch below. Adding the hires timestamps from issue #197 would improve the UUIDv1 granularity (not implemented). -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/269___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint