CDS Saada (Images, Spectra, Catalogues)

Laurent Michel, Sebastien Derriere & Thomas Boch

Abstract

The aim of Saada is to help astronomers to build local archives as simply as possible. A database created by Saada, a SaadaDBs, can host multiple collections populated with heterogenous data (spectra, images, tables, flatfiles...).Data collection can be linked each to other with persistent relationships.
A SaadaDB can be accessed by a Web interface
  • It comes with VO services (SSAP, SIAP and CS).
  • It allows to tag metadata with UCD, Utypes or Units.
  • A powerful query language allows to make data-mining oriented searches especially by using metadata or relationships

Saada can easily be installed on any platform (Linux, Windows or MacOS). It requires Postgres or MySQL, Tomcat and a Java compiler (1.5+).
The tutorial can be entirely done on a laptop, but in that case, services will remain local due to network issues (no permanent address). VO service may however be
run but by bypassing the registry (see step by step tutorial).
Saada can also be installed on the workshop server. This server is visible from outside and databases will therefore be seen as any VO Resources

We have proposed for the tutorial a data set designed to give a bench to use Saada features, not to make science! An example dataset has been provided for the tutorial. The example dataset is designed to provide a test-bench to use Saada features and tomake services. User provided data are welcome of course, especially for the services attended to be published in the VO.

The wokshop dataset is based on 6 XMM images and various data located in the aera covered by these images:

  • 243 XMM FITS spectra with associated plots: to be VO published in an SSA
  • One USNOB1 extraction covering this aera with a text readme files: to be VO published in a cone search
  • 3 extraction of catalogues of Galaxies with readme text files: to be VO published in a cone search

The tutorial is organised into 8 separate exercises.

NOTE 1: More documentation can be found at http://amwdb.u-strasbg.fr/saada
NOTE 2: There are a few technical notes at the end of the tutorial
NOTE 3: An instance of the tutorial database can be accessed here.VO resources attached to this database can be retrieved in the workshop registry (or browse with saada as keyword)

Tutorial steps

  • Step 1:Install Saaa and chck the workspace (required)
  • Step 2: Saada basic (required)
  • Step 3: Using Loader Configuration for Images (recommended)
  • Step 4: Building a Spectral Access Service (recommended)
  • Step 5: Building a Cone Search Service (recommended)
  • Step 6: Building another Cone Search Service (optional)
  • Step 7: Mapping UCDs (optional)
  • Step 8: Building Relationships (optional, requires 1-6)

Software requirements

Tutorial guide

Exercise 1 Install Saada and check the workspace
Goal: Check that all components needed by the session are working

Step 1 Install Saada
Saada is a database generator. It is only used to create a database ( saadaDB) template which is basically a java layer on the top of a relational database. Once created by Saada, saadaDBs are
autonomous. They do not depend on Saada or any other centralized service. Saada can be used to create as many saadaDBs as we want.

  • Create new folder
  • Create a sub-folder saada, where the database generator will be installed
  • Create a sub-folder saadadbs where resources used by future databases will be placed.
  • Create a sub-folder repository where ingested files will be copied in order to feed the download facility. The directory also contains temporary files, log files and VO query response files.
  • Run the jar installer saada.1.5.1.a.noplatform.jar (double click on it on run java -jar saada.1.5.1.a.noplatform.jar).
  • Choose the sub-folder saada as install directory.
