le store webcontent
play

Le Store WebContent Benjamin NGUYEN UVSQ & INRIA-SMIS Spyros - PowerPoint PPT Presentation

1 Le Store WebContent Benjamin NGUYEN UVSQ & INRIA-SMIS Spyros ZOUPANOS U.Paris Dauphine & INRIA-LEO Workshop Sources Ouvertes et Service Caen 2010 2 Plan 1. Enjeux de lutilisation dun SGBD XML 2. Exemple du store


  1. 1 Le Store WebContent Benjamin NGUYEN UVSQ & INRIA-SMIS Spyros ZOUPANOS U.Paris Dauphine & INRIA-LEO Workshop Sources Ouvertes et Service – Caen 2010

  2. 2 Plan 1. Enjeux de l’utilisation d’un SGBD XML 2. Exemple du store centralisé 3. Store P2P

  3. 3 Enjeux de l’utilisation d’un SGBD XML

  4. 4 Architecture de WebContent XML !!

  5. 5 Le format pivot (UML)

  6. 6 Le format pivot (exemple XML) •Les schémas XML •Un exemple de document

  7. 7 Paradigme des Services Web •Un modèle pivot de documents basé sur UML et implémenté par un XML Schema •Des données échangées via des services web en XML •Un traitement en interne des informations par des programmes en C, Java, etc…

  8. 8 Quelle utilisation des documents ? •Stockage • Définition d’une URI • Sert de référence future •Récupération • Intégralité du document � indexation des documents • Sous partie du document � indexation structurelle •Requêtes � utilisation d’un langage de requête (XQuery) • Modification de la structure du document • Jointure entre documents •Modification (possiblement concurrente) des documents lors d’une chaîne de traitement � problème d’incohérences / redondance •Il faut utiliser un véritable SGBD et pas simplement des fichiers !

  9. 9 Store centralisé

  10. 10 Construction du StoreService •Problème : • Construire un wrapper de Web Service sur une base de données XML déjà existante (eXist, MonetDB, SQL Server, Quizx, … Sedna ?) • Choix d’un SGBD existant performant & fonctionnel (et des interfaces existant par rapport au langage d’interrogation) •Caractéristiques • Passage à l’échelle – Nombre de documents (ok?) – Nombre de requêtes (pb?) • Robustesse • Reprise sur panne

  11. 11 Fonctionnalités •Stockage d’un document du modèle • Génération de l’URI •Récupération du document • Dans son intégralité • Juste une sous partie • Basé sur l’utilisation des URIs WebContent •Requêtes XQuery complexes sur les documents

  12. 12 Démo du store centralisé

  13. 13 Enseignements •L’utilisation simple de fichiers n’aurait pas fonctionné •Le système passe à l’échelle en terme de documents (plusieurs milliers) •Un système d’indexation simple aurait pu suffire •Peu de fonctionnalités véritables du SGBD ont été utilisées •Il est difficile de séparer le service de stockage du service d’interrogation

  14. 14 3- Store P2P

  15. 15 Outline of P2P services Peer 1 SOAP access Peer 2 Local P2P SPARQL processor Local P2P XML- AXML Local P2P XML- AXML Peer 3 query processor query optimizer Peer 4 XML store + Local part of File Xquery processing the P2P index storage

  16. 16 Peer-to-peer storage service Implemented jointly by several peers DHT service is implemented on top of DHTs Basic functionality of a DHT • put(k,v) • get(k) Different DHTs may have different algorithmic properties • Goal: combine the advantages of the available DHTs

  17. 17 KadoP Index keys: • all element & attribute names Index values: • structural identifiers (docID, start, end) Kadop’s query language: • tree pattern language • each node is labeled with a XML node or word • edges are / or // Query evaluation: • holistic join on the list of identifiers associated to the query node labels Advantage: • fast tree patern query execution based on the one and only holistic join

  18. 18 PathFinder Index keys: • linear parent-child rooted paths Index values: • sorted docId list of documents that contain a given path PathFinder’s query language: • conjunctions of disjunctions of atomic path expressions • atomic path: XPath with child axis + predicate Special hash function: • keys that are lexicographically close are stored to peers that are close between themselves Advantage: • inequality queries e.g. / a r t i c l e [ yea r > 2005 ]

  19. 19 AXML language Data-centric Web service composition ActiveXML document = XML document including calls to (continuous) Web services • A service call contains contact info for the Web service • When the calls is activated, results are added to the document as siblings of the service call. <myPage> <myPage> <myPage> <axml <axml <axml : : : sc sc sc se se se rv rv rv i i i ce= ce= ce= " " " ge ge ge tP tP tP rog rog rog ram" ram" ram" pee pee pee r= r= r= " " " t t t v v v channe channe channe l l l . . . com"> com"> com"> <pa <pa <pa rame rame rame te te te r>Mov r>Mov r>Mov ies< ies< ies< /pa /pa /pa rame rame rame te te te r> r> r> < < < /axm /axm /axm l l l : : : sc> sc> sc> < /myPage> <prog <prog ram day=" ram day=" today today "><mov "><mov ie>Shrek ie>Shrek 3< 3< /mov /mov ie>< ie>< /p /p rog rog ram> ram> < /myPage> <prog ram day=" tomo r row"><mov ie>Per sepo l i s< /mov ie>< / p rog ram> < /myPage>

  20. 20 AXML evaluation AXML document d@p1, sc in d calls s@p2($in) Activating sc entails: • stream $in to p2 • evaluate s@p2 • stream the results of s@p2 to p1 p1 p2 d s@p2

  21. 21 OptimAX A rule based AXML optimizer • uses an extensible set of rules (cooperates with other programs to perform better document opimization) • rewrites an AXML document to another one with smaller overall evaluation cost • uses statistics for document optimization

  22. 22 Putting everything together When a query arrives: • it is introduced into a document d 1 • d 1 is given to optimAX for optimization • optimAX will cooperate with TGV – an algebraic XQuery compiler – to decompose it into sub-queries • based on the type of the sub-query, optimAX will create a call to the right DHT • a compensation query will be added in the new document d 2 above all the calls to the DHTs • further optimization if needed will be performed • d 2 will be given to the AXML engine for evaluation

  23. 23 Outline of P2P services Peer 1 SOAP access Peer 2 Local P2P SPARQL processor Local P2P XML- AXML Local P2P XML- AXML Peer 3 query processor query optimizer Peer 4 XML store + Local part of File Xquery processing the P2P index storage

  24. 24 Example Original query f o r $d1 i n /Co l1/Book , $d2 i n / Co l2 /Book where $d1 /PageNo < 400 and $d2 /Au thor = "U l lman" and $d2 /Code = $d1 /Code r e tu rn $d2 /T i t l e OptimAX TGV

  25. 25 Example Join query Join query f o r $x_0 i n $ i n_0 / / r es , $x_1 i n $ i n_1 / / res f o r $x_0 i n $ i n_0 / / r es , $x_1 i n $ i n_1 / / res where $x_0 / /Code= $x_1 /Code where $x_0 / /Code= $x_1 /Code re tu rn $x_0 / /T i t l e re tu rn $x_0 / /T i t l e Tree pattern query Tree pattern query Query with inequality Query with inequality <Co l2> <Co l2> f o r $d1 i n /Co l1 / Book f o r $d1 i n /Co l1 / Book <Book re tu rned=" t rue "> where $d1 /PageNo < 400 re tu rn <Book re tu rned=" t rue "> where $d1 /PageNo < 400 re tu rn <Au tho r>U l l man</Au tho r> <res> {$d1 /Code } < / res> <Au tho r>U l l man</Au tho r> <res> {$d1 /Code } < / res> <Code />< /Book> <Code />< /Book> < /Co l2> < /Co l2>

  26. 26 SPARQL processor In WebContent there are semantic data to be queried. A semantic peer marks available resources according to the appropriate ontologies. Semantic peers interact with each other by means of mapping. With the use of ontologies and mappings, reasoning can be inferred.

  27. 27 Semantic example Query: Aircraft P1 Q(X) :- P1:Aircraft(X) Max conjunctive rewritings: P2 Airplane R1(X) :- P1:Aircraft(X) R2(X) :- P2:Airplane(X) Airliner Cargo R3(X) :- P2:Airliner(X) R4(X) :- P2:Cargo(X)

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend