Developer’s corner

Differences

This shows you the differences between two versions of the page.

vospace [2011/05/18 12:36]
administrator
vospace [2012/05/10 18:08] (current)
administrator
Line 44: Line 44:
LocalFileSystemBackend and iRODSBackend will be delivered with the implementation release. LocalFileSystemBackend and iRODSBackend will be delivered with the implementation release.
- 
- 
-==== How to play with a VOSpace 2.0 service ==== 
- 
-We propose a public lite implementation of [[http://quiwi3.u-strasbg.fr/VOSpace/views|VOSpace 2.0]]. 
- 
-Warnings : this implementation is not secured (no replication, etc.) and the data can be removed at any time, it is just designed to make simple tests. 
- 
- 
-=== How to make a request ? === 
- 
-   * with a command line 
- 
-Example 1 : a script which creates a new ContainerNode named "myDir". 
- 
-<code> 
-#!/bin/sh 
- 
-SERVER="http://quiwi3.u-strasbg.fr/VOSpace" 
-POST='-X POST -H "Content-: text/xml" -d @-' 
-PUT='-X PUT -H "Content-: text/xml" -d @-' 
-DELETE='-X DELETE' 
-SEND="curl -v" 
- 
-XML=$(cat <<-'END_XML' 
-<?xml version="1.0" encoding="UTF-8"?> 
-<node xmlns="http://www.ivoa.net/xml/VOSpace/v2.0" 
-      xmlns:ns2="http://www.ivoa.net/xml/UWS/v1.0" 
-      xmlns:ns3="http://www.w3.org/1999/xlink" 
-      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
-      xsi:schemaLocation="http://www.ivoa.net/xml/VOSpace/v2.0 file:./others/xsd/VOSpace2.xsd" 
-      xsi:type="ContainerNode" 
-      uri="vos://fr.u-strasbg.cds!vospace/myDir"> 
-  <properties> 
-  </properties> 
-  <accepts/> 
-  <provides/> 
-  <capabilities/> 
-  <nodes> 
-  </nodes> 
-</node> 
-END_XML 
-) 
- 
-echo "Puts a ContainerNode at root named \"myDir\"" 
-echo "$XML" 
-echo "Response" 
-echo $XML | $SEND $PUT "$SERVER/nodes/myDir" 
-</code> 
- 
-Example 2 : a script which creates 10 UnstructuredDataNode 
- 
-<code> 
-#!/bin/sh 
- 
-SERVER="http://quiwi3.u-strasbg.fr/VOSpace" 
-POST='-X POST -H "Content-: text/xml" -d @-' 
-PUT='-X PUT -H "Content-: text/xml" -d @-' 
-DELETE='-X DELETE' 
-SEND="curl -v" 
- 
-for (( i = 1 ; i <= 10 ; i += 1 )) ; do 
-XML=$(cat <<END_XML 
-<?xml version="1.0" encoding="UTF-8"?> 
-<node xmlns="http://www.ivoa.net/xml/VOSpace/v2.0" 
-      xmlns:ns2="http://www.ivoa.net/xml/UWS/v1.0" 
-      xmlns:ns3="http://www.w3.org/1999/xlink" 
-      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
-      xsi:schemaLocation="http://www.ivoa.net/xml/VOSpace/v2.0 file:./others/xsd/VOSpace2.xsd" 
-      xsi:type="UnstructuredDataNode" 
-      uri="vos://fr.u-strasbg.cds!vospace/myDir/myNode$i"> 
-  <properties> 
-    <property uri="ivo://ivoa.net/vospace/core#description">Example of node creation</property> 
-  </properties> 
-  <accepts/> 
-  <provides/> 
-  <capabilities/> 
-</node> 
-END_XML 
-) 
- 
-echo "Puts an UnstructuredDataNode under \"myDir\" named \"myNode$i\"" 
-echo "$XML" 
-echo "Response" 
-echo $XML | $SEND $PUT "$SERVER/nodes/myDir/myNode$i" 
- 
-done 
- 
-</code> 
- 
-Example 3 : a script which adds a property to a node. 
- 
-<code> 
-#!/bin/sh 
- 
-SERVER="http://quiwi3.u-strasbg.fr/VOSpace" 
-POST='-X POST -H "Content-: text/xml" -d @-' 
-PUT='-X PUT -H "Content-: text/xml" -d @-' 
-DELETE='-X DELETE' 
-SEND="curl -v" 
- 
-XML=$(cat <<END_XML 
-<?xml version="1.0" encoding="UTF-8"?> 
-<node xmlns="http://www.ivoa.net/xml/VOSpace/v2.0" 
-      xmlns:ns2="http://www.ivoa.net/xml/UWS/v1.0" 
-      xmlns:ns3="http://www.w3.org/1999/xlink" 
-      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
-      xsi:schemaLocation="http://www.ivoa.net/xml/VOSpace/v2.0 file:./others/xsd/VOSpace2.xsd" 
-      xsi:type="UnstructuredDataNode" 
-      uri="vos://fr.u-strasbg.cds!vospace/myDir/imageM31.fits"> 
-  <properties> 
-    <property uri="ivo://ivoa.net/vospace/core#date">2010-08-23</property> 
-  </properties> 
-</node> 
-END_XML 
-) 
- 
-echo "add a property to the node" 
-echo "$XML" 
-echo "Response" 
-echo $XML | $SEND $POST "$SERVER/nodes/myDir/imageM31.fits" 
-</code> 
- 
- 
-Remarque : a local VOSpace schema is used, file:./others/xsd/VOSpace2.xsd 
- 
- 
-   * through a dedicated Java library which is easy to write (provided in the VOSpace 2.0 toolkit) 
==== Ongoing work ==== ==== Ongoing work ====
-   * remove the integrated UWS management and delegete this part to the CDS UWS library  
   * tutorial about how to implement a backend    * tutorial about how to implement a backend
-   * optimization and reduction of the overhead between the client request and the backend response +   * packaging 
-   * Security facade to finalize (TLS with password from CDS VOSpace 1.15 implementation can be used for the moment) +   * linking to last iRODS release
-   * 3 volunteers would like to test the toolkit, feedback during the Pune meeting+
==== References ==== ==== References ====
vospace.1305714994.txt.gz · Last modified: 2011/05/18 12:36 by administrator

Thanks for acknowledging the CDS developer’s resources (libraries, source code, etc.)

© Université de Strasbourg/CNRS

    • Contact