pcp
[Top] [All Lists]

Re: [pcp] PATCH: - Implement time-out for connect() in http_fetcher

To: Nathan Scott <nathans@xxxxxxxxxx>
Subject: Re: [pcp] PATCH: - Implement time-out for connect() in http_fetcher
From: Ryan Doyle <rdoyle@xxxxxxxxxx>
Date: Mon, 15 Apr 2013 09:43:06 +1000 (EST)
Cc: pcp@xxxxxxxxxxx
Delivered-to: pcp@xxxxxxxxxxx
In-reply-to: <82929559.282056.1365982413903.JavaMail.root@xxxxxxxxxx>
Hey Nathan

At the time I didn't intend on merging the commits upstream and was going to send you just the diff. In future I'll be using that branch so I'll keep the commits meaningful : )

Cheers!


----
Ryan Doyle


From: "Nathan Scott" <nathans@xxxxxxxxxx>
To: "Ryan Doyle" <rdoyle@xxxxxxxxxx>
Cc: pcp@xxxxxxxxxxx
Sent: Monday, 15 April, 2013 9:33:33 AM
Subject: Re: [pcp] PATCH: - Implement time-out for connect() in http_fetcher

Hi Ryan,

----- Original Message -----
> Updated patch to remove code duplication.
>
> ---
>
> A timeout setting exists in src/libpcp_http/src/http_fetcher.c. This is a
> library that the Apache PMDA uses to read the server status page (the source
> of the apache metrics).
>
> I noticed that this library doesn't honour the timeout value when
> connect()'ing to a HTTP server. The patch implements a timeout for connect()
> via select().
>
> See patch provided, otherwise it is in the branch "ryan" at
> git://github.com/ryandoyle/pcp.git.

I've merged from there, its always easier to do a git pull.  For your
next update could you spend some extra time on the commit messages
though?

Your email above would have been a good start (gives further context,
and so the casual reader of a "git log" would know the commit relates
to pmdaapache) - you've got commits in there that are a little on the
terse side, e.g.

commit e713372458f6047e1641eb7e3e098bd706343500
Author: Ryan Doyle <rdoyle@xxxxxxxxxx>
Date:   Tue Apr 9 15:38:43 2013 +1000

    Syntax


Mhmm.  :)

Also, doing an --interactive git-rebase might suit your workflow - ie.
you could squash multiple smaller commits before pushing to github and
sending the pull mail.

Thanks though, that fix looks good to me!

cheers.

--
Nathan

<Prev in Thread] Current Thread [Next in Thread>