<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/libglusterfs/src/dict.c, branch v6.0</title>
<subtitle></subtitle>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/'/>
<entry>
<title>core: move "dict is NULL" logs to DEBUG log level</title>
<updated>2019-02-01T03:28:50+00:00</updated>
<author>
<name>Milind Changire</name>
<email>mchangir@redhat.com</email>
</author>
<published>2019-01-31T06:00:27+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=62a61c548d85d8c894907d7c43ef66c009a4757d'/>
<id>62a61c548d85d8c894907d7c43ef66c009a4757d</id>
<content type='text'>
Too many logs get printed if dict_ref() and dict_unref() are passed NULL
pointer.

fixes: bz#1671213
Change-Id: I18afd849d64318f68baa7b549ee310dac0e1e786
Signed-off-by: Milind Changire &lt;mchangir@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Too many logs get printed if dict_ref() and dict_unref() are passed NULL
pointer.

fixes: bz#1671213
Change-Id: I18afd849d64318f68baa7b549ee310dac0e1e786
Signed-off-by: Milind Changire &lt;mchangir@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>core: move logs which are only developer relevant to DEBUG level</title>
<updated>2019-01-23T16:05:52+00:00</updated>
<author>
<name>Amar Tumballi</name>
<email>amarts@redhat.com</email>
</author>
<published>2019-01-16T14:54:06+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=990d6a99d41111ea18481db55566a96c2fc4dad4'/>
<id>990d6a99d41111ea18481db55566a96c2fc4dad4</id>
<content type='text'>
We had only changed the log level to DEBUG in release branch earlier.
But considering 90%+ of our deployments happen in same env, we can look
at these specific logs on need basis. With this change, the master
branch will be easier to debug with lesser logs.

Change-Id: I4157a7ec7d5ec9c2948b2bbc1e4cb8317f28d6b8
Updates: bz#1666833
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We had only changed the log level to DEBUG in release branch earlier.
But considering 90%+ of our deployments happen in same env, we can look
at these specific logs on need basis. With this change, the master
branch will be easier to debug with lesser logs.

Change-Id: I4157a7ec7d5ec9c2948b2bbc1e4cb8317f28d6b8
Updates: bz#1666833
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>core: Resolve dict_leak at the time of destroying graph</title>
<updated>2019-01-14T04:01:54+00:00</updated>
<author>
<name>Mohit Agrawal</name>
<email>moagrawal@redhat.com</email>
</author>
<published>2018-11-30T10:37:39+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=211521f039bb5c883ef444577b5962bad9e18be1'/>
<id>211521f039bb5c883ef444577b5962bad9e18be1</id>
<content type='text'>
Problem: In gluster code some of the places it call's get_new_dict
         to create a dictionary without taking reference so at the time
         of dict_unref it has become a leak

Solution: To resolve the same call dict_new instead of get_new_dict

updates bz#1650403
Change-Id: I3ccbbf5af07079a4fa09aad2cd0458c8625b2f06
Signed-off-by: Mohit Agrawal &lt;moagrawal@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem: In gluster code some of the places it call's get_new_dict
         to create a dictionary without taking reference so at the time
         of dict_unref it has become a leak

Solution: To resolve the same call dict_new instead of get_new_dict

updates bz#1650403
Change-Id: I3ccbbf5af07079a4fa09aad2cd0458c8625b2f06
Signed-off-by: Mohit Agrawal &lt;moagrawal@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libglusterfs: Move devel headers under glusterfs directory</title>
<updated>2018-12-05T21:47:04+00:00</updated>
<author>
<name>ShyamsundarR</name>
<email>srangana@redhat.com</email>
</author>
<published>2018-11-29T19:08:06+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=20ef211cfa5b5fcc437484a879fdc5d4c66bbaf5'/>
<id>20ef211cfa5b5fcc437484a879fdc5d4c66bbaf5</id>
<content type='text'>
libglusterfs devel package headers are referenced in code using
include semantics for a program, this while it works can be better
especially when dealing with out of tree xlator builds or in
general out of tree devel package usage.

Towards this, the following changes are done,
- moved all devel headers under a glusterfs directory
- Included these headers using system header notation &lt;&gt; in all
code outside of libglusterfs
- Included these headers using own program notation "" within
libglusterfs

This change although big, is just moving around the headers and
making it correct when including these headers from other sources.

This helps us correctly include libglusterfs includes without
namespace conflicts.

Change-Id: Id2a98854e671a7ee5d73be44da5ba1a74252423b
Updates: bz#1193929
Signed-off-by: ShyamsundarR &lt;srangana@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
libglusterfs devel package headers are referenced in code using
include semantics for a program, this while it works can be better
especially when dealing with out of tree xlator builds or in
general out of tree devel package usage.

Towards this, the following changes are done,
- moved all devel headers under a glusterfs directory
- Included these headers using system header notation &lt;&gt; in all
code outside of libglusterfs
- Included these headers using own program notation "" within
libglusterfs

This change although big, is just moving around the headers and
making it correct when including these headers from other sources.

This helps us correctly include libglusterfs includes without
namespace conflicts.

Change-Id: Id2a98854e671a7ee5d73be44da5ba1a74252423b
Updates: bz#1193929
Signed-off-by: ShyamsundarR &lt;srangana@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libglusterfs/src/dict.c : consistent initialization of parameters.</title>
<updated>2018-11-27T05:30:02+00:00</updated>
<author>
<name>Yaniv Kaul</name>
<email>ykaul@redhat.com</email>
</author>
<published>2018-11-25T10:04:50+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=01f3358501672e7c0fa8ae1f749f060af29bcd69'/>
<id>01f3358501672e7c0fa8ae1f749f060af29bcd69</id>
<content type='text'>
Some were assigned NULL, for no good reason, some were assigned proper
initial value. Made them all consistent, as much as possible, to be
assigned reasonable initial values.
No expected functional changes (and I also assume the compiler
already did most of this work behind the scenes anyway, so no
performance implications either).

Compile-tested only!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: I2bc0d4f2221124b5f9ef6150c86b7259074e7013
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some were assigned NULL, for no good reason, some were assigned proper
initial value. Made them all consistent, as much as possible, to be
assigned reasonable initial values.
No expected functional changes (and I also assume the compiler
already did most of this work behind the scenes anyway, so no
performance implications either).

Compile-tested only!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: I2bc0d4f2221124b5f9ef6150c86b7259074e7013
</pre>
</div>
</content>
</entry>
<entry>
<title>libglusterfs/src/dict.c : use xxhash64 for hashing.</title>
<updated>2018-09-17T03:32:23+00:00</updated>
<author>
<name>Yaniv Kaul</name>
<email>ykaul@redhat.com</email>
</author>
<published>2018-09-11T08:42:19+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=956b4ad214b46b1a1c89e5c120754081561aa930'/>
<id>956b4ad214b46b1a1c89e5c120754081561aa930</id>
<content type='text'>
As part of a larger effort to consolidate hash functions
and use a faster, with less collissions, I've moved to use
xxhash as the hashing function for the dictionary.

Note: I'm using only 32 bits of the hashes, as the hash field
is currently a 32 bit variable. There's room (since the struct
is not packed) to move to use a 64bit variable. Donno how it'll
affect performance.

Only compile-tested!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: Ie244efd1368234e54dd5957ee1ae5bebd7d9409a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As part of a larger effort to consolidate hash functions
and use a faster, with less collissions, I've moved to use
xxhash as the hashing function for the dictionary.

Note: I'm using only 32 bits of the hashes, as the hash field
is currently a 32 bit variable. There's room (since the struct
is not packed) to move to use a 64bit variable. Donno how it'll
affect performance.

Only compile-tested!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: Ie244efd1368234e54dd5957ee1ae5bebd7d9409a
</pre>
</div>
</content>
</entry>
<entry>
<title>Land part 2 of clang-format changes</title>
<updated>2018-09-12T12:22:45+00:00</updated>
<author>
<name>Gluster Ant</name>
<email>bugzilla-bot@gluster.org</email>
</author>
<published>2018-09-12T12:22:45+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=e16868dede6455cab644805af6fe1ac312775e13'/>
<id>e16868dede6455cab644805af6fe1ac312775e13</id>
<content type='text'>
Change-Id: Ia84cc24c8924e6d22d02ac15f611c10e26db99b4
Signed-off-by: Nigel Babu &lt;nigelb@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: Ia84cc24c8924e6d22d02ac15f611c10e26db99b4
Signed-off-by: Nigel Babu &lt;nigelb@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Some (mgmt) xlators: use dict_{setn|getn|deln|get_int32n|set_int32n|set_strn}</title>
<updated>2018-09-09T01:53:59+00:00</updated>
<author>
<name>Yaniv Kaul</name>
<email>ykaul@redhat.com</email>
</author>
<published>2018-09-03T10:55:01+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=09198e203ece6925791a8a3a6121c5f808e4e873'/>
<id>09198e203ece6925791a8a3a6121c5f808e4e873</id>
<content type='text'>
In a previous patch (https://review.gluster.org/20769) we've
added the key length to be passed to dict_* funcs, to remove the need
to strlen() it. This patch moves some xlators to use it.

- It also adds dict_get_int32n which was missing.
- It also reduces the size of some key variables.
They were set to 1024b or PATH_MAX, where sometimes 64 bytes were
really enough.

Please review carefully:
1. That I did not reduce some the size of the key variables too much.
2. That I did not mix up some keys.

Compile-tested only!

Change-Id: Ic729baf179f40e8d02bc2350491d4bb9b6934266
updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In a previous patch (https://review.gluster.org/20769) we've
added the key length to be passed to dict_* funcs, to remove the need
to strlen() it. This patch moves some xlators to use it.

- It also adds dict_get_int32n which was missing.
- It also reduces the size of some key variables.
They were set to 1024b or PATH_MAX, where sometimes 64 bytes were
really enough.

Please review carefully:
1. That I did not reduce some the size of the key variables too much.
2. That I did not mix up some keys.

Compile-tested only!

Change-Id: Ic729baf179f40e8d02bc2350491d4bb9b6934266
updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libglusterfs/src/dict.c: remove memcpy(), gf_asprintf -&gt; asprintf</title>
<updated>2018-09-06T06:49:44+00:00</updated>
<author>
<name>Yaniv Kaul</name>
<email>ykaul@redhat.com</email>
</author>
<published>2018-08-30T07:54:54+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=bc6b6f6a168804f22bbb44081f89e938fbfcec60'/>
<id>bc6b6f6a168804f22bbb44081f89e938fbfcec60</id>
<content type='text'>
1. We don't need a temp. string to strotol(), we can use data-&gt;data.
2. We don't need the gf_asprintf, when a regular asprintf would do.
3. No need to CALLOC the data, can MALLOC, since
we are going to populate most of the fields anyway.
4. Removed is_const member - it was not used.
5. Turned is_static to a gf_boolean_t
6. Turned another get_mem0 to get_mem (in dict_set_lk() func)
7. Remove dict_set_ptr - was exactly the same as dict_set_static_ptr
 (apart from the 'static' bit) and no one was using it.
8. Removed is_static from the dictionary object. Did not seem to be
very useful.

Compile-tested only!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: I7b1f6320867b154be4a94033819407f7e51cf38c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
1. We don't need a temp. string to strotol(), we can use data-&gt;data.
2. We don't need the gf_asprintf, when a regular asprintf would do.
3. No need to CALLOC the data, can MALLOC, since
we are going to populate most of the fields anyway.
4. Removed is_const member - it was not used.
5. Turned is_static to a gf_boolean_t
6. Turned another get_mem0 to get_mem (in dict_set_lk() func)
7. Remove dict_set_ptr - was exactly the same as dict_set_static_ptr
 (apart from the 'static' bit) and no one was using it.
8. Removed is_static from the dictionary object. Did not seem to be
very useful.

Compile-tested only!

updates: bz#1193929
Signed-off-by: Yaniv Kaul &lt;ykaul@redhat.com&gt;

Change-Id: I7b1f6320867b154be4a94033819407f7e51cf38c
</pre>
</div>
</content>
</entry>
<entry>
<title>dict: handle negative key/value length while unserialize</title>
<updated>2018-09-05T09:23:10+00:00</updated>
<author>
<name>Amar Tumballi</name>
<email>amarts@redhat.com</email>
</author>
<published>2018-07-24T07:55:12+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=cc3271ebf3aacdbbc77fdd527375af78ab12ea8d'/>
<id>cc3271ebf3aacdbbc77fdd527375af78ab12ea8d</id>
<content type='text'>
Fixes: bz#1625089
Change-Id: Ie56df0da46c242846a1ba51ccb9e011af118b119
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes: bz#1625089
Change-Id: Ie56df0da46c242846a1ba51ccb9e011af118b119
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