Step 2 RDBMS setup.
This step depends on the RDBMS you are using (Postgres or MySQL). Please refer to the Saada site to learn more about RDBMS setup (http://saada.u-strasbg.fr/saada/spip.php?rubrique119).
We suggest that you use the Postgres instance running on your laptop.
The standard RDBMS setup for Saada requires creating 2 roles (database accounts) accessing the database: one with administrator privileges used for the SaadaDB management, and another with read-only restricted privileges used by the Web interface. This security precaution is not necessary in the frame of the workshop. So you can use the Postgres administrator account (login: postgres/postgres usually) for both roles.

The working of RDBMS roles is checked by Saada at database creation time.

Step 3 Build and empty database

  • Jump to Saada install in directory ./saada/Saada1.5.1.a/bin
  • Run the command ./newsaadadb.
This command starts a wizard guiding the database creation process.

  • Panel 1
    • Give your preferred name to the database (take a specific one in order to avoid collisions with other databases)
    • Select ./saadadb s as installation directory
    • Select ./repository as repository directory
  • Panel 2
    • Select the RDBMS your are using (Postgres actually).
    • Set the server name (see above)
    • Give the identifiers of the RDBMS admin role. At this step, Saada will operate all functionalities used by the administrator.
  • Panel 3
    • Give the identifiers of the RDBMS reader role.
  • Panel 4
    • Keep the default values if your are installing the DB on your laptop. If you are working on the server, set the appropriate value for the Tomcat location and the appropriate root URL (e.g. http://servername/SAADA_DB_NAME) . These parameters can be changed after.
  • Panel 5
    • Keep the default value
  • Panel 6
    • Choose keV as units for spectra. That means that the Saada data loader will try to convert spectral coordinates of input spectra in keV.
  • Important: If the Tomcat server is run by another user, make sure he can write in the directory ..../repository/SAADA_DB_NAME/voreports
Step 4 Create a collection
  • Jump to the saadaDB install bin directory ( ./saadadbs/SAADA_DB_NAME/bin)
  • Run the administration tool: ./saadmintool
All panels are disabled while no data collection has been created. We are going to create one.

  • Right click on the root node of the data tree (left part)
  • Select new collection.
  • Give a name and an optional description. The progress panel remains open after the collection has been created. This feature allows you to read logs. It is used with any operation.
    • The new collection appears then on the data tree. Click on it and all sub-collection can be seen: one sub-collection per data category.

Step 5 Test the Web Interface
  • Click on the Deploy the Web Interface button on the panel bottom.
  • Start your tomcat server if necessary.
  • Connect first to http://localhost:8080 to see whether Tomcat is running correctly.
  • Connect to http://localhost:8080/SAADA_DB_NAME (or http://servername/SAADA_DB_NAME) where SAADA_DB_NAME is the database name.
You should see something looking like this:


Exercise 2 Saada basic

Goal:
In this exercise we are going to populate our database with a small image set and to do selections by using various methods.

Step 1 Populate the database with 6 images

  • Jump to the saadaDB install bin directory ( ./saadadbs/SAADA_DB_NAME/bin)
  • Run the administration tool: ./saadmintool
  • Open the collection node.
  • Right click on the images node and select load data.
    • Click on Data Directory -> Browse.
    • Select the directory imagesXMM in data_sample.
    • Click on Load Files.
    • Click on Run Dataloader in the Load IMAGE Data dialog and confirm.
  • Click on Deploy Web App.
Step 2 Run queries with the WEB interface
  • Connect the database with the browser and click on Database map. You can see your collection with 2 different classes of image.
    • Clicking on a [det] icon shows the class fields
    • Clicking on the number following the class name shows all instance of the class.
  • Click on the Data Access button on the page banner.
    • Select images in the query editor and then Submit Query. all the images are then displayed.
    • [det] icons opens the detail of the image, [vo] icon starts Aladin with the image loaded in and the [|] icon download the image.
  • Put a name in the Search by coordinates field (e.g. ngc 4472 with 2 arcmin as radius) and Add & Submit.
  • Notice that the query can be edited by hand in the query editor text area. That allows to do quick parameter setup.
  • You can try to do more complex queries by using the query editor applet ( Refine Query button).
Step 3 Test the SIAP service with Aladin
  • Click on the VO Portal button.
  • Put ngc 4472 in the target text field and 0.03 degrees in the size field
    Note : If the Tomcat server is run by another user, make sure he can write in the directory ..../repository/SAADA_DB_NAME/voreports
  • Click on the VOT button: A SIAP result VOtable is then displayed (or downloaded according to your browser preferences)
  • Click now on the Aladin button: The Aladin applet starts with that SIAP result table loaded.

    At this point we have a SIAP service in operation. It could be published.

Exercise 3 Using Loader Configuration for Images

Goal:In the previous exercise, images have been stored in 2 different classes (see image below). That is because they do not have exactly the same keyword set. By default, Saada stores identical products in one class. That makes sure to have consistent data classes, but queries can only use class attributes (e.g. INSTRUME) or native keyword (that is the same) if they are restricted to that class.
A query on the collection ( Select IMAGE From * in MyCollection .....) can not include constraints on native keyword. In this exercise, we are going to overtake this limitation by using dataloader configuration

Step 1 Remove the collection you had created before
  • Right click on the collection on the data tree.
  • Select Remove Collection and confirm.

Step 2 Create the collections for XMM data.
  • Create a collection named XMMData for XMM data (see how to proceed in Ex1/Step4)

Step 3 Setup a configuration for images
  • Open the Dataloader Configuration tab and select the Image tab.
  • Select Class Fusion on the Class Mapping panel and give EPICImage as class name. This mode makes Saada grouping all data in one class named EPICImage .
  • Take the keyword OBJECT as name. That means that Saada will copy the value of the native keyword OBJECT in the saadaname field. Native keywords can be displayed by opening one of the files to load ( Data Sample anchor). They can be drag-dropped from the tree to the text field.
  • Save as: the configuration is named EPICImage by default.

Step 4 Populate the database with 6 images
  • Open the XMMData collection node on the data tree.
  • Right click on the images node and select load data.
    • Check the Use a Customized Configuration check box
    • Click on Browse and select IMAGE. EPICImage.config
    • Click on Data Directory -> Browse.
    • Select the directory imagesXMM in data_sample
    • Click on Load Files
    • Click on Run Dataloader in the Load IMAGE Data dialog and confirm
    • Deploy the Web application again and look at he result on the database map.

Step 5 Publish your SIAP service

  • Open the VOPortal page.
  • In the SIAP frame, select the XMMData collection.
  • A template for a SIAP registry record is provided here. It must be updated by hand and uploaded in the registry :
    • first, download the registry template.
    • open it in a text editor, and update the following attributes :
      • title
      • IMPORTANT : you MUST change the identifier in order to avoid overriding an existing service record. Put for instance ivo://aida.workshop09/SIAP/SAADA/YourName
      • publisher name
      • creator name
      • Adapt the referenceURL and the accessURL to the correct values, according to your installation
      • Save the changes, and go on the registry page (user/passwd information are available here).
      • Click on Browse and select the file you just updated. Click on Upload. That's it !

Step 6 Check the SIAP service
  • You can query your SIAP service from a VO tool, Aladin for instance. Launch Aladin beta (available on the workshop DVD or through Web Start). Then, select File --> Load from the Virtual Observatory. Click on Detailed list, select Query workshop registry, and click on Refresh. You should see your service in the list of available services. Unselect all the services, select yours,enter NGC 4472 as the target, and press Submit.
  • If the machine running the service is visible from outside, the compliance can be checked fo instance with the NVO validator (http://nvo.ncsa.uiuc.edu/dalvalidate/siavalidate.html) or by the VODesktop.
  • The service can in any case be used by Aladin or Topcat by clicking on the Aladin or Topcat button. In this case, clients access the DB directly without using the registry.

Exercise 4 Building a Spectral Access Service

Goal: We are now going to load 243 XMM spectra. All spectra will be stored in one class EPICSpectra. The XMM spectra are not calibrated, but in order to make our SSAP compliant, we will declare a fixed spectral range for the spectra.This will allow the data to be queried by the spectral rang, but the resulting spectrum wil only be displayed with raw channels.

Step 1 Setup a configuration for spectra

  • Open the Dataloader Configuration tab and select the Spectrum tab.
  • Select Class Fusion on the Class Mapping panel and give EPICSpectrum as class name. This mode makes Saada grouping all data in one class named EPICSpectrum.
  • Take the keywords OBS_ID,RA_NOM and DEC_NOM as name (comma separated). That means that Saada will concatenate the values of these native keywords i n the saadaname field. Native keywords can be displayed by opening one of the files to load ( Data Sample anchor). They can be drag-dropped from the tree to the text field.
  • Sky positions of spectra are given by keywords RA_NOM and DEC_NOM.
    • Check the only box in the position mapping mode. That means that Saada won't try to find out coordinate keywords, but it will just use those given below.
    • Put RA_NOM,DEC_NOM in the position field.
  • Set the fixed spectra range
    • Check the only box in the spectral coordinates mapping mode. Saada won't try to find out spectral coordinates. It will just use values given below.
    • Select keV as unit
    • Set '0.2,20' (quoted) in the text field. Quotes mean the mapping is a constant value but not a keyword.
  • Save as: the configuration is named EPICSpectra by default.



Step 2 Populate the database 243 spectra
  • Open the XMMData collection node on the data tree.
  • Right click on the spectra node and select load data.
    • Check the Use a Customized Configuration check box
    • Click on Browse and select SPECTRUM. EPICSpectrum.config
    • Click on Data Directory -> Browse.
    • Select the directory EPICSpectra in data_sample
    • Select FITS as Filename Mask. The directory contains a mix of plots and spectra. We have to filter FITS files.
    • Click on Load Files
    • Click on Run Dataloader in the Load SPECTRUM Data dialog and confirm
    • Deploy the Web application again and look at the result on the database map.

Step 3 Load plot files (optional)
  • Open the XMMData collection node on the data tree.
  • Right click on the flatfile node and select load data.
    • Select the directory EPICSpectra in data_sample
    • Type *.png as new filename mask and the type return.
    • Click on Load Files
    • Click on Run Dataloader in the Load FLATFILE Data dialog and confirm.
    • Deploy the Web application again and look at the result on the database map.
Step 4 Publish the SSAP service
  • Open the VOPortal page.
  • In the SSAP frame, select the XMMData collection.
  • A template for a SSAP registry record is provided here. It must be updated by hand and uploaded in the registry.
    • first, download the registry template.
    • open it in a text editor, and update the following attributes :
      • title
      • IMPORTANT : you MUST change the identifier in order to avoid overriding an existing service record. Put for instance ivo://aida.workshop09/SSAP/SAADA/YourName
      • publisher name
      • creator name
      • Adapt the referenceURL and the accessURL to the correct values, according to your installation
      • Save the changes, and go on the registry page (user/passwd information are available here).
      • Click on Browse and select the file you just updated. Click on Upload. That's it !
Step 5 Check the SSAP service

  • You can query your SIAP service from a VO tool, Aladin for instance. Launch Aladin beta (available on the workshop DVD or through Web Start). Then, select File --> Load from the Virtual Observatory. Click on Detailed list, select Query workshop registry, and click on Refresh. You should see your service in the list of available services. Unselect all the services, select yours,enter PG1216+069 as the target, and press Submit. Aladin can not display spectra, but it can ask (through SAMP) VO spectra viewers as VOSpec or SPLAT to display them
  • The compliance can for instance be checked with the VODesktop.
  • The service can anyway be used by Splat or Topcat by clicking on the Aladin or Topcat buttons. In this case, clients access directly to the DB without using the registry. Splat cannot read directly SSAP results from an URL:
    • Save the query result by clicking on the VOT button.
    • Run Splat by clicking the StarLink button
    • Open the IVOA dialog box (IVOA logo) and click on Restore Query Result.

Exercise 5 Building a Cone Search Service

Goal: We are now going to load 3 extractions of galaxy catalogues. These catalogues sources can not be put in a single class since their formats are quite different. We will ask Saada to build 3 different classes which will be seen as a single VO resource.

Step 1 Create collections

  • Create a collection named GalaxyCatalogues for sources extracted from galaxy catalogues (See Ex1/Step4)
Step 2 Setup a configuration for the Galaxy tables

  • Open the Dataloader Configuration tab ans select the Table tab.
  • Select Automatic Classifier on the Class Mapping panel and give Galaxy as class name. With this mode, Saada makes one class for each different table. Classes will be named Galaxy, Galaxy_1..... In addition with table classes, Saada creates classes for table entries named GalaxyEntry, Galaxy_1Entry.....
  • The tables come from Vizier. They have a well-known format. Saada can detect automatically the position keywords. There is no mapping to give here.
  • Save as: the configuration is named Galaxy by default.
Step 3 Load tables

  • Open the GalaxyCatalogues collection node on the data tree.
  • Right click on the table node and select load data.
    • Check the Use a Customized Configuration check box
    • Click on Browse and select TABLE.Galaxy.config
    • Click on Data Directory -> Browse.
    • Select the directory VizierSources in data_sample
    • Select FITS and VOTable as FilenameMask. The directory contains a mix of readme (*.txt) and tables either in VOTable or Fits files.
    • Click on Load Files
    • Click on Run Dataloader in the Load TABLE Data dialog and confirm
    • Deploy the Web application again ans look at the result on the database map.
Step 4 Load Readme files (optional)

  • Open the GalaxyCatalogues collection node on the data tree.
  • Right click on the flatfile node and select load data.
    • Select the directory VizierSources in data_sample
    • Type *.txt as new filename mask and the type enter.
    • Click on Load Files
    • Click on Run Dataloader in the Load FLATFILE Data dialog and confirm.
    • Deploy the Web application again ans look at the result on the database map.

Step 5 Publish the Cone Search service

  • Open the VOPortal page.
  • In the CS frame, select the GalaxyCatalogue collection.
  • A template for a CS registry record is provided here. It must be updated by hand and uploaded in the registry
    • first, download the registry template.
    • open it in a text editor, and update the following attributes :
      • title
      • IMPORTANT : you MUST change the identifier in order to avoid overriding an existing service record. Put for instance ivo://aida.workshop09/CS/SAADA/YourName
      • publisher name
      • creator name
      • Adapt the referenceURL and the accessURL to the correct values, according to your installation
      • Save the changes, and go on the registry page (user/passwd information are available here).
      • Click on Browse and select the file you just updated. Click on Upload. That's it !
Step 6 Check the CS service

  • You can query your CS service from a VO tool, Aladin for instance. Launch Aladin beta (available on the workshop DVD or through Web Start). Then, select File --> Load from the Virtual Observatory. Click on Detailed list, select Query workshop registry, and click on Refresh. You should see your service in the list of available services. Unselect all the services, select yours,enter NGC4472 as the target, and press Submit.
  • If the machine running the service is visible from outside, the compliance can for instance be checked with the NVO validator (http://nvo.ncsa.uiuc.edu/dalvalidate/csvalidate.html) or by the VODesktop.
  • The service can anyway be used by Aladin or Topcat by clicking on the Aladin or Topcat buttons. In this case, clients access directly to the DB without using the registry.



Exercise 6 Building another Cone Search Service

Goal: We are now going to load 1 extraction of the USNOB1 catalogue. We will ask Saada to build 1 class named USNOB1

Step 1 Create collections
Create a collection named Survey. (See Ex1/Step4)

Step 2 Setup a configuration for the USNOB1 table

  • Open the Dataloader Configuration tab and select the Table tab.
  • Select Class Fusion on the Class Mapping panel and give USNOB1 as class name.
  • The table comes from Vizier. They have a well-known format. Saada can detect automatically the position keywords. There is no mapping to give here.
  • Save as: the configuration is named USNOB1 by default.

Step 3 Load tables
  • Open the Survey collection node on the data tree.
  • Right click on the table node and select load data.
    • Check the Use a Customized Configuration check box.
    • Click on Browse and select TABLE.USNOB1.config.
    • Click on Data Directory -> Browse.
    • Select the directory USNO in data_sample.
    • Select FITS as FilenameMask. The directory contains a mix of readme (*.txt) and FITS tables.
    • Click on Load File.
    • Click on Run Dataloader in the Load TABLE Data dialog and confirm.
    • Deploy the Web application again and look at he result on the database map.

Step 4 Load Readme files (optional)
  • Open the Survey collection node on the data tree.
  • Right click on the flatfile node and select load data.
    • Select the directory USNO in data_sample
    • Type *.txt as new filename mask and the type enter.
    • Click on Load Files
    • Click on Run Dataloader in the Load FLATFILE Data dialog and confirm
    • Deploy the Web application again and look at the result on the database map.
Step 5 Publish the Cone Search service
  • Open the VOPortal page.
  • In the CS frame, select the Survey collection.
  • Check the registry box and then click on the VOT button. The XML page returned is a template of the service record. It must be completed by hand and uploaded in the registry or it can help to fill a registry form.
Step 6 Check the CS service
  • If the machine running the service is visible from outside, the compliance can for instance be checked with the NVO validator (http://nvo.ncsa.uiuc.edu/dalvalidate/csvalidate.html) or by the VODesktop.
  • The service can anyway be used by Aladin or Topcat by clicking on the Aladin or Topcat buttons. In this case, clients access directly to the DB without using the registry.


Exercice 7 Mapping UCDs
Goal: Saada can tag metadata with UCDs, Utypes or units. These metadata assignation can be used by the query engine to query data in heterogeneous collections. 2 of the 3 galaxy catalogues have a radial velocity. If we put the right UCD and unit on the right columns, we can select in one step sources with a given radial velocity

Step 1 Look for the entry classes having a radial velocity

  • Open the Galaxy collection node of the data tree
  • Open the entry node. 3 classes appear: Galaxy Entry, Galaxy_1Entry and Galaxy_2Entry
  • For each of them, right click and select Show Metadata.
    • Look for the Cz column.
    • One has no such column.
    • The 2 others have one. One ( Vaucouleurs) has a Cz column with a UCD = phys.veloc;pos.heliocentric
      • Double click on the UCD and save it in the clipboard.
      • Double click on false of the queriable column. That will make this column used by the query engine to build UCD based queries.
      • Right click on the meta data panel and save.



    • The other with a Cz column ( NOG) has no UCD for that column
      • Double click on the UCD and paste phys.veloc;pos.heliocentric (previously saved in the clipboard).
      • Double click on false of the queriable column.
      • Right click on the meta data panel and save.



  • Deploy the Web application.
  • From your browser, go to the Database Map and check that UCDs are properly set.
Step 2 Select entries with a radial velocity greater than 1200km/s
  • Open the Data Access page
  • Copy the following query in the text area:
    Select ENTRY From * In GalaxyCatalogues

    WhereUCD {
    [phys.veloc;pos.heliocentric] > 1200 [km/s]
    }
  • Submit
  • Try to change the unit.
  • This query can be built with the query editor: click on Refine Query.

Exercise 8 Build Relationships

Goal: In this exercise, we setup relationships between data collections. Links are persistent. They can be used to browse the database or to make data-mining oriented queries. They can also enrich VO results files.

Step 1 Associate tables with their readme.

This relationship associates a readme file to the USNO B1 table. Table file names and readme filenames are the same expect for the suffix. We use this property to setup links.

  • Check the tab relationships.
  • Click on new.
  • Name the relationship SurveyReadme.
  • Drag and drop : TABLE of collection USNOSurvey in Primary box.
    FLATFILE of collection USNOSurvey in Secondary box.
  • Click on the Create Relation button.
  • Click on the Yes button in the confirmation box.
  • Write in the keyword based condition box.

    substring(p.product_url_csa, 1, 5) = substring(s.product_url_csa, 1, 5)
  • Click on Populate, then click on ok in the box.
  • Click on Deploy the Web App.
  • Open the Database Map Web page.
  • Display the Galaxy table and display the readme page.
  • Do the same with the GalaxyCatalogues. Take GalaxyReadme as relation name.

Step 2 Associate XMM spectra with their plots.

Each XMM spectra has an associated plot which has the same name except for the suffix. In other words the 27 first characters of both spectrum filename and plot filename are the sames.
  • Check the tab relationships.
  • Click on new.
  • Name the relationship SpectVignette.
  • Drag and drop : SPECTRUM of collection XMMData in Primary box
    FLATFILE of collection XMMData in Secondary box


  • Click on the Create Relation button.
  • Click on the Yes button in the confirmation box.
  • Write in the keyword based condition box.

    substring(p.product_url_csa, 1, 27) = substring(s.product_url_csa, 1, 27)



  • Click on Populate, then click on ok in the box.
  • Click on Deploy the Web App.
  • Check on Web pages that the relationship is properly set.


Step 3 Link USNO entries with EPIC images

This relationship associate to each EPIC image the sources it contains.

  • Check the tab relationships.
  • Click on new.
  • Name the relationship SurveySources.
  • Drag and drop : IMAGE of collection XMMData in Primary box.
    ENTRY of collection USNOSurvey in Secondary box.



  • Click on the Create Relation button.
  • Click on the Yes button in the confirmation box.
  • Write in the keyword based condition box.

    isinbox(
    p.pos_ra_csa,
    p.pos_dec_csa,
    p.size_alpha_csa,
    p.size_delta_csa,
    s.pos_ra_csa, s.pos_dec_csa)



  • Click on Populate, then click on ok in the box.
  • Click on Deploy the Web App.
  • Check on Web pages that the relationship is properly set.
  • Do the same with GalaxyCatalogues (relation name GalaxySources).
  • And with XMM spectra (relation name: XRaySpectra ).


Step 4 Run queries with matrchPatterns

  • The query below select XMM images containing USNO sources, galaxy sources and EPIC spectra. You can copy it the query text area on the Data Access page. You can also build it by using the query editor started by the Refine Query button.

Select IMAGE From * In XMMData
WhereRelation {
matchPattern {
SurveySources
}
matchPattern {
GalaxySources
}
matchPattern {
XRaySpectra
}
}

  • The query below select XMM images containing no USNO sources but galaxy sources and EPIC spectra.

Select IMAGE From * In XMMData
WhereRelation {
matchPattern {
SurveySources,
Cardinality = 0
}
matchPattern {
GalaxySources
}
matchPattern {
XRaySpectra
}
}

Step 5 Publish a SIAP service with associated data

  • Open the VO portal Web page
  • In the SIAP frame, select the collection XMMData and check the box Include associated data.
  • Set ngc 4472 as position and 2 arcmin as size.
  • Click on the ALadin button.
  • Look at the data tree shown by Aladin.


Platform Notes

The table below summarizes the platforms used to test Saada

OS
arch
MySQL
Postgres
Vista Family SP1
32
5.1
8.3
XP sp 3
32
5.0
8.1
MacOS 10.5.6 32
5.1.35
8.3.7
Debian 2.6.18
32
5.0.32
8.1.2
RHE 4
64
not tested
8.2.1
Ubuntu 8.0.4
32
-
8.3.5

For Mac users:
  • MySQL: Declare users as attached to localhost: create user saadmin@localhost... otherwise the connection fails
  • MySQL: Set password to accounts, otherwise the connection fails
  • MySQL: Start the server with sudo /Library/StartupIems/MySQLCOM/MSQLCOM start
  • PSQL: The Postgres distribution comes with PGAdminIII which is very convenient to setup accounts and to manage the server. Passwords are often required to validate accounts.
  • Be sure that the directory where Saada and the saadadbs are installed has a read access for the daemon users running the database system. That is not the case for the Desktop. If your workshop working directory (see Ex1) is set in your Desktop, set this one in RX mode for everybody.
For Windows users:
  • PSQL: The Postgres distribution comes with PGAdminIII which is very convenient to setup accounts and to manage the server. Password are often required to validate accounts.
  • Be sure that the directory where Saada and the saadadbs are installed has a read access for the daemon users running the database system. Changing the permission is not enough on Windows (see http://amwdb.u-strasbg.fr/saada/spip.php?article196). On Vista, the problem can also be sorted out by using the Security tab on the properties panel of the folder.

For any platforms:
If the Tomcat server is run by another user, make sure he can write in the directory ..../repository/SAADA_DB_NAME/voreports



For the VitualBOX :
The VirtualBox delivered for the tutorial runs a low level security manager (similar to SELinux). This feature denys to the mysql server any access to user's home directories which is however necessary for Saada. This security control must be disabled for mysql (sudo or root):

aa-complain /usr/sbin/mysqld
/etc/init.d/apparmor reload 


Using local VO services

A machine with no permanent address or which cannot be accessed from outside for any reason can in principle
not host VO services. These services must be visible by any remote client and the server must be referenced by the registry

It is possible however
to use VO services located on your localhost with the condition that VO clients (Aladin, Splat or Topcat at least) also run on that machine. Each of these clients can access local services without using the registry and also simultaneously query other published resources through the registry.

Using your local SIAP
The result of SIAP queries can either be returned in a downloadable VOTable ( VOT button) or it can be directly displayed in Aladin (or Topcat) by clicking on the Aladin (or Topcat button).
In that case, Aladin behaves exactly as for a real VO query. It opens the data tree and proposes to select images to be displayed. All Aladin data sources are available to enrich your local data.

Using your local cone search
Exactly as for SIAP.

Using your local SSAP
Contrary to Aladin, the spectrum viewer can not be spawned with a SSAP query URL. You must first start Splat with the StarLink button and then execute your query by clicking on the VOT button. Save the returned VOTable on your disk and load it in Splat.

  • Click the IVOA button.
  • Click on the Restore query result button.
  • Select the file you have saved.
  • Select the spectra you want to display.


Moving your SaadaDB from a Machine to Another

We suppose here that your SaadaDB has been installed on localhost and that it has to be moved on the machine server. WE assume the the RDBMS runs on server and that it has not to be moved.

  • Installation on localhost
    • Installation directory SAADA_DB_HOME ( usually workshop_directory/saadadbs/SAADA_DB_NAME)
    • Initial repository directory REP_HOME ( usually workshop_directory/repository/SAADA_DB_NAME)
    • Initial tomcat location TOMCAT_HOME
  • Installation on server
    • Installation directory TARGET_DB_HOME
    • Initial repository directory TARGET_REP_HOME
    • Initial tomcat location TARGET_TOMCAT_HOM
Step by step process:
  • Run SAADA_DB_HOME/bin/ saadamintool.
  • Open the Database Installation panel.
  • Click on Modify the Install. Dir. and confirm.
  • Write the TARGET_DB_HOME in the dialog box .
  • Confirm and read carefully the message .
  • Copy the content of SAADA_DB_HOME into TARGET_DB_HOME.
  • Copy the content of REP_HOME into TARGET_REP_HOME.
  • Go in TARGET_DB_HOME/bin and rename the file saadadb.properties.new as saadadb.properties.
  • Start TARGET_DB_HOME/bin/saadmintool.
  • Set TARGET_REP_HOME as repository directory.
  • Set TARGET_TOMCAT_HOME as tomcat directory.
  • Update the root URL according to the server configuration.
  • Deploy the Web interface and starts if necessary Tomcat

Many thanks to Mathieu WERNER for having spent so much time to test this tutorial.

Topic attachments
I Attachment Action Size Date Who Comment
pdfpdf AIDAI2009.pdf manage 1970.4 K 25 Jun 2009 - 07:46 LaurentMICHEL Introduction of the tutorial
xmlxml getregistry-cs.xml manage 3.9 K 23 Jun 2009 - 14:14 LaurentMICHEL  
xmlxml getregistry-siap.xml manage 4.3 K 23 Jun 2009 - 14:15 LaurentMICHEL  
xmlxml getregistry-ssa.xml manage 4.0 K 23 Jun 2009 - 14:16 LaurentMICHEL  
Topic revision: r19 - 25 Jun 2009 - 10:53:22 - LaurentMICHEL
 
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback