CC'ing the list:

On 04/07/2010 07:13 AM, Willy Tarreau wrote:
> That's very nice. It is possible that your tool could become the default
> CLI interface in the end if it's lightweight and portable. At one moment
> I wondered if I should embed a CLI in the haproxy binary using readline
> or ncurses and use it as a client to connect to the previous process.

I'm glad to hear that. HATop has no external dependencies except for
Python itself, which comes with the socket and curses APIs. It should
run everywhere where Python is available. (I wrote it for the current
Python 2.6, however it runs fine with 2.5 and it should be quite easy to
make it work with others)

To keep it lightweight and easy to distribute, it's written as one
single python executable: https://labs.feurix.org/admin/hatop/tree/hatop

It's interesting to hear that you've thought about integrating this
directly into the haproxy binary. I had that exact same thought and
mentally prepared myself to contribute a patch... when I suddenly found
the stat socket and it's interactive mode. In the end, I think an
external app connecting to the haproxy socket is the better solution:

 - keep haproxy as small and stable as possible
 - there are tools to tunnel the socket connection

I've also thought about an additional tcp mode, but IMHO ssh is more
than sufficient, plus much more secure and convenient (pubkeys):

  $ ssh -t haproxy-host hatop -s /tmp/haproxy.sock

After all, the CLI is my prefered way to manage haproxy (and probably
other's too) and working with plain socat is painful :-)

> OK, so here are two different samples from two distinct machines. I'm
> hoping this helps.
> 
> Also, if you find that some fields are missing from the output and
> could help your tool, please suggest, I'm open to discussions.

Thanks! I've received samples from 4 people so far, this will help me a
lot designing the screen layout.

I didn't read the pre-haproxy-1.4 CSV format documentation yet. I want
to support 1.3 too at least, so it's possible that I'm missing something
there. (interactive socket mode, some status fields, ...)

Regards,
John


Reply via email to