Libxo bugs and fixes.

Alfred Perlstein bright at mu.org
Thu Dec 25 14:38:14 UTC 2014


> On Dec 24, 2014, at 11:32 PM, Simon J. Gerraty <sjg at juniper.net> wrote:
> 
> Alfred Perlstein <alfred at freebsd.org> wrote:
>> 1) We need libxo to support explicit fflush:
>> https://reviews.freebsd.org/D1379
> 
> This is probably sub-optimal.  
> Supporting flushing isn't the same thing as blindly doing it.
> Probably better if caller can indicate a need for flushing regularly.
> Will try and catch up with Phil to discuss.

Yes, the patch leaves it to the caller. The otherwise when you run "netstat --libxo json 1" you only see output every BUFSIZE bytes from netstat. 

With the fix I added the xo_flush calls actually work. Which I think is what you want as well. 


> 
>> 2) We need libxo to support time series data.  I don't have a patch
>> for that, but I would like to ask for ideas on this.  This would be
>> extremely helpful for instance "netstat 1".  would like to get a very
>> accurate timestamp with each row.  Suggestions on how to do this
>> correctly AND *consistently* via libxo would make sense.
>> 
>> 3) I have netstat mostly converted over, however not all the json is
>> valid, I will be doing another pass ASAP on this.
>> https://reviews.freebsd.org/D1380
>> 
>> 4) Can I as politely as I know how, ask that Juniper keep the patches
>> against the userland utils up to date either in a project branch in
>> SVN, or simply in a fork of the github repo?  This would make life so
>> much easer to deal with.
> 
> I assume that commits would be more use?

Yes!

Also we should really have unit tests made to make sure the json is valid. I've found some bugs and I am fixing them, but it will take some time and I want to avoid regressions. 



> _______________________________________________
> freebsd-arch at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-arch
> To unsubscribe, send any mail to "freebsd-arch-unsubscribe at freebsd.org"
> 


More information about the freebsd-arch mailing list