Gentoo Archives: gentoo-dev

From: Yannick Koehler <yannick.koehler@××××××××.com>
To: gentoo-dev@g.o, Terje Kvernes <terjekv@××××××××.no>
Subject: Re: [gentoo-dev] Config Idea - take 2
Date: Tue, 23 Apr 2002 08:47:20
Message-Id: 200204230947.19464.yannick.koehler@colubris.com
In Reply to: Re: [gentoo-dev] Config Idea - take 2 by Terje Kvernes
1 -----BEGIN PGP SIGNED MESSAGE-----
2 Hash: SHA1
3
4 On April 22, 2002 06:49 pm, Terje Kvernes wrote:
5 > ick. this sounds a lot like marketspeak. honestly, the day someone
6 > starts writing XSLTs for configuration files, I wish them pity. for
7 > one thing, adding a single option in a given config suddenly
8 > requires another DTD. another DTD which is in no way _really_
9 > related to the previous one. maintenance becomes interesting. the
10 > XSLT work also has to change.
11
12 I have not heard about marketspeak, I will proceed with some research to see
13 how it fit inside my idea, thanks. I'd like more details on the thought that
14 you mention about a single option inside the config may require a whole new
15 DTD please so that I can validate that case and see how often it could occurs
16 and if there's anything existing that allow to go around it.
17
18 > second, we'd have the issue of verbosity. writing XML isn't
19 > something you do easily during emerge. imagine wanting to port from
20 > one version of the initscripts to another -- you might just want to
21 > add one single variable. we'll need to require a full XML parser
22 > just to do such a task, instead of adding a line to the end of a
23 > file. unless this gives us a very large benefit, I don't see it
24 > happening at all.
25
26 Again, please give me concrete example as I don't understand how adding a
27 variable will cause a need for a parser as XML is quite easy to use without
28 such parser.
29
30 > third. most configurationfiles are flat. very flat. with a very
31 > loose order. changing this isn't a good idea in itself, it's not
32 > needed to change either. using XML to store a very flat hierarchy
33 > is usually overkill.
34
35 You have to understand that I'm not going to replace a flat text file into an
36 XML file just for the sake of it. Actually in the current state the flat
37 file will be on the fly converted into an XML logical representation which
38 could be save as-is but most likely will not.
39
40 > and fourth, and this is very general. KISS. things work very well
41 > today. again, if we're going to change it, there should be some
42 > great promise of good things happening. again, I don't see it. :/
43
44 That may be true for you but not for me. The current state of the
45 configuration system still take up to 20 min. of my time to ensure config are
46 merged and their results is ok. That is for sure relative on which package I
47 uninstall/install and will be different for everyone of you. I actually
48 don't promise good things yet as I'm still very early and looking at the
49 details of what this represents and to evaluate if at the end the solution
50 will solve my current problems.
51
52 > whoa. this would make emerge optionally depend on a full XML
53 > suite. fair enough, 4Suite mostly works, but why? and if it is
54 > optional, will people use it?
55
56 !? Not sure I get your point here. There'll be 1 package which portage will
57 not depend on but when present portage could use. I believe that this would
58 be set using a keyword inside the USE variable and I have yet no idea as what
59 will be inside that package and the size of it. It will be for sure a goal
60 to keep it small and make it fast as with most software I work on, but the
61 primary goal will absolutely be to solve my issues such as
62 merging/unmerging/ease creation of config tools and at some point mix that
63 with an install tool.
64
65 > honestly, that XSLT-file I want to see before I will give it much
66 > faith. I handcoded XSLT for a long while and I don't see this as a
67 > trivial task. how many developers know their XML and XSLT well
68 > enough to do this (properly)?
69
70 I am not an XML/XSLT expert myself but I have learned in one day how the basic
71 system work and got a small example running with a single tutorial. There
72 seems to be plenty of those on the web and as more and more linux software
73 use XML, such as Web/Mozilla/KDE/Gnome etc., it makes me believe that there
74 will be a lot more tools related to those technologies in the very near
75 future.
76
77 XSLT doesn't seems to fit my idea of a general purpose transformation
78 languages as it seems to require an XML tree at the source to generate an XML
79 tree at the output. Something I'm thinking about is tranforming the flat
80 config into a keyword XML tree without processing instruction and then
81 applying templates on them, then reverse the process. But that's too early
82 to confirm XSLT will be up to the task.
83
84 I also have to make it a big point that the way the system is done it would
85 attract developer by its ease of use. And that's a point I need to work on,
86 how I will get that as simple as bash (well, actually that may be easy ;-)).
87 Maybe the kind of person who will help in that sector won't be ebuild
88 developers but web developers, which could possibly be a greater number of
89 people as I believe there's more web developer than there is bash developer
90 but that's not a fact but a thought.
91
92 > you'd have to interfere with /etc, otherwise inconsistencies would
93 > emerge (okay, bad pun :) and all hell would break loose.
94
95 For sure I will have to modify /etc content but again that will only be if you
96 use the tool. There's no point in making the system transform the /etc into
97 an XML logical representation to merge new config and then discarding the
98 results. I could easily make it output to a different folder and let you
99 switch between them to test. That could be a good way to let people
100 understand how the system works and to test it by having input, output and
101 merged and do compare.
102
103 > I think it sounds like the debates that happen now and then on using
104 > XML in /proc on linux-kernel. it doesn't _give_ as much as it
105 > demands. by far. if anyone can prove the gain from such a change,
106 > I'd rethink my stance, but so far the idea scares me. it adds a lot
107 > of complexity and solves very few problems, if any. :/
108
109 Yes it does, but sometimes the benefit cannot be understood until the system
110 is actually in place. Right now I see ease of merge with ease for software
111 installation and from a point of view of an administrator or a developer
112 those means nothing as he's doing there steps and they are happy with the
113 current state. For that to make sense you need to get at a different level
114 where the user is presented and they set up their system. If you want them
115 to go use some other distro fine but you can't force them, I'd actually like
116 that more people use gentoo even if they don't know all about Linux, first
117 they can learn (yes even with such an idea as I got) and they'll generate a
118 demand on you guys to continue to keep the pace with creating ebuilds.
119
120 > and no, I don't work with XML anymore. I happily got away from it.
121 > two years of trying to make DTDs "fake" inheritance and deal with
122 > version changes now and then got the best of me. if I was going to
123 > rant about XML in general, and not about this specific issue, I'd
124 > say "XML is very often the wrong solution to the wrong problem".
125
126 I can't argue with you as I have no experience (except 1 day) with XML. I'm
127 based myself on the description/purpose of those languages and from what I
128 experienced with them. That languages has been made as I understand to allow
129 software to understand content other than their mime-type. From that point
130 on software can do mostly anything and that's probably why it has not taking
131 off yet as it has not been clearly define what the software can do as there's
132 no limitations.
133
134 Some additionnal things that I could add as a secondary goal to the config
135 system could be to remotely configure it or to configure multiple computer at
136 the same time while only modifying certain parameters that are really system
137 specific that may help on the clusterisation etc... If software understand
138 what attribute are unique per PC and which could be duplicated on all PC then
139 you make it feasible to have central configuration for all your PC without a
140 single duplication in your configuration tools (the duplication exists
141 thought when you press the 'do it' button and that it generate the /etc in
142 the different PC but that may even dissappear if people get to like XML)
143
144 - --
145
146 Yannick Koehler
147 -----BEGIN PGP SIGNATURE-----
148 Version: GnuPG v1.0.6 (GNU/Linux)
149 Comment: For info see http://www.gnupg.org
150
151 iD8DBQE8xWXmfuKOJNEyL1URAuEWAKCPUzIwBrhi3CVHBcJ6PvtGd6X1LgCfQWrX
152 h9RtW8WDvlPTyWl1cihQi5g=
153 =satu
154 -----END PGP SIGNATURE-----