[Zope-Moz] Re[2]: [Zope-Moz] Re: [Zope] RDF Use cases

Martijn Pieters Martijn Pieters <mj@digicool.com>
Mon, 20 Dec 1999 17:15:12 +0100


Hello Shalabh,

Monday, December 20, 1999, 2:40:24 PM, you wrote:
SC> ----- Original Message -----
SC> Sounds nice though I wonder if we're using RDF outside its intended
SC> domain here. Is RDF really meant to be used for this? Why not just XML?
SC> To state w3c: RDF is
SC> "a foundation for processing metadata"
SC> "a declarative language and provides a standard way for using XML to
SC> represent metadata in the form of statements about properties and
SC> relationships of items on the Web"

SC> If we view the SQL Method as a web resource and the arguments etc as
SC> properties then I suppose it would be right to use RDF.

SC> The visible usefulness of RDF here is really the usefulness of XML (or
SC> any object model as such). It would be just as good if we had an XML
SC> schema to represent the SQL Method or objects and then operated on that
SC> model.
SC> The only place where RDF may score over another XML is that mozilla has
SC> support to manipulate it (but [1] how much would be usable for this
SC> application. [2] does mozilla has support for XML too?)
SC> Are we mixing up 'metadata' and 'data' here?

There are other advantages to using RDF, such as aggregation. You can
mix and match RDF datasources. Also, the RDF APIs that exist now, like
Mozilla, allow you to query and manipulate RDF in a very specific way.

These issues were also discussed by the people designing things like
the Mozilla sidebar. It's an interisting discussion you might want to
have a look at, as it discusses the why and how of RDF:

  http://www.mozilla.org/xpfe/xulrdf.htm

Then again, we would be running ahead of the game if we were to decide
on an implementation now. Again, I am only speculating about a
possible use for RDF in Zope.
  
SC> One question: Will a 'Zope Studio mozilla' be distributed with Zope or
SC> will users have to get mozilla an use it to manage their Zope install?
SC> I'd favour the former and assume it for the following:-

SC> I present an architecture idea for the Zope Studio that is a bit
SC> different from that of Martijn's:-
SC> This is a bit vague yet but here goes...
SC> -There exist XML Schemas for each of the Zope object-types.
SC> -There exits XML-RPC calls for all posible operations on objects.
SC> -The XML Schemas contain info about:-
SC>   -All the attributes of the objects.
SC>   -Info about the posible RPC modification calls that modify the
SC> properties/do other stuff.
SC> -Some XSLTs to go with each of the Objects.
SC> Mozilla gets the XML doc for the object and renders it with the help of
SC> the XSLT into XUL etc. There will be user-interaction widgets here too.
SC> When the user performs an action on a widget, it gets translated to an
SC> XML-RPC call and gets sent to the server. The server sends back a new
SC> XML doc for each of the affected objects which are then rendered again
SC> by mozilla. If its really smart it can send back only the changed info
SC> for the objects and mozilla merges them in the objects on its side.
SC> If the Zope data has changed through other logins/apps those changes can
SC> also be sent to mozilla with any response. Optionally, after some
SC> interval mozilla polls the zope server(auto -refresh) to get the changes
SC> made by others.
SC> There's no RDF here. We can put it in if we want to however - some of
SC> the info about objects is stored as RDF and other is stored in other XML
SC> docs.
SC> Also, this architecture would need some specialized JS as XSLT would not
SC> provide everything that may be desirable.
SC> With this architecture too, a nicer SQL Method would be possible.

This could be another scenario for Zope Studio. One point: XML Schema
is still very much a moving target. Also, an XML Schema cannot
represent the contents of a ZODB, only the class definitions that were
used to create the instances in the ZODB. You would need:

1. An XML Schema that defines the classes, and therefor also the
   operations permitted on them. These are all also callable through
   XML-RPC.
2. An XML Document describing the actual contents of the ZODB, or at
   least of the object that we're manipulating.

There is a parallel specification for RDF Schemas:

  http://www.w3c.org/TR/PR-rdf-schema

-- 
Best regards,
 Martijn Pieters                    mailto:mj@digicool.com