Science With the Virtual Observatory |
The exercises presented here are companions to the presentation Publishing and Resource Discovery with Registries (PDF, PPT).
The ivoaregistry Java package provides a Java API and
a rudimentary command-line tool for searching registries through the
IVOA standard search interface. To build the library and tool, change
into the package directory and run ant:
on Linux/MacOS:
cd $NVOSS_HOME/java/src/ivoaregistry ant |
on Windows:
cd %NVOSS_HOME%\java\src\ivoaregistry ant |
|
regsearch is the command line tool for searching
registries via the standard interface. Currently, all the
documentation is in-lined to the command script; thus, to view it,
load src/scripts/regsearch into your favorite editor or
browser.
To use the tool, it's helpful to store the registry endpoint into a variable. At this writing, we have two compliant registries we can use; one from the AstroGrid project in the UK and one on our local network, an upgraded version of the Carnivore registry. We'll set a variable for each:
on Linux/MacOS, csh:
set agreg=http://msslxt.mssl.ucl.ac.uk:8080/astrogrid-regtest-1_0/services/RegistryQueryv1_0 set locreg=http://localhost:8080/carnivore/serviceson Linux/MacOS, sh: agreg=http://msslxt.mssl.ucl.ac.uk:8080/astrogrid-regtest-1_0/services/RegistryQueryv1_0 locreg=http://localhost:8080/carnivore/serviceson Windows: set agreg=http://msslxt.mssl.ucl.ac.uk:8080/astrogrid-regtest-1_0/services/RegistryQueryv1_0 set locreg=http://localhost:8080/carnivore/services |
Usage: regsearch -e url [ options ] command [ args ... ]where command is one of the following:
getidentity return the description of the registry getresource return the description of the resource specified by an identifier searchbyadql search for resources whose descriptions match ADQL constraints searchbykeywords search for resources whose descriptions contain given keywords idsbyadql return just IDs of resources whose descriptions match ADQL constraints idsbykeywords return just IDs of resources whose descriptions contain given keywords
In this exercise, we will use the searchbyadql command. Let's try an example.
Find all resource that mention quasars in its description:Here some options you may find helpful or instructive:
regsearch -e $agreg searchbyadql "content/description like '%galaxy%'"
Try some more examples:
-s list extract metadata from the returned records by listing their XPath identifiers in a comma-separated list; e.g. "identifier,title,capability/interface/accessURL" -v print out some extra messages about what's going on -x show the SOAP request and response messages
Find all registered organisations:
regsearch -e $agreg searchbyadql "@xsi:type like '%Organisation%'"
Find all registered organisations that work in radio astronomy:
regsearch -e $agreg searchbyadql "@xsi:type like '%Organisation%' and content/subject like '%radio%'"
Find all cone search services:
regsearch -e $agreg searchbyadql "capability/@xsi:type like '%ConeSearch%'"
In this exercise, we will together walk through the process using the NCSA Publishing Registry.
Access the Registry via the link above.
We will enter via the left panel for first time users. Before you do anything, click the check box for trying out the form without really publishing any records. After that click "Create a new site".
The first thing you have to do is register yourself--or, more precisely, your organization--as a recognized publisher in the VO. Fill out the form describing your organisation. Note the color coding indicating which fields are required and which are recommended.
When your finished filling out the form, click "Next". You now enter a login name and password for protecting write access to the records you access.
From here you can add new Resource records.
The NVO Summer School is made possible through the support of the National Science Foundation and the National Aeronautics and Space Administration.
![]() |