<div dir="ltr"><div>That sounds good to me. I will send it as a separate patch then. And I can <br></div><div>maintain it. No issues.<br></div><div><br></div><div>Thanks and Regards,<br></div><div>Kotresh H R<br></div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 28, 2017 at 1:02 PM, Niels de Vos <span dir="ltr">&lt;<a href="mailto:ndevos@redhat.com" target="_blank">ndevos@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Wed, Jun 28, 2017 at 12:51:07PM +0530, Amar Tumballi wrote:<br>
&gt; On Tue, Jun 27, 2017 at 8:46 PM, Niels de Vos &lt;<a href="mailto:ndevos@redhat.com">ndevos@redhat.com</a>&gt; wrote:<br>
&gt;<br>
&gt; &gt; On Tue, Jun 27, 2017 at 08:09:25AM -0400, Kaleb S. KEITHLEY wrote:<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; xxhash doesn&#39;t seem to change much. Last update to the non-test code was<br>
&gt; &gt; six<br>
&gt; &gt; &gt; months ago.<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; bundling giant (for some definition of giant) packages/projects would be<br>
&gt; &gt; &gt; bad. bundling two (three if you count the test) C files doesn&#39;t seem too<br>
&gt; &gt; bad<br>
&gt; &gt; &gt; when you consider that there are already three or four packages in fedora<br>
&gt; &gt; &gt; (perl, python, R-digest, ghc (gnu haskell) that have implementations of<br>
&gt; &gt; &gt; xxhash or murmur but didn&#39;t bother to package a C implementation and use<br>
&gt; &gt; it.<br>
&gt; &gt;<br>
&gt; &gt; I prefer to have as little maintenance components in the Gluster sources<br>
&gt; &gt; as we can. The maintenance burdon is already very high. The number of<br>
&gt; &gt; changes to xxhash seem limited, but we still need someone to track and<br>
&gt; &gt; pay attention to them.<br>
&gt; &gt;<br>
&gt;<br>
&gt; I agree that someone should maintain it, and we should add it to<br>
&gt; MAINTAINERS file<br>
&gt; (or some other place, where we are tracking the dependencies).<br>
&gt;<br>
&gt; For now, Kotresh will be looking into keeping these changes up-to-date with<br>
&gt; upstream xxhash project, along with me.<br>
<br>
</span>Kotresh as maintainer/owner, and Aravinda as peer?<br>
<span class=""><br>
&gt; &gt; &gt; I&#39;d be for packaging it in Fedora rather than bundling it in gluster. But<br>
&gt; &gt; &gt; then we get to &quot;carry&quot; it in rhgs as we do with userspace-rcu.<br>
&gt; &gt;<br>
&gt; &gt; We should descide what the most maintainable solution is. Having package<br>
&gt; &gt; maintainers with the explicit task to keep xxhash updated and current is<br>
&gt; &gt; apealing to me. Merging (even small) projects into the Gluster codebase<br>
&gt; &gt; will add more maintenance need to the project members. Therefor I have a<br>
&gt; &gt; strong preference to use xxhash (or an other library) that is provided<br>
&gt; &gt; by distributions. The more common the library is, the better it will be<br>
&gt; &gt; maintained without our (Gluster Community&#39;s) help.<br>
&gt; &gt;<br>
&gt; &gt;<br>
&gt; While this is desirable, we didn&#39;t see any library available for xxhash (<br>
&gt; <a href="http://cyan4973.github.io/xxHash/" rel="noreferrer" target="_blank">http://cyan4973.github.io/<wbr>xxHash/</a>) in our distro.<br>
&gt;<br>
&gt; I would recommend taking these patches with TODO to use library in future<br>
&gt; when its available, and continue to have xxhash in &#39;contrib/&#39;. It is not<br>
&gt; new for us to take code from different libraries and use it for our need<br>
&gt; and maintain only that part (eg. libfuse). Lets treat this as similar setup.<br>
<br>
</span>Yes, if there is no suitable alternative available in the majority of<br>
distributions, this is the only sensible approach. Much of the code in<br>
contrib/ is not maintained at all. We should prevent this from happening<br>
with new code and assigning an owner/maintainer and peer(s) just like<br>
for other components is a must.<br>
<br>
Thanks,<br>
Niels<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
&gt;<br>
&gt; Regards,<br>
&gt; Amar<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; &gt; Niels<br>
&gt; &gt;<br>
&gt; &gt;<br>
&gt; &gt; &gt; On 06/27/2017 04:08 AM, Niels de Vos wrote:<br>
&gt; &gt; &gt; &gt; On Tue, Jun 27, 2017 at 12:25:11PM +0530, Kotresh Hiremath Ravishankar<br>
&gt; &gt; wrote:<br>
&gt; &gt; &gt; &gt; &gt; Hi,<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; We were looking for faster non-cryptographic hash to be used for the<br>
&gt; &gt; &gt; &gt; &gt; gfid2path infra [1]<br>
&gt; &gt; &gt; &gt; &gt; The initial testing was done with md5 128bit checksum which was a<br>
&gt; &gt; slow,<br>
&gt; &gt; &gt; &gt; &gt; cryptographic hash<br>
&gt; &gt; &gt; &gt; &gt; and using it makes software not complaint to FIPS [2]<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; On searching online a bit we found out xxhash [3] seems to be faster<br>
&gt; &gt; from<br>
&gt; &gt; &gt; &gt; &gt; the results of<br>
&gt; &gt; &gt; &gt; &gt; benchmark tests shared and lot of projects use it. So we have<br>
&gt; &gt; decided to us<br>
&gt; &gt; &gt; &gt; &gt; xxHash<br>
&gt; &gt; &gt; &gt; &gt; and added following files to gluster code base with the patch [4]<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt;      BSD 2-Clause License:<br>
&gt; &gt; &gt; &gt; &gt;         contrib/xxhash/xxhash.c<br>
&gt; &gt; &gt; &gt; &gt;         contrib/xxhash/xxhash.h<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt;      GPL v2 License:<br>
&gt; &gt; &gt; &gt; &gt;         tests/utils/xxhsum.c<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; NOTE: We have ignored the code guideline check for these files as<br>
&gt; &gt; &gt; &gt; &gt; maintaining it<br>
&gt; &gt; &gt; &gt; &gt; further becomes difficult.<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; Please comment on the same if there are any issues around it.<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; How performance critical is the hashing for gfid2path?<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; What is the plan to keep these files maintained? At minimal we need to<br>
&gt; &gt; &gt; &gt; add these files to MAINTAINERS and the maintainers need to cherry-pick<br>
&gt; &gt; &gt; &gt; updates and bugfixes from the original project. The few patches a year<br>
&gt; &gt; &gt; &gt; makes this a recurring task that should not be forgoten. It would be<br>
&gt; &gt; &gt; &gt; much better to use this as an external library that is provided by the<br>
&gt; &gt; &gt; &gt; distributions. We already rely on OpenSSL, does this library not<br>
&gt; &gt; provide<br>
&gt; &gt; &gt; &gt; an alternative &#39;FIPS approved&#39; hashing that performs reasonably well?<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; Some distributions are very strict on bundling external projects, and<br>
&gt; &gt; we<br>
&gt; &gt; &gt; &gt; need to inform the packagers about the additions so that they can<br>
&gt; &gt; handle<br>
&gt; &gt; &gt; &gt; it correctly. Adding an external project to contrib/ should be<br>
&gt; &gt; mentioned<br>
&gt; &gt; &gt; &gt; in the release notes at the very least.<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; Note that none of the symbols of any public functions in Gluster may<br>
&gt; &gt; &gt; &gt; collide with functions in standard distribution libraries. This causes<br>
&gt; &gt; &gt; &gt; for regular problems with gfapi applications. All exposed symbols that<br>
&gt; &gt; &gt; &gt; get imported in contrib/ should have a gf_ prefix.<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; Thanks,<br>
&gt; &gt; &gt; &gt; Niels<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; [1] Issue: <a href="https://github.com/gluster/glusterfs/issues/139" rel="noreferrer" target="_blank">https://github.com/gluster/<wbr>glusterfs/issues/139</a><br>
&gt; &gt; &gt; &gt; &gt; [2] <a href="https://en.wikipedia.org/wiki/Federal_Information_" rel="noreferrer" target="_blank">https://en.wikipedia.org/wiki/<wbr>Federal_Information_</a><br>
&gt; &gt; Processing_Standards<br>
&gt; &gt; &gt; &gt; &gt; [3] <a href="http://cyan4973.github.io/xxHash/" rel="noreferrer" target="_blank">http://cyan4973.github.io/<wbr>xxHash/</a><br>
&gt; &gt; &gt; &gt; &gt; [4] <a href="https://review.gluster.org/#/c/17488/10" rel="noreferrer" target="_blank">https://review.gluster.org/#/<wbr>c/17488/10</a><br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt;<br>
&gt; &gt; &gt; &gt; &gt; --<br>
&gt; &gt; &gt; &gt; &gt; Thanks and Regards,<br>
&gt; &gt; &gt; &gt; &gt; Kotresh H R and Aravinda VK<br>
&gt; &gt; &gt;<br>
&gt; &gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; --<br>
&gt; Amar Tumballi (amarts)<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Thanks and Regards,<br></div>Kotresh H R<br></div></div>
</div>