FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S)...
-
Upload
roland-clowney -
Category
Documents
-
view
218 -
download
2
Transcript of FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S)...
![Page 1: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/1.jpg)
FP6-511513
OntoGrid: Paving the way for Knowledgeable
Grid Services and Systems
www.ontogrid.net
WS-DAIOnt-RDF(S) Hands-on session
OntoGrid Semantic Grid TutorialManchester, Feb 2007
Miguel Esteban Gutiérrez (U.P.M.)
![Page 2: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/2.jpg)
2OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Outline of the tutorial
Part I: Theoretical introduction
Part II: Hands-on exercises
![Page 3: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/3.jpg)
3OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Part I: Theoretical introduction
![Page 4: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/4.jpg)
4OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Outline of the tutorialTheoretical introduction
An introductory scenarioOntology share/reuse problemPossible solutionsOur approach
The specificationFoundationsOperational model
The implementationArchitectureRDF(S) Storage support
![Page 5: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/5.jpg)
5OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
??
??
Ontology share/reuse problem
Node A
RDF(S)
3store
Node C
OWL
Jena
Node B
RDF(S)
Kowaki
Node D
Ontology evaluatorOntology evaluator
Evaluating ontology...
Parameters Ontology1.rdf Ontology1.owl
File Edit Evaluation
<service> <name>robes</name> <atribute> <atrname>product</atrname> <value>dressingGown</value> </atribute> <atribute> <atrname>washing_instruction</atrname> <value>machineWash</value> <value>handWash</value> <value>dryClean</value> </atribute> </service>
OWL
Sesame
WebODE
Client
??
??
????
????3Store
Kowari
![Page 6: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/6.jpg)
6OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Possible solutionsAccess through proprietary interfaces
The client needs to know the specific APIs of every single source it has to connect to:
Operational model
Data model
Node A
RDF(S)
3store
API <<A>>
Client
API <<A>>::methodXXX()
result XXX
THIN CLIENT
![Page 7: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/7.jpg)
7OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Possible solutions (II)Acquire the fulls contents
Download overhead: how big is the part of the ontology that will be used?
How often are the ontologies synchronized?
Node A
RDF(S)
3store
HTTP
Client
HTTP::get (ontology_url)
serialized ontology
THICK CLIENT
![Page 8: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/8.jpg)
8OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Our approach
Standardise an RDF(S) ontology access mechanism that: Provides an homogeneus access interface Defines an operational model based on the model
itself Full CRUD (beyond SPARQL protocol)
Prevents the user from dealing directly with the physical resources (resource virtualization)
![Page 9: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/9.jpg)
9OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The specificationWS-DAIOnt-RDF(S)– RDF(S) Access in Grids
Web Services Data Access and Integration – The Ontology Realization for RDF(S) Access
Specification of grid compliant ontology services, which Defines a set of interfaces for accessing RDF(S) ontologies
in a Grid environment Provides two ways for accessing ontologies:
• Using model-based access functionalities
• Using RDF(S) querying languages Is fully compliant with OGSA Based on Grid (OGF) and Web Services (OASIS, W3C)
standards• WS-DAI, WS-RF, WS-Addressing
Is based on Semantic Web standards (W3C):• RDF, RDFS, SPARQL
![Page 10: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/10.jpg)
10OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
What is a Grid?
LicenseLicense
PrinterPrinter
A grid is a system consisting of Distributed but connected resources and Software and/or hardware that provides and manages logically
seamless access to those resources to meet desired objectives
A grid is a system consisting of Distributed but connected resources and Software and/or hardware that provides and manages logically
seamless access to those resources to meet desired objectives
R2AD
DatabaseDatabase
Webserver
Webserver
Data CenterCluster
Handheld Supercomputer
Workstation
Server
Taken from Hiro Kishimoto’s keynote in GGF17
![Page 11: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/11.jpg)
11OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The specification (II)The Grid as an ontology deployment playground
EGA Reference Model De-facto standard grid architecture
Open Grid Services Architecture (OGSA) SoA and web services based instantiation of EGA Reference Model
Infrastructure Services (i.e. transactions) Execution Management Services(i.e. job management) Data Services
• Security• Data Description• Data Access• Storage Resource Management• Cache Services• Data Replication• Data Federation• Metadata Catalogue & Registries
Resource Management Services Security Services (i.e. AAA) Self-management Services Information Services (i.e. provenance)
WS-DAISpecificatio
n
![Page 12: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/12.jpg)
12OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The specification (III)How does the specification fit in WS-DAI
WS-DAI
WS-DAIR WS-DAIX
Sets general pattern for realisations
Possible Future Realisations
Extensions for specific kinds of data resource
RelationalSQL
XMLXQuery/XPath
WS-DAIOnt-RDF(S)
Ontology OpsQuery lang.
![Page 13: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/13.jpg)
13OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The specification (II)Data resources
![Page 14: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/14.jpg)
14OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The specification (III)Interface organization
![Page 15: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/15.jpg)
15OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
RDFSRepositorySelectorServiceRDFSRepositorySelector
Service
RDFSRepositorySelectorAccess
RDFSRepositorySelectorFactory
RDFSRepositorySelectorDescription
RDFSRepository Service
RDFSRepositoryAccess
RDFSRepositoryFactory
RDFSRepositoryDescription
RDFSClass Service
RDFSClassAccess
RDFSClassDescription
![Page 16: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/16.jpg)
16OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
RDFSRepositoryServiceRDFSRepositorySelector
Service
RDFSRepositorySelectorAccess
RDFSRepositorySelectorFactory
RDFSRepositorySelectorDescription
RDFSRepository Service
RDFSRepositoryAccess
RDFSRepositoryFactory
RDFSRepositoryDescription
RDFSClass Service
RDFSClassAccess
RDFSClassDescription
![Page 17: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/17.jpg)
17OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
RDFSClassService
RDFSRepositorySelector Service
RDFSRepositorySelectorAccess
RDFSRepositorySelectorFactory
RDFSRepositorySelectorDescription
RDFSRepository Service
RDFSRepositoryAccess
RDFSRepositoryFactory
RDFSRepositoryDescription
RDFSClass Service
RDFSClassAccess
RDFSClassDescription
![Page 18: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/18.jpg)
18OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
The Implementation Architecture
Two-tier architecture:
Web Service tier, different layers according access granularity
• Upper layer: management of multiple repositories
• Intermediate layer: management of a single repository
• Lower layer: management of knowledge elements of a given repository
RDF(S) access tier:• Abstracts the interaction with
specific RDF(S) storages
RepositorySelectorService
RepositoryService
ResourceService
ListService
ContainerService
StatementService
PropertyService
ClassService
AltService
RDFSConnector
Web
Service T
ierR
DF
(S) S
torag
e Layer
WS-DAIOnt-RDF(S) Implementation Architecture
. . .
Sesame RDF Storage
SesameConnector
Jena RDF Storage
JenaConnector
OracleRDF Storage
OracleConnector
Upper service layerUpper service layer
Internediate service layerInternediate service layer
Lower service layerLower service layer
![Page 19: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/19.jpg)
19OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Part II: Hands-on exercises
![Page 20: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/20.jpg)
20OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Outline of the tutorialHands-on exercises
Methodology Introducing the players
The software distribution The sample ontologies
Hands-on work lifecycle overview Setting up the work environment
Pre-deployment configuration Prototype services deployment Post-deployment configuration
Using the services The repository selector service The repository service The class service
Advanced use of the services Cleaning up
![Page 21: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/21.jpg)
21OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Methodology
The software will be used in two ways: Command line clients Ad-hoc Java clients
The clients will be tested in a controlled scenario: The scenario will be prepared as part of the practical
• The resources will be configured• The services will be deployed in the container
When the practical ends, the alumni will clean up their computer• The services will be undeployed from the container
Two console windows will be necessary: Client window Container window
![Page 22: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/22.jpg)
22OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Setting up the work environment (I)Preparing the resources
Download the resources: Software: already downloaded yesterday Ontologies:
http://www.cs.man.ac.uk/~ocorcho/OntoGrid/SG-tutorial/software/backoffice.zip
Unpack the resources: The directory where the software was unpacked to
will be referred to as %DIST% The directory where the ontologies will be
unpacked to will be referred to as %BACKOFFICE%
![Page 23: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/23.jpg)
23OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Introducing the players (I)The software distribution
Software: ws-daio-rdfs.v0.5.zip(sg-tutorial-install.zip) Structure:
![Page 24: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/24.jpg)
24OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Introducing the players (II)The sample ontologies
Sample ontologies: backoffice.zip Main ontology used:
Insurance Grid Ontology (insurance_grid.rdfs)
Class hierarchy:
![Page 25: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/25.jpg)
25OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Hands-on work lifecycle overview
![Page 26: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/26.jpg)
26OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
RDFSRepository
log
RDFSNamespace
uri
has
RDFSSesameRepository
SC
RDFSSesameFileRepository
file
RDFSSesameMemoryRepository RDFSSesameRemoteRepository
userpassword
RDFSSesameHTTPRepository
url
RDFSSesameRMIRepository
rmiuri
SCSC SC
SC SC
Setting up the work environment (II) Pre-deployment configuration: How to configure the repositoy selector service
More RDF(S) Repositories here to be added
For example:• Jena RDF(S) storage• Oracle-RDF• RDF distributed systems (ATLAS)
![Page 27: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/27.jpg)
27OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
<?xml version="1.0" encoding="WINDOWS-1252"?><rdf:RDF xmlns:rdfs_repos="http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"><rdf:Description
rdf:about="http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#insurance_grid"><rdfs:comment>The Insurance Grid Ontology</rdfs:comment><rdfs:label>insurance_grid</rdfs:label><rdfs_repos:has
rdf:resource="http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#ig_ns"/><rdfs_repos:file>D:/2ndreview/backoffice/insurance_grid.rdfs</rdfs_repos:file><rdf:type rdf:resource="http://wsdaiordfs.eu.ist.ontogrid/
RDFSRepository#RDFSSesameFileRepository"/></rdf:Description><rdf:Description rdf:about="http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#ig_ns">
<rdfs:comment>The Insurance Grid Ontology Namespace</rdfs:comment><rdfs:label>ig_ns</rdfs:label><rdfs_repos:uri>http://www.insurancegrid.org/vocabulary#</rdfs_repos:uri><rdf:type
rdf:resource="http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#RDFSNamespace"/></rdf:Description>
</rdf:RDF>
"http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#insurance_grid"
"http://wsdaiordfs.eu.ist.ontogrid/
RDFSRepository#RDFSSesameFileRepository"
"http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#ig_ns"D:/2ndreview/backoffice/insurance_grid.rdfs
Setting up the work environment (III) Pre-deployment configuration: How to configure the repositoy selector service(II)
"http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#ig_ns"
"http://wsdaiordfs.eu.ist.ontogrid/RDFSRepository#RDFSNamespace"
http://www.insurancegrid.org/vocabulary#
![Page 28: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/28.jpg)
28OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Setting up the work environment (III) Pre-deployment configuration: Configuring the repositories that are to be used (II)
Configure the repositories that will be managed by the selector service: (at least insurance_grid.rdfs) Create a file named RDFSRepository.rdf in %DIST%/etc
Create a repository description for the default ontology that we will use:
• Name: insurance_grid• File: insurance_grid.rdfs• Log: <<any you want>>• Namespace uri: http://www.insurancegrid.org/vocabulary#
Include other repository descriptions for any extra repository that you want to use.
![Page 29: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/29.jpg)
29OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Setting up the work environment (IV)Build
Build the prototype:
> ant all
![Page 30: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/30.jpg)
30OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Setting up the work environment (V)Deploy
Deploy the services:
> ant deploy
![Page 31: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/31.jpg)
31OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Setting up the work environment (VI)Running the container & further configuration
Starting the container (Container window)> globus-start-container -nosec
Post-deployment configuration (Client window) Set up some helpful environment variables> set %SELECTOR%=\
http://localhost:8080/wsrf/services/WS-DAIO-RDFS/RDFSRepositorySelectorService
> set %REPOSITORY%=\
http://localhost:8080/wsrf/services/WS-DAIO-RDFS/RDFSRepositoryService
> set %CLASS%=\
http://localhost:8080/wsrf/services/WS-DAIO-RDFS/RDFSClassService
> set %NS%=http://www.insurancegrid.org/vocabulary#
Set up GT4 environment> globus-devel-env
![Page 32: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/32.jpg)
32OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (I) – The Repository Selector Service
Check out how many repositories are available> get-number-of-repositories -s %SELECTOR%There are n repositories available in the backoffice directory managed by the selector.
List the names of the available repositories> list-repositories -s %SELECTOR%The name of each of the repositories managed by the selector will be returned.
Retrieve an available repository> get-repository -s %SELECTOR% insurance_grid repository.rdfsThe repository is retrieved and stored in the specified file in RDF/XML .
Load an available repository> load-repository -s %SELECTOR% insurance_gridThe service returns the EPR of the repository service to which we have to contact in order to access to the specified repository.The EPR is serialized to a file that will be used in the following examples. It will be referred to as <EPR_REPOSITORY>.
![Page 33: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/33.jpg)
33OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (II) – The Repository Service
List the available classes in the repository:> list-classes -e <EPR_REPOSITORY> The service returns all the available classes defined in the repository, plus those predefined by RDFS.
Load an available class from the repository:> load-class -e <EPR_REPOSITORY> %NS%#Company> load-class -e <EPR_REPOSITORY> %NS%#PhysicalActor
The service returns the EPR of the class service to which we have to contact in order to access to the specified classes.The EPR to access to the Company class will be referred to as <EPR_CLASS_1>, and the EPR to access the PhysicalActor class will be referred to as <EPR_CLASS_2>.
![Page 34: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/34.jpg)
34OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (III) – The Class Service (I)
List the direct subclasses of a class:> list-related-classes -e <EPR_CLASS_1> -lr subclasses
The result is the direct subclasses of the class, that is, those which appear as subject in a rdfs:subClassOf relationship which has as object the class represented by the service.
![Page 35: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/35.jpg)
35OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (IV) – The Class Service (II)
List direct superclasses of a class:> list-related-classes -e <EPR_CLASS_1> -lr superclasses
The result is the direct superclasses of the class, that is, those which appear as object in a rdfs:subClassOf relationship which has as subject the class represented by the service.
![Page 36: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/36.jpg)
36OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (V) – The Class Service (III)
List of the subclasses of a class:> list-related-classes -e <EPR_CLASS_1> -lr subclasses -chr
The result is all the subclasses of the class, that is, those classes which are direct subclasses or have a subclass that is direct subclass of the class represented by the service
![Page 37: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/37.jpg)
37OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (VI) – The Class Service (IV)
List of the superclasses of a class:> list-related-classes -e <EPR_CLASS_1> -lr superclasses -chr
The result is all the superclasses of the class, that is, those which are direct superclasses or have a superclass that is direct superclass of the class represented by the service
![Page 38: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/38.jpg)
38OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (VII) – The Class Service (V)
List of the siblings of the class:> list-related-classes -e <EPR_CLASS_1> -lr siblings
The result is the sibling classes of the class, that is, those have the same direct superclasses than the class represented by the service.
![Page 39: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/39.jpg)
39OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (VIII) – The Class Service (VI)
List the direct subclasses of a class:> list-related-classes -e <EPR_CLASS_2> -lr subclasses
The result is the direct subclasses of the class, that is, those which appear as subject in a rdfs:subClassOf relationship which has as object the class represented by the service.
![Page 40: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/40.jpg)
40OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (IX) – The Class Service (VII)
List direct superclasses of a class:> list-related-classes -e <EPR_CLASS_2> -lr superclasses
The result is the direct superclasses of the class, that is, those which appear as object in a rdfs:subClassOf relationship which has as subject the class represented by the service.
![Page 41: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/41.jpg)
41OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (X) – The Class Service (VIII)
List of the subclasses of a class:> list-related-classes -e <EPR_CLASS_2> -lr subclasses -chr
The result is all the subclasses of the class, that is, those classes which are direct subclasses or have a subclass that is direct subclass of the class represented by the service
![Page 42: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/42.jpg)
42OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (XI) – The Class Service (IX)
List of the superclasses of a class:> list-related-classes -e <EPR_CLASS_2> -lr superclasses -chr
The result is all the superclasses of the class, that is, those which are direct superclasses or have a superclass that is direct superclass of the class represented by the service
![Page 43: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/43.jpg)
43OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (XII) – The Class Service (X)
List of the siblings of the class:> list-related-classes -e <EPR_CLASS_2> -lr siblings
The result is the sibling classes of the class, that is, those have the same direct superclasses than the class represented by the service.
![Page 44: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/44.jpg)
44OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (XIII) – The Repository Service (III)
Execute a simple graph query defined different query languages:
> execute-query -e <EPR_REPOSITORY> -ql rql class_query.rql> execute-query -e <EPR_REPOSITORY> -ql rdql class_query.rdql> execute-query -e <EPR_REPOSITORY> -ql serql class_query.serql
The simple query used selects the classes defined in the repository: RQL:
class RDQL:
SELECT ?x WHERE (?x <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2000/01/rdf-schema#Class>)
SERQL:SELECT DISTINCT C FROM {C} rdf:type {rdfs:Class}
As expected, the three queries have the same results: the classes defined in the repository plus the predefined by RDFS.
![Page 45: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/45.jpg)
45OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Using the services (XIV) – The Repository Service (IV)
Execute a simple construct query in SERQL The query creates an ad-hoc S ex:superclassOf C relationship between each two classes S and C such as C rdfs:subClassOf S holds:CONSTRUCT {S} ex:superClassOf {C} FROM {C} rdf:type {rdfs:Class}; rdfs:subClassOf {S} USING NAMESPACE ex = <http://example.org/things#>
Using the graph querying interface:> execute-query -e <EPR_REPOSITORY> -ql serql construct.serql
In this case the results are returned in a table, as happened with the previous queries. Using the construct query interface:> execute-construct-query -e <EPR_REPOSITORY> -ql serql construct.serql construct.result.rdfs
In this case the results are stored serialized in RDF/XML in an specified file.
![Page 46: FP6-511513 OntoGrid: Paving the way for Knowledgeable Grid Services and Systems WS-DAIOnt-RDF(S) Hands-on session OntoGrid Semantic Grid.](https://reader035.fdocuments.us/reader035/viewer/2022081516/551abeea55034606048b48a4/html5/thumbnails/46.jpg)
46OntoGrid Semantic Grid Tutorial - Manchester, Feb 2007
Cleaning up
Before moving to the next session, clean the container :-D
> cd %DIST%
> ant undeploy