Re: [Gluster-devel] !! operator

2016-04-02 Thread Emmanuel Dreyfus
Jeff Darcy  wrote:

> Sorry if my comment came off as dismissive.

It was not dissmissive. My reply was not ironic, I was gladly surprised
to learn something about C syntax.

>From an objective code-readability standpoint it's probably a bad
> idiom. 

IMO the root of the problem is the lack of a built-in boolean type in C,
but that is not big business.

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
m...@netbsd.org
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] !! operator

2016-04-02 Thread Jeff Darcy
> Thanks for the explanation. I was able to practice C for 18 years in
> numerous projects without having the opportunity to see it. I will got
> to bed less ignorant tonight. :-)

Sorry if my comment came off as dismissive.  I was only trying to
explain why I'd assume it's intentional.  I'll readily admit that
I had the exact same reaction when I first saw this construct.
>From an objective code-readability standpoint it's probably a bad
idiom.  While it is definitely concise, the syntax gives no hint
as to its intent, and it's often unnecessary.  This and the dozen
other instances of !! in our code should probably be eliminated
or replaced with a macro.  TO_BOOLEAN, perhaps?
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] !! operator

2016-04-02 Thread Emmanuel Dreyfus
Jeff Darcy  wrote:

> It's a common idiom in the Linux kernel/coreutils community.  I
> thought it was in BSD too.

Thanks for the explanation. I was able to practice C for 18 years in
numerous projects without having the opportunity to see it. I will got
to bed less ignorant tonight. :-)

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
m...@netbsd.org
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] !! operator

2016-04-02 Thread Jeff Darcy
> I found a !! in glusterfs sources. Is it a C syntax I do not know, a
> bug, or just a weird syntax?
> 
> xlators/cluster/afr/src/afr-inode-write.c:
>  local->stable_write = !!((fd->flags|flags)&(O_SYNC|O_DSYNC));

It's a common idiom in the Linux kernel/coreutils community.  I
thought it was in BSD too.  It's a convenient way to coerce any
arbitrary non-zero integer value into a specific value of one,
for code that uses integers as booleans.  I wouldn't assume it's
a bug, since that seems to be precisely what's called for in the
snippet you provided, but I guess that means it's weird syntax.
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] [Gluster-infra] freebsd-smoke failures

2016-04-02 Thread Jeff Darcy
> Please make sure that this change also gets included in the repository:
> 
>   https://github.com/gluster/glusterfs-patch-acceptance-tests

Looks like we're getting a bit of a queue there.  Who can merge some of
these?
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


[Gluster-devel] !! operator

2016-04-02 Thread Emmanuel Dreyfus
Hello 

I found a !! in glusterfs sources. Is it a C syntax I do not know, a
bug, or just a weird syntax?

xlators/cluster/afr/src/afr-inode-write.c: 
 local->stable_write = !!((fd->flags|flags)&(O_SYNC|O_DSYNC));


-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
m...@netbsd.org
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] [Gluster-infra] freebsd-smoke failures

2016-04-02 Thread Jeff Darcy


- Original Message -
> On Sat, Apr 02, 2016 at 07:53:32AM -0400, Jeff Darcy wrote:
> > > IIRC, this happens because in the build job use "--enable-bd-xlator"
> > > option while configure
> > 
> > I came to the same conclusion, and set --enable-bd-xlator=no on the
> > slave.  I also had to remove -Werror because that was also causing
> > failures.  FreeBSD smoke is now succeeding.
> 
> Please make sure that this change also gets included in the repository:
> 
>   https://github.com/gluster/glusterfs-patch-acceptance-tests
> 
> I always thought the bd-xlator was Linux only because it depends on LVM.
> Does anyone have an idea why this suddenly(?) got enabled on FreeBSD?

At first I thought it might have been because a Linux-specific version
got restored when the slave was rebooted a few days ago (something to
do with network changes at Rackspace IIRC).  The timing's right; that's
when the tests started failing consistently.  OTOH, that version also
has -Werror which has never worked on Linux AFAIK.  So it's still a bit
of a mystery.
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] "Tiering Performance Enhancements" is at risk for 3.8

2016-04-02 Thread Niels de Vos
On Fri, Apr 01, 2016 at 07:57:14AM -0400, Dan Lambright wrote:
> 
> 
> - Original Message -
> > From: "Niels de Vos" 
> > To: "Dan Lambright" , "Joseph Fernandes" 
> > 
> > Cc: gluster-devel@gluster.org
> > Sent: Friday, April 1, 2016 4:08:25 AM
> > Subject: "Tiering Performance Enhancements" is at risk for 3.8
> > 
> > Hi,
> > 
> > the feature labelled "Tiering Performance Enhancements" did not receive
> > any status updates by pull request to the 3.8 roadmap. We have now moved
> > this feature to the new "at risk" category on the page. If there is
> > still an intention to include this feature with 3.8, we encourage you
> > send an update for the roadmap soon. This can easily be done by clicking
> > the "edit this page" link on the bottom of the roadmap:
> > 
> >   https://www.gluster.org/community/roadmap/3.8/
> > 
> > If there is no update within a week, we'll move the feature to the next
> > release.
> 
> This is related to EC as a cold tier, we can rename the feature to clarify 
> that.
> 
> One fix from Pranith helps, I'll confirm with him it shall be in 3.8.
> 
> Another fix from me is waiting on results from Manoj.
> 
> Once I hear back, I'll update the page.

Ok, many thanks for the update!

Niels


> 
> > 
> > Thanks,
> > Jiffin and Niels
> > 


signature.asc
Description: PGP signature
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel

Re: [Gluster-devel] Reminder: adding source files

2016-04-02 Thread Niels de Vos
On Fri, Apr 01, 2016 at 11:46:00AM -0400, Jeff Darcy wrote:
> If you add a file to the project, please remember to add it to the
> appropriate Makefile.am as well.  Failure to do so *will not show up* in
> our standard smoke/regression tests because those do "make install" but
> they will prevent RPMs (and probably equivalents on other
> distros/platforms) from building.

Nightly builds in the CentOS CI will fail, and the maintainers list gets
notified. The Jenkins job did not report the actual problem that was
recently introduced, but that has changed now too. Some more details are
this email:

  http://article.gmane.org/gmane.comp.file-systems.gluster.maintainers/548

Cheers,
Niels


signature.asc
Description: PGP signature
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel

Re: [Gluster-devel] [Gluster-infra] freebsd-smoke failures

2016-04-02 Thread Niels de Vos
On Sat, Apr 02, 2016 at 07:53:32AM -0400, Jeff Darcy wrote:
> > IIRC, this happens because in the build job use "--enable-bd-xlator"
> > option while configure
> 
> I came to the same conclusion, and set --enable-bd-xlator=no on the
> slave.  I also had to remove -Werror because that was also causing
> failures.  FreeBSD smoke is now succeeding.

Please make sure that this change also gets included in the repository:

  https://github.com/gluster/glusterfs-patch-acceptance-tests

I always thought the bd-xlator was Linux only because it depends on LVM.
Does anyone have an idea why this suddenly(?) got enabled on FreeBSD?

Thanks,
Niels


signature.asc
Description: PGP signature
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel

Re: [Gluster-devel] [Gluster-infra] freebsd-smoke failures

2016-04-02 Thread Jeff Darcy
> IIRC, this happens because in the build job use "--enable-bd-xlator"
> option while configure

I came to the same conclusion, and set --enable-bd-xlator=no on the
slave.  I also had to remove -Werror because that was also causing
failures.  FreeBSD smoke is now succeeding.
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel


Re: [Gluster-devel] [Gluster-infra] freebsd-smoke failures

2016-04-02 Thread Prasanna Kalever
On Sat, Apr 2, 2016 at 2:13 AM, Jeff Darcy  wrote:
>
> I've seen a lot of patches blocked lately by this:
>
> > BD xlator requested but required lvm2 development library not found.
>
Hi Jeff,

IIRC, this happens because in the build job use "--enable-bd-xlator"
option while configure;
but looks like bd library dependencies were missing in this slave.

/me looking into configure.ac

[part of configure.ac]

if test "x$enable_bd_xlator" != "xno"; then
  AC_CHECK_LIB([lvm2app],
   [lvm_init,lvm_lv_from_name],
   [HAVE_BD_LIB="yes"],
   [HAVE_BD_LIB="no"])
[...]

if test "x$enable_bd_xlator" = "xyes" -a "x$HAVE_BD_LIB" = "xno"; then
   echo "BD xlator requested but required lvm2 development library not found."
   exit 1
fi

>From above I can say liblvm2app.so doesn't have
lvm_init/lvm_lv_from_name functions or
there is no liblvm2app.so in this slave, hence 'HAVE_BD_LIB' will be set to 'no'

IMO, no one really uses "BD-xlator" and I think we need to remove this
option In the build script while we configure.


Thanks,
-- Prasanna

> It doesn't happen all the time, so there must be something about
> certain patches that triggers it.  Any thoughts?
> ___
> Gluster-infra mailing list
> gluster-in...@gluster.org
> http://www.gluster.org/mailman/listinfo/gluster-infra
___
Gluster-devel mailing list
Gluster-devel@gluster.org
http://www.gluster.org/mailman/listinfo/gluster-devel