St. Louis XML Training April 2015

From The SBN Wiki
Revision as of 22:10, 16 April 2015 by Raugh (talk | contribs) (Creation - Safety Save)
Jump to navigation Jump to search

PDS node personnel will be meeting in person and via web conference on Monday, 20 April 2015, prior to the PDS Management Council Meeting, to share some tips and techniques for working with the PDS schema library and (mainly) the oXygen Editor. This page lists some topics we plan to cover, with some references and some file sets we'll use as samples and examples.

The intention is to provide sample file sets and help people work through the exercises with me as desired, so we can trouble-shoot as we go and answer questions as they come up. The structure will be largely informal, and our primary goal is that those who want to will walk away with a working development environment on their laptops that they understand and can continue to modify.

Topics

Not necessarily in chronological order, but this seems like a reasonable organization to start with:

The XML Prolog
The XML prolog is everything that precedes the document root. We'll walk through a typical prolog, what you might find in the wild, and what you should see in a PDS4 label.
Referencing Schemas
The PDS4 schema collection is actually rather complicated. We'll demonstrate how to reference the dozen or so schemas needed to validate a single, non-trivial label, and talk about ways to code those references into labels to maximize transportability.
Setting Up a Work Environment
At UMD we have half a dozen different people working on various aspects of development, migration, and validation; and each of us will be working on data from a variety of different sources. I'll demonstrate the directory structures and XML catalog files we're using to maximize transportability and commonality within the group. The same technique can be extended to the data provider's side as well.
Label Creation with Oxygen
I'll run through configuring the Oxygen editor for validating, and demonstrate the detailed process of creating a new, non-trivial PDS4 label and testing that all schema references are working as desired. The process is similar in Eclipse, though at the moment I'm only planning to focus on Oxygen. If you want to see the same thing in Eclipse, let me know.
Label Templates and Programming Technique
This'll probably be shorter than you'd think, but I will walk through a brute-force program I wrote to convert some Deep Impact labels from PDS3 to PDS4 as a demonstration of what moving to the XML paradigm buys us in development time-savers.

If you have additional topics or questions along these lines that you'd like to see covered, let me know. I can't guarantee to hit them, but we'll try.


Sample File Sets

Here are some samples, examples, and otherwise useful file sets you can download to follow along with.

  • File:DI ITS example.zip: This zip file contains the sample label we'll be coming back to throughout the day. It is a Deep Impact ITS calibrated data product label (no data file provided - ask if you want one), done as part of an earlier prototyping project. It references older schemas and draft dictionaries, so don't be surprised if you see stuff in here that you thought was no longer valid. One of the things we'll demonstrate is what happens when you change schema versions to something incompatible.
  • File:Schemas 2015-04-16.zip: This zip file contains a schema tree with all the .xsd and .sch files available from the PDS4 schema site. You'll also find some sample XML Catalog files in here to play with.
  • File:Develop-schema.zip: This zip file contains some schemas still in a development stage. We'll use this and the preceding schema collection to demonstrate some XML catalog file techniques for a development environment.
  • File:DIcode.zip: This zip file contains Mark Showalter's PDS3 label reading Python library (since improved), a template Deep Impact label similar to the example label above (but from an earlier protoype), and the Python subroutines that move data from the PDS3 label to the PDS4 label using a brute-force DOM navigation approach.