Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 01 Mar 2015 23:51:52 -0500
From:      Alfred Perlstein <bright@mu.org>
To:        Harrison Grundy <harrison.grundy@astrodoggroup.com>,  freebsd-current@freebsd.org
Subject:   Re: Massive libxo-zation that breaks everything
Message-ID:  <54F3EC68.3020405@mu.org>
In-Reply-To: <54F38B52.6090209@astrodoggroup.com>
References:  <54F31510.7050607@hot.ee> <54F34B6E.2040809@astrodoggroup.com> <CAG=rPVfcB1Fy_8mHq-t5Ay07yrzuSGthQ0ZcGzvp0XG9gSSzkg@mail.gmail.com> <54F35F29.4000603@astrodoggroup.com> <CAG=rPVdb-VFTErWMn0Jp8trGj8wLgsL9qj0rf-_60yTk2ojMgQ@mail.gmail.com> <54F38B52.6090209@astrodoggroup.com>

next in thread | previous in thread | raw e-mail | index | archive | help


On 3/1/15 4:57 PM, Harrison Grundy wrote:
> I like the idea behind this... where I'm running into difficulty is why
> these bits of functionality need to be combined. What someone does with
> ifconfig on the command line, versus what someone wants to know about
> their network interfaces in an XML dump may be very distinct bits of
> information. (For instance, an XML dump of network information may want
> to incorporate data from netstat, route, and ifconfig, while ifconfig is
> really only designed to deal with the interfaces themselves.)
Part of this is putting the burden of machine readable output into the 
utilities themselves.  Meaning that people have complained against libxo 
because "well you can get the same information by combining data points 
X, Y and Z from sysctl" whereas ifconfig just does that for you.  So if 
we split the code then those interfaces would wither and die from 
neglect because honestly very few core freebsd devs care about XML and JSON.

So in order to prevent bitotting and make this a "feature" of FreeBSD, 
we decided to put it into the base utils so that we would be sure to 
carry the burden and keep it working.

> I know it involves some notable reworking, but would there be any
> interest in seeing what "libifying" a handful of binaries and splitting
> the libxo and CLI functionality looks like? It seems like this may give
> FreeBSD the best of both worlds, so the XML output isn't logically
> limited by how the CLI needs to work, and the CLI won't have to deal
> with the complexity XML output can require.
>
> I'd be happy to get this set up for a few binaries so people can see how
> it might work and what it could look like if there's any interest in
> going that route.

Please do.  That would be great.  Please make sure they are thread safe. :)

-Alfred



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?54F3EC68.3020405>