Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 3 Mar 2015 09:32:23 -0800
From:      hiren panchasara <hiren@strugglingcoder.info>
To:        Alfred Perlstein <bright@mu.org>
Cc:        Harrison Grundy <harrison.grundy@astrodoggroup.com>, "freebsd-current@freebsd.org" <freebsd-current@freebsd.org>
Subject:   Re: Massive libxo-zation that breaks everything
Message-ID:  <20150303173223.GQ95752@strugglingcoder.info>
In-Reply-To: <E187B006-72D8-40CB-A5F0-439B1D02E037@mu.org>
References:  <54F34B6E.2040809@astrodoggroup.com> <CAG=rPVfcB1Fy_8mHq-t5Ay07yrzuSGthQ0ZcGzvp0XG9gSSzkg@mail.gmail.com> <54F35F29.4000603@astrodoggroup.com> <54F429EF.5050400@freebsd.org> <54F46536.8040607@mu.org> <54F4C03F.7030704@freebsd.org> <54F4FECB.90501@freebsd.org> <197AA5DC-0591-4F71-BF10-51A5D8104C11@mu.org> <54F5270D.1010009@freebsd.org> <E187B006-72D8-40CB-A5F0-439B1D02E037@mu.org>

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

--V2tfspbppmK1TQo2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On 03/02/15 at 07:33P, Alfred Perlstein wrote:
>=20
>=20
> > On Mar 2, 2015, at 7:14 PM, Julian Elischer <julian@freebsd.org> wrote:
> >=20
> >> On 3/2/15 5:30 PM, Alfred Perlstein wrote:
> >>=20
> >>>> On Mar 2, 2015, at 4:22 PM, Andrey Chernov <ache@freebsd.org> wrote:
> >>>>=20
> >>>>> On 02.03.2015 22:55, Julian Elischer wrote:
> >>>>> On 3/2/15 5:27 AM, Alfred Perlstein wrote:
> >>>>>=20
> >>>>>=20
> >>>>>>> On 3/2/15 4:14 AM, Julian Elischer wrote:
> >>>>>>> On 3/1/15 10:49 AM, Harrison Grundy wrote:
> >>>>>>> Thanks!
> >>>>>>>=20
> >>>>>>> That does seem useful, but I'm not sure I see the reasoning behind
> >>>>>>> putting into base, over a port or package, since processing XML i=
n base
> >>>>>>> is a pain, and it can't serve up JSON or HTML without additional
> >>>>>>> utilities anyway.
> >>>>>>>=20
> >>>>>>> (If I'm reviving a long-settled thing, let me know and I'll drop =
it.
> >>>>>>> I'm
> >>>>>>> trying to understand the use case for this.)
> >>>>>> To me it would almost seem more useful to have a programmable filt=
er
> >>>>>> for which you could produce
> >>>>>> parse grammars to parse the output of various programs..
> >>>>>> thus
> >>>>>>=20
> >>>>>> ifconfig -a | xmlize -g ifconfig | your-favourite-xml-parser
> >>>>>> with a set of grammars in /usr/share/xmlize/
> >>>>>> then we could use it for out-of-tree programs as well if we wrote
> >>>>>> grammars for them..
> >>>>>>=20
> >>>>>> The sentiment of machine-readable output is nice, but I think it's
> >>>>>> slightly off target.
> >>>>>> we shouldn't have to change all out utilities, and it isn't going =
to
> >>>>>> help at all with 3rd party apps,
> >>>>>> e.g. samba stuff. A generally easy to program output grammar parser
> >>>>>> would be truely useful.
> >>>>>> and not just for FreeBSD.
> >>>>>>=20
> >>>>>> I've been watching with an uncomfortable feeling, but it's taken m=
e a
> >>>>>> while to put my
> >>>>>> finger on what it was..
> >>>>> Are you sure it's not the hairs on the back of your neck standing up
> >>>>> due to NIH?
> >>>>>=20
> >>>>> Juniper has been doing this for years and it's very useful for them.
> >>>> I'm not saying the ability to generate machine readable output is wr=
ong,
> >>>> but that the 'unix way' would be to make a filter for it. It seems t=
hat
> >>>> the noisy people don't
> >>>> agree with me so I will not stand in the way of progress..
> >>> I agree. Even if someone starts with json and xml only, it will need
> >>> some 3rd format soon, and adding any new format have real possibility=
 to
> >>> break all already existent (like adding json+xml breaks plain text in
> >>> pipes). Moreover, it violates Unix principle 'one tool =3D=3D one gen=
eral
> >>> function' and lots of other rules like Eric Raymond ones, making each
> >>> program looks like systemd. It makes harder to merge changes from oth=
er
> >>> BSDs too.
> >>> Proper way to do this thing is to back out all changes and write
> >>> completely separate templates-based parser - xml/json writer.
> >>=20
> >> Read the library. It doesn't care what output format it needs. It is u=
p to the translation layer to do it. You could even do a csv format or most=
 any other structured output format without changing the userland utils.
> > As far as I can see that's not an argument either way.
> > I just think it makes more sense to spend more time writing one generic=
 converter and grammar files than to mess up the insides of every utility i=
n the system. If we had a tool, we could have grammar templates for 3rd par=
ty tools easily.. do YOU want to make libxo changes to 3rd party ports? of =
course not. so you are going off here solving a half of the problem.
>=20
> Actually I want to shame third party ports into adopting libxo (or at lea=
st providing machine readable output).=20
>=20
> I know it's scary to try to lead the pack, after all we could be wrong, b=
ut maybe it's time to try something new and see what happens.=20
>=20
> And no, your idea doesn't make sense it just will lead to those files bit=
 rotting. =20
>=20
> Bedsides that you don't even have a real spec other than "it should be do=
ne differently".=20
>=20
> Again, show the code.=20

Wow. He told you want he didn't like and he moved on. I hope/wish we as
a project can take criticism more positively than this.

Answer to every criticism should not be "show me your code". We (should)
know better than that.

Hiren


--V2tfspbppmK1TQo2
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (FreeBSD)

iQF8BAEBCgBmBQJU9fAmXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRBNEUyMEZBMUQ4Nzg4RjNGMTdFNjZGMDI4
QjkyNTBFMTU2M0VERkU1AAoJEIuSUOFWPt/ljOkH/j5fjhvUYv2iihHU7EONnYO/
gPG5QTbFJ6ivRN6IzLxS7UvgFltlZYx4nWhCTuH7l0JxUH5IFEXhJFpMHuXfP+DZ
ZhcZNGqZ+Hw24ZewnE2eiLTYtpWWHRrnZPcjqfpbnzUReYojFFWTUIJy35sfbmed
t8+DGEvPyZ6a5dneu/hrTp7ekNyhs3748d3/pdO3UqTj0IwrvjyL2uKxEUdiT61q
Eh62eKZ6DEV6ltoHNqArzG/7fKM/uGFOAYXRYKEItnQDTJCIQwoLaPJGE1s4r9lr
9g0tmgB4NfA9XsnBfZlweThT93tircgL2c2oZ6rIdbYy9fhh9nbm5lS5apRT9CU=
=y3vq
-----END PGP SIGNATURE-----

--V2tfspbppmK1TQo2--



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