[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: New Catalog XML Draft



John Caron wrote:
...
> ----- Original Message -----
> From: "Joe Wielgosz" <address@hidden>
...

1) Don't restrict service types to known values. It is certain that
people will want to add new service types, so the catalog format should
be extensible in this area.

In order to prevent ambiguity (does "dods" equal "DODS" equals
"distributed oceanographic data system"?) perhaps these types could
somehow resolve to the url of the service's home page (e.g.
DODS->http://unidata.ucar.edu/packages/dods). I don't know the most
XML-savvy way to do this but perhaps the known mappings can be included
in the DTD?

2) Same suggestion for metadata types.


In both these cases, the XML thing to do is to use a URI as a unique identifier. The options are eg:

1.  xlink:arcrole="http://unidata.ucar.edu/packages/dods";

vs

2.  metadataType="DODS"

Pros of 1: allows services to be added by anyone, URI optionally point to
explanation
Pros of 2: compact, explicitly documents allowable types


John, flipping through my XML tome, I'm wondering if it wouldn't be appropriate to use the "notation" concept here. Notations are supposed to give the parser a clue how a particular entity should be interpreted, which seems to be what we are doing with the metadataTypes and serviceTypes.

Say the THREDDS DTD contained the following:

<!NOTATION dods SYSTEM "http://unidata.ucar.edu/packages/dods";>
<!NOTATION netcdf SYSTEM "http://unidata.ucar.edu/packages/netcdf";>
<!ENTITY % standardMetadataTypes "dods | netcdf">
<!ATTLIST metadataRef metadataType
    NOTATION ( %standardmetadataTypes; ) #REQUIRED>

What I didn't realize until last night is that it is possible for the client to extend the DTD in the actual document. So if i have a protocol that is not on the THREDDS standard list, I could potentially produce the following catalog for my server:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE catalog SYSTEM "http://www.unidata.ucar.edu/projects/THREDDS/xml/InvCatalog.0.6.dtd"; [
<!NOTATION lgdp
SYSTEM "http://u-somewhere.edu/latest_greatest_data_protocol";>
<!ATTLIST metadataRef metadataType
NOTATION ( %standardMetadataTypes; | lgdp)
]>
<catalog>
<service ID="myDODSService" type="dods" />
<service ID="myLGDPService" type="lgdp" />
...
</catalog>


This means we keep our unambiguous standard list, and readability in the file, but it is still possible for people to accurately catalog their data if they are using a "non-standard" (i.e. unknown to THREDDS) service. Of course it is a bit more complicated, but only for people who are extending the standard types - for standard types it would be just like the 0.6 DTD from the data provider's p.o.v.

What do you think?

- Joe


-- Joe Wielgosz address@hidden / (707)826-2631 --------------------------------------------------- Center for Ocean-Land-Atmosphere Studies (COLA) Institute for Global Environment and Society (IGES) http://www.iges.org


NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.