170 likes | 188 Views
The Horizon Cosmological Database is a work in progress, with a complex schema and MySQL implementation. It includes simulation, halo, galaxy schemas, and data ingestion via XML files. The project aims for web data access with SQL and scripting languages.
E N D
The Horizon Cosmological Database http://horizon-vo.univ-lyon1.fr:8080/horizon DAPNIA/SEDI/LILAS
The development team • Romain Tessier CEA DAPNIA • Bruno Guiderdoni CRAL • Hervé Wosniak CRAL • Julien Devriendt CRAL • Jaime Forero CRAL • Jean-Paul Le Fèvre CEA DAPNIA DAPNIA/SEDI/LILAS
The database schema • Based on the Galics schema • Normalized : information is not duplicated, relationships are logically implemented • Still not used yet on real data • May cause performance problems DAPNIA/SEDI/LILAS
The Full Database Schema Simulation Boxes Code params Halo Cosmology Container Ascendance Descendance Galaxy Properties Properties Magnitudes Cone Apparent props DAPNIA/SEDI/LILAS
The Simulation Schema Cosmology Simulation Box cosmology_id Simulation_id timestep author_id User parameters_id Parameters DAPNIA/SEDI/LILAS
The Halo Schema Halo properties Ascendance Halo @ ts halo_id properties_id timestep ascendant_id container_id simulation_id Descendance halo_id descendant_id DAPNIA/SEDI/LILAS
The Galaxy Schema Galaxy comp properties halo_id galaxy_id at_left component (disc,bulge,burst) at_rite daughter_id comp magnitudes galaxy_id filter_id Filter component DAPNIA/SEDI/LILAS
The database implementation • MySQL • But the application should stay db independant • Connections managed by JDBC • Servers located at Saclay, Cral, CC in2p3 DAPNIA/SEDI/LILAS
The data ingestion • File format is based on XML • The content is specified by xml schemas : • Horizon-db.xsd, simulation.xsd, etc • A file is parsed, checked and the content is made persistent in the database • Running java hep.horizon.db.ie.SimulationLoader DAPNIA/SEDI/LILAS
Retrieving data from the database • Some issues to address : • Volume of data is big • Schema is complex • Performances should be reasonable • Security should stay sound DAPNIA/SEDI/LILAS
Accessing data through the web • Examine what has been done by others • Decide which kind of interface to implement • Forms • SQL • Scripting language DAPNIA/SEDI/LILAS
SQL : pros and cons • Short learning curve • Already known by many users • Straighforward to write simple queries • Hard to write complex queries • Nightmare to debug • Security is an issue DAPNIA/SEDI/LILAS
Bsh : pros and cons • Reasonable learning curve : like java, python… • These languages are very popular • True programming language • A huge number of APIs available • It’s a new language still evolving • The best scripting language is not known yet DAPNIA/SEDI/LILAS
Bsh : how it looks like • haloNumber = 2; • simulationName = "test"; • handler = new SimulationHandler(); • halo = handler.selectHalo(simulationName, haloNumber); • list = halo.getSortedGalaxies(); • for (Galaxy g : list) { • print(g.getNumber()); • } DAPNIA/SEDI/LILAS
Output results • If only a few lines : output on the web page • Otherwise in a csv formatted ascii file which can be downloaded by http • Fits files should be available in a near future DAPNIA/SEDI/LILAS
The Horizon Cosmological Database internet MySQL Tomcat Client Application Server Database Database Server browser http Client jdbc data Java programs cayenne Mozilla Client IExplorer DAPNIA/SEDI/LILAS
It’s a work in progress • A lot of things still left to be done • At this point we are testing the prototype • Access library should be developped • SQL & BSH scripts should be written and run • First simulation results should be loaded • GUI, documentation should be improved • User management should be implemented • Super big simulations should be loaded DAPNIA/SEDI/LILAS