[XML-SIG] XML/python approach to "smooshing docs together"?

Will Partain partain@dcs.gla.ac.uk
Sat, 11 Nov 2000 16:33:48 +0000

Folks, here's a puzzler of the "I'm sure someone's figured
this out" type...  Seeking pointers, ideas, direction, ...

The context is the Arusha Project
(http://ark.sourceforge.net/), which is trying to crack the
problem of collaborative Unix system administration.  We're
also gunning for a *universal* framework for expressing
system configurations, i.e. you might use it for hosts,
packages, users, web sites, vendor interactions, etc.  It
also needs to be comparatively *simple*.

A metaphor I'm thinking about is overlapping transparencies.
Imagine that I draw three tree-like diagrams (yes, XML docs
:-) to describe hosts:

#1  Shows the distinctive things about my Sun 'slicker',
    e.g. its name and IP address:


#2  Shows the general stuff about how I plan to set up all
    of the Suns at my site; e.g.:


#3  Shows stuff that is probably true of all Suns everywhere:

      <pgm name="DIFF" path="/usr/bin/diff" />
      <pgm name="MAKE" path="/usr/ccs/bin/make" />

Now, what if I line these three documents up at <host> and
shine a light through them -- what do I see?  I would hope
that, all together, they tell me *everything* there is to
know about my machine 'slicker'.

How might you define, precisely, such a "smooshing together"

* How do you "line up" the transparencies so you can look at

* Say you have 10 transparencies... in what order do you do
  the pair-wise "smooshing"?

* Various rules for "top-layer wins", "bottom-layer wins",
  "layers combined into a list", etc.

* Some sort of "type system" that helps to say whether the
  overall "smoosh" makes sense. ???

I can imagine something similar prevails in a document
world.  Imagine a "general info about something" document
and a "site-local info about the same something" document;
how do those get "smooshed together"?  It seems like there
is a useful general problem to be solved...

All ideas gratefully received... And if any of you
Python/XML gurus want to hang out on our ark-dev mailing
list and keep us straight on these kinds of these, I would
be *most pleased*.