Re: Error reading catalog with latest (2.2.16) toolsUI jar

Hi all,

Kyle's fixes validate for me. I have just a few minor changes that would synch up the THREDDS namespace and version number.

1) Remove the DOCTYPE line that references the 0.6 DTD.
2) Add an xmlns attribute to the catalog element to point to the 1.0 XSD, "http://www.unidata.ucar.edu/namespaces/thredds/InvCatalog/v1.0";. 3) Add an empty name attribute to each catalogRef. [None of the THREDDS code fails if these aren't there but the XML parser might complain a bit. The reason is that, in the schema, catalogRef is-a dataset and dataset requires a name attribute.]

The catalog with these changes is below.

Ethan

<?xml version="1.0" encoding="utf-8"?>
<catalog xmlns="http://www.unidata.ucar.edu/namespaces/thredds/InvCatalog/v1.0";
        xmlns:xlink="http://www.w3.org/1999/xlink";
        name="test" version="1.0.1">
  <dataset name="PyDAP server">
<service base="http://climate.llnl.gov/dap"; name="PyDAP server" serviceType="DODS"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/2xco2/?thredds"; xlink:title="ipcc4/2xco2" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresb1/?thredds"; xlink:title="ipcc4/sresb1" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/1pctto4x/?thredds"; xlink:title="ipcc4/1pctto4x" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/commit/?thredds"; xlink:title="ipcc4/commit" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/20c3m/?thredds"; xlink:title="ipcc4/20c3m" name="" />

<catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/amip/?thredds"; xlink:title="ipcc4/amip" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/pdcntrl/?thredds"; xlink:title="ipcc4/pdcntrl" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/slabcntl/?thredds"; xlink:title="ipcc4/slabcntl" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/picntrl/?thredds"; xlink:title="ipcc4/picntrl" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresa2/?thredds"; xlink:title="ipcc4/sresa2" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresa1b/?thredds"; xlink:title="ipcc4/sresa1b" name="" /> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/1pctto2x/?thredds"; xlink:title="ipcc4/1pctto2x" name="" />
  </dataset>
</catalog>


Kyle Halliday wrote:

Hi Roland -

We've made some customizations to the THREDDS-generating middleware that comes with PyDAP 2.1, so we should be able to make the necessary fixes to PyDAP itself.

Thanks,
Kyle

Roland Schweitzer wrote:

Hi Kyle,

Thanks for looking into this. I think you've hit upon the solution, but ultimately I think it will take updates to the PyDAP server to truly fix the problem (or text versions of the entire hierarchy). The test catalog is valid and it reads just fine in my software. However, each of the catalogRef elements points to another catalog generated by PyDAP each of which has the same problems as the original so my software fails again when tries to work with the next level down.

Roland

Kyle Halliday wrote:

Hi Roland -

I've taken a closer look at the THREDDS being generated by our PyDAP server, and I've found a number of errors. Fortunately, they shouldn't be too difficult to correct. I was able to get the XML from http://climate.llnl.gov/dap/ipcc4?thredds to validate after:
1) Adding the encoding="utf-8" attribute to the XML declaration.
2) Adding the DOCTYPE declaration: <!DOCTYPE catalog SYSTEM "http://www.unidata.ucar.edu/projects/THREDDS/xml/InvCatalog.0.6.dtd";> 3) Referencing the xlink namespace in the catalog tag: xmlns:xlink="http://www.w3.org/1999/xlink";
4) Adding "name" and "version" attributes to the catalog tag.
5) Changing all catalogRef "href" and "title" attributes to "xlink:href" and "xlink:title", respectively.

Below is the corrected version of the THREDDS catalog, which I was able to validate with the THREDDS validation form. I've also temporarily posted this at: http://www-pcmdi.llnl.gov/test/thredds.xml
Does this parse successfully using your Java code?

Thanks,
Kyle

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE catalog SYSTEM "http://www.unidata.ucar.edu/projects/THREDDS/xml/InvCatalog.0.6.dtd";> <catalog xmlns="http://www.unidata.ucar.edu/thredds"; xmlns:xlink="http://www.w3.org/1999/xlink"; name="test" version="1.0">
   <dataset name="PyDAP server">
<service base="http://climate.llnl.gov/dap"; name="PyDAP server" serviceType="DODS"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/2xco2/?thredds"; xlink:title="ipcc4/2xco2"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresb1/?thredds"; xlink:title="ipcc4/sresb1"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/1pctto4x/?thredds"; xlink:title="ipcc4/1pctto4x"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/commit/?thredds"; xlink:title="ipcc4/commit"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/20c3m/?thredds"; xlink:title="ipcc4/20c3m"/>

<catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/amip/?thredds"; xlink:title="ipcc4/amip"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/pdcntrl/?thredds"; xlink:title="ipcc4/pdcntrl"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/slabcntl/?thredds"; xlink:title="ipcc4/slabcntl"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/picntrl/?thredds"; xlink:title="ipcc4/picntrl"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresa2/?thredds"; xlink:title="ipcc4/sresa2"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/sresa1b/?thredds"; xlink:title="ipcc4/sresa1b"/> <catalogRef xlink:href="http://climate.llnl.gov/dap/ipcc4/1pctto2x/?thredds"; xlink:title="ipcc4/1pctto2x"/>
   </dataset>
</catalog>


--
Ethan R. Davis                                Telephone: (303) 497-8155
Software Engineer                             Fax:       (303) 497-8690
UCAR Unidata Program Center                   E-mail:    edavis@xxxxxxxx
P.O. Box 3000
Boulder, CO  80307-3000                       http://www.unidata.ucar.edu/
---------------------------------------------------------------------------


==============================================================================
To unsubscribe thredds, visit:
http://www.unidata.ucar.edu/mailing-list-delete-form.html
==============================================================================


  • 2006 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the thredds archives: