SlideShare uma empresa Scribd logo
1 de 25
Baixar para ler offline
Henning Rauch
                                                          henning@sones.de
                                                               Sones GmbH




         Graphdatenbanken



         Vorlesung Uni Stuttgart
         Datenbanken
         Stuttgart 02/2011


Confidential                       sones GmbH| 2/9/2011                 1
Agenda



   Einleitung

   Graphdatenbanken

   Nachteile des relationalen Models

   Vorteile von Graphdatenbanken

   Einsatzszenarien

   Sones GraphDB




                                                           2
Confidential                   sones GmbH| 2/9/2011            1
Einleitung / 1 – Aktuelle Situation



   Datenintensive, komplexe, verteilte Anwendungen
           –   Semantic Web
           –   Empfehlungssysteme
           –   Soziale Netzwerke
           –   Geoinformationssysteme
           –   Bioinformatik
           –   …
   Gemeinsamkeiten
           –   Stark vernetzte, umfangreiche Datenmengen
           –   Komplexe Strukturen
           –   Stetiges Wachstum der Datenmenge
           –   Strukturierte oder semi-strukturierte (schemalose) Beschreibung




                                                                                     3
Confidential                               sones GmbH| 2/9/2011                          1
Einleitung / 2 – Beispiel Soziales Netzwerk




  http://www.facebook.com/press/info.php?statistics


                                                                                        4
Confidential                                          sones GmbH| 2/9/2011                  1
Einleitung / 3 – Neue Probleme



   Effizientes (rekursives) Verknüpfen von
    Datensätzen?

   Beschreibung der Daten /
    Datenmodellierung?

   Effiziente (verteilte) Speicherung?

   (Horizontale) Skalierbarkeit?


                                                                  5
Confidential            sones GmbH| 2/9/2011                          1
Einleitung / 4 – Neue Anforderungen


        Rekursiv vernetze Informationen als neues Designziel

        Einfache Verwaltung strukturierter, semistrukturierter, unstrukturierter
         Datensätze

        Bessere Integration in objektorientierte Entwicklung

        Replikation von Datensätzen

        Versionierung von Datensätzen

        Effiziente Partitionierung von Datensätzen

        Graphenorientierte Operationen


                                                                                    6
Confidential                            sones GmbH| 2/9/2011                            1
Einleitung / 5 – Definition Graphdatenmodell



   Graph G(Vertices,Edges)
           – Vertices – Menge von Knoten V
           – Edges – Menge von Kanten E

     Knoten

                                      Gerichtete Kante
               Vertex0                                        Vertex1



   Einfache Modellierung alltäglicher Probleme




                                                                           7
Confidential                           sones GmbH| 2/9/2011                    1
Einleitung / 6 – Definition Graphdatenmodell



   Zusätzliche Knoten- / Kantengewichte




                                Stuttgart




                                260 km
               Jena                                      Berlin

                      ungerichtete / gewichtete Kante


                                                                    8
Confidential                      sones GmbH| 2/9/2011                  1
Graphdatenbanken / 1 – Definition




       A graph database is a database that uses graph structures with
              nodes, edges, and properties to represent and store
        information. General graph databases that can store any graph
             are distinct from specialized graph databases such as
                       triplestores and network databases.

                                    http://en.wikipedia.org/wiki/Graph_database




                                                                                  9
Confidential                      sones GmbH| 2/9/2011                                1
Graphdatenbanken / 2 – Property Graph Datenmodell




               Name : Alice        Kommuniziert mit                Name : Bob
                  ID : 0                                             ID : 1
                 Age : 23             Encrypted : true              Age : 42
                                       Method : RSA




   Erweiterung des Graphdatenmodells
           – Zusätzliche Eigenschaften (Properties) an Knoten und Kanten
           – Properties sind Key/Value Paare (Age:23)
           – Keys werden vom Schema des Knotentyps vorgegeben


   Property Graph ist ein gerichteter, multi-relationaler Graph



                                                                                10
Confidential                             sones GmbH| 2/9/2011                        1
Graphdatenbanken / 3 – Property Graph Datenmodell




               Name : TU                                              Name : Uni
                Ilmenau                                                Stuttgart
                                                 Name : Carol
                                                    ID : 3
                                                   Age : 18




                       Name: Alice            Kommuniziert mit      Name : Bob
                         ID : 0                                       ID : 1
                        Age : 23                 Encrypted : true    Age : 42
                                                  Method : RSA




                                                                                   11
Confidential                              sones GmbH| 2/9/2011                          1
Nachteile relationales Modell / 1 – Unflexible Datenhaltung



   Änderungen des Schemas sehr aufwändig
           – ALTER TABLE


   Keine semistrukturierten / unstrukturierten Daten
           – z.B. XML, JSON, …


   Keine Listenattribute
           – List<String>, Set<Integer>, Set<User>


   Keine Möglichkeit einfacher Versionierung von Datensätzen




                                                                          12
Confidential                             sones GmbH| 2/9/2011                  1
Nachteile relationales Modell / 2 – Foreign Key Constraints



   Darstellung von 1:n bzw. n:m nur über zusätzliche Mapping-
    Tabellen
           – Kein explizites Konzept für Beziehungen / Relationen


   Verknüpfung von Tabellen über rechenintensive JOIN
    Anweisungen

   Keine rekursiven JOINs

       User                                      Kommunizert mit
       ID           Name       Alter             User_ID1           User_ID2
       0            Alice      23                0                  1
       1            Bob        42                1                  0


                                                                               13
Confidential                             sones GmbH| 2/9/2011                       1
Nachteile relationales Modell / 3 – Skalierbarkeit



   Keine explizite Möglichkeit zur Skalierung und Partitionierung
    innerhalb des relationen Modells

   Keine JOINs zwischen verteilten Datenbanksystemen / -
    herstellern

   Keine integrierte Unterstützung aktueller state-of-the-art Web
    Technologien
           – HTTP/REST, Hypermedia, Semantic Web




                                                                          14
Confidential                         sones GmbH| 2/9/2011                      1
Vorteile von Graphdatenbanken / 1 – Abstraktion




   Explizites Datenmodell
   Direkte Abbildung realer Netzwerkstrukturen
   Besseres Verständnis der Anwendungsdomäne



                                                                15
Confidential                  sones GmbH| 2/9/2011                   1
Vorteile von Graphdatenbanken / 2 – Indexfreie Adjazenz



   Beziehungen / Relationen über Kanten direkt am Knoten
    modelliert
           – Kein zusätzliches Mapping erforderlich


   Keine Indizes für Relationen erforderlich
           – Hohe Performance beim Abfragen des Graphen
           – Jeder Knoten agiert als „mini-index“


   Datenlokalität / effiziente Speicherung
           – Adjazente Knoten können „nah beieinander“ persistiert werden


   Performance ist unabhängig von der Größe des Graphen



                                                                            16
Confidential                             sones GmbH| 2/9/2011                    1
Vorteile von Graphdatenbanken / 3 – Traversierung



   Eine der wichtigsten Operationen innerhalb von
    Graphdatenbanken

   Teilweise oder vollständige Abfrage eines Graphen
           – Aufbau einer Baumstruktur


   Suchen nach Knoten / Kanten mit bestimmen Eigenschaften
           – z.B. User mit mehr als 500 Freunden (Naben)


   Verschiedene Traversierungsmethoden
           – Breitensuche, Tiefensuche, algorithmische Traversierung, Random
             Walks




                                                                               17
Confidential                             sones GmbH| 2/9/2011                       1
Vorteile von Graphdatenbanken / 4 – Weitere Vorteile



   Unterstützung von state-of-the-art Schnittstellen

   Grundlage für wissenschaftliche Analysen realer
    Netzwerkstrukturen

   Zusätzliche Indizes für einfache Attribute oder komplexe
    Subgraphen

   Konzipiert für den Einsatz in verteilten Systemen / Cloud-
    Angeboten




                                                                   18
Confidential                    sones GmbH| 2/9/2011                    1
Einsatzszenarien / 1 – Graphenbasierte Algorithmen



   Bewerten von Websites in Suchmaschinen – page rank

   Wer-kennt-wen in sozialen Netzwerken – shortest path

   Empfehlungssysteme – biparite matching

   Verkehrsinfrastrukturen – minimum spanning tree

   Erkennen von Naben in Netzwerken – betweenness centrality

   Transportplanoptimierung – maximum flow

   …

                                                                19
Confidential                  sones GmbH| 2/9/2011                   1
Einsatzszenarien / 2 – Business Use-Cases



   Web
           – Klickpfad-Analyse – Welche Wege nehmen die Kunden auf dem
             Portal?


   Universal Data Access
           – Zentrales Metadaten-Repository – Unternehmensdaten zentral
             verwalten. Daten aus diversen redaktionellen Quellen (Bilder, Artikel,
             etc.) verknüpfen


   eCommerce
           – Recommendations – Empfehlung der richtigen Produkte dem richtigen
             Kunden zur richtigen Zeit (kundenspezifische Werbung)


   …


                                                                                      20
Confidential                               sones GmbH| 2/9/2011                            1
sones GraphDB / 1 - Überblick



          URL            http://www.sones.com
          Kategorie      Objektorientierte Graphdatenbank
          Datenmodell    Property-Hypergraph
          Querymethode   sones GQL, C#- / Java-API
          Sprache        C# 4.0 / .NET 4.0 / Mono
          Protokoll      REST (JSON, XML, HTML, GEXF), WebDAV
          Ziele          Management und Verknüpfung
                          semistrukturierter Daten
          Concurrency    MVCC
          Replikation    Master Slave Replikation
          Persistenz     OSE: In-Memory GraphFS
                          Enterprise: Proprietäres persistentes GraphFS
          Lizenz         AGPLv3 und proprietär kommerziell



                                                                          21
Confidential                     sones GmbH| 2/9/2011                          1
sones GraphDB / 2 – Property Hypergraph




                                                   Edge

                                                        Person Freund        Bob
                                                                              ID = 2
                                                        seit : 2009/09/21
                          Hyperedge                                         Alter = 23


           Alice       SET<Person> Freunde
            ID = 1        SetMaxNumber : 12
          Alter = 21

                        Hyperedge-Properties
                                                        Person Freund       Carol
                                                                              ID = 3
                                                        seit : 2010/04/11
                                                                            Alter = 20




                                                                                         22
Confidential                             sones GmbH| 2/9/2011                                 1
sones GraphDB / 3 – Graph Query Language



      // sones GQL Example

      // define Vertex Type (QDL)
      CREATE VERTEX User
                 ADD ATTRIBUTES (String Name, SET<User> Friends)
                 INDICES (Name)

      // add vertices Alice and Bob (QML)
        INSERT INTO User VALUES (Name = "Alice", Age = 23)
        INSERT INTO User VALUES (Name = "Bob", Age = 42)

      // add edges between Alice and Bob (QML)
        LINK User(Name = ‘Alice') VIA Friends TO User(Name = ‘Bob')
        LINK User(Name = ‘Bob') VIA Friends TO User(Name = ‘Alice‘)




                                                                      23
Confidential                          sones GmbH| 2/9/2011                 1
sones GraphDB / 4 – Live Demo




               Demo




                                                     24
Confidential   sones GmbH| 2/9/2011                       1
Kontakt


      Henning Rauch
      Head of R&D
      henning@sones.com
      Xing: Henning_Rauch
      Twitter: cosh23
                             sones GmbH
                             Schillerstraße 5
                             04109 Leipzig

                             +49-341-3929680
                                                         25
Confidential                sones GmbH| 2/9/2011              1

Mais conteúdo relacionado

Mais procurados

[D12] NonStop SQLって何? by Susumu Yamamoto
[D12] NonStop SQLって何? by Susumu Yamamoto[D12] NonStop SQLって何? by Susumu Yamamoto
[D12] NonStop SQLって何? by Susumu Yamamoto
Insight Technology, Inc.
 
YAPC::Tokyo 2013 ritou OpenID Connect
YAPC::Tokyo 2013 ritou OpenID ConnectYAPC::Tokyo 2013 ritou OpenID Connect
YAPC::Tokyo 2013 ritou OpenID Connect
Ryo Ito
 
Microsoft Azure Active Directory
Microsoft Azure Active DirectoryMicrosoft Azure Active Directory
Microsoft Azure Active Directory
David J Rosenthal
 

Mais procurados (20)

Azure active directory によるデバイス管理の種類とトラブルシュート事例について
Azure active directory によるデバイス管理の種類とトラブルシュート事例についてAzure active directory によるデバイス管理の種類とトラブルシュート事例について
Azure active directory によるデバイス管理の種類とトラブルシュート事例について
 
Graph Database Meetup in Seoul #1. What is Graph Database? (그래프 데이터베이스 소개)
Graph Database Meetup in Seoul #1. What is Graph Database? (그래프 데이터베이스 소개)Graph Database Meetup in Seoul #1. What is Graph Database? (그래프 데이터베이스 소개)
Graph Database Meetup in Seoul #1. What is Graph Database? (그래프 데이터베이스 소개)
 
K8s on AWS - Introducing Amazon EKS
K8s on AWS - Introducing Amazon EKSK8s on AWS - Introducing Amazon EKS
K8s on AWS - Introducing Amazon EKS
 
Best Practices for Integrating Active Directory with AWS Workloads
Best Practices for Integrating Active Directory with AWS WorkloadsBest Practices for Integrating Active Directory with AWS Workloads
Best Practices for Integrating Active Directory with AWS Workloads
 
[D12] NonStop SQLって何? by Susumu Yamamoto
[D12] NonStop SQLって何? by Susumu Yamamoto[D12] NonStop SQLって何? by Susumu Yamamoto
[D12] NonStop SQLって何? by Susumu Yamamoto
 
YAPC::Tokyo 2013 ritou OpenID Connect
YAPC::Tokyo 2013 ritou OpenID ConnectYAPC::Tokyo 2013 ritou OpenID Connect
YAPC::Tokyo 2013 ritou OpenID Connect
 
AWS Black Belt Online Seminar 2017 AWS体験ハンズオン~Amazon S3 バックアップ~
AWS Black Belt Online Seminar 2017 AWS体験ハンズオン~Amazon S3 バックアップ~AWS Black Belt Online Seminar 2017 AWS体験ハンズオン~Amazon S3 バックアップ~
AWS Black Belt Online Seminar 2017 AWS体験ハンズオン~Amazon S3 バックアップ~
 
Integrating your on-premises Active Directory with Azure and Office 365
Integrating your on-premises Active Directory with Azure and Office 365Integrating your on-premises Active Directory with Azure and Office 365
Integrating your on-premises Active Directory with Azure and Office 365
 
AWS Single Sign-On (SSO) 서비스 집중 탐구 - 윤석찬 :: AWS Unboxing 온라인 세미나
AWS Single Sign-On (SSO) 서비스 집중 탐구 - 윤석찬 :: AWS Unboxing 온라인 세미나AWS Single Sign-On (SSO) 서비스 집중 탐구 - 윤석찬 :: AWS Unboxing 온라인 세미나
AWS Single Sign-On (SSO) 서비스 집중 탐구 - 윤석찬 :: AWS Unboxing 온라인 세미나
 
AWS IoT Greengrass V2 の紹介
AWS IoT Greengrass V2 の紹介AWS IoT Greengrass V2 の紹介
AWS IoT Greengrass V2 の紹介
 
IA Générative et Graphes Neo4j : RAG time !
IA Générative et Graphes Neo4j : RAG time !IA Générative et Graphes Neo4j : RAG time !
IA Générative et Graphes Neo4j : RAG time !
 
Realtime Analytics on AWS
Realtime Analytics on AWSRealtime Analytics on AWS
Realtime Analytics on AWS
 
Data Lake Security on AWS
Data Lake Security on AWSData Lake Security on AWS
Data Lake Security on AWS
 
클라우드 네이티브 데이터베이스 서비스로 Oracle RAC 전환 - 김지훈 :: AWS 클라우드 마이그레이션 온라인
클라우드 네이티브 데이터베이스 서비스로 Oracle RAC 전환 - 김지훈 :: AWS 클라우드 마이그레이션 온라인클라우드 네이티브 데이터베이스 서비스로 Oracle RAC 전환 - 김지훈 :: AWS 클라우드 마이그레이션 온라인
클라우드 네이티브 데이터베이스 서비스로 Oracle RAC 전환 - 김지훈 :: AWS 클라우드 마이그레이션 온라인
 
Microsoft Azure Active Directory
Microsoft Azure Active DirectoryMicrosoft Azure Active Directory
Microsoft Azure Active Directory
 
How Dell Used Neo4j Graph Database to Redesign Their Pricing-as-a-Service Pla...
How Dell Used Neo4j Graph Database to Redesign Their Pricing-as-a-Service Pla...How Dell Used Neo4j Graph Database to Redesign Their Pricing-as-a-Service Pla...
How Dell Used Neo4j Graph Database to Redesign Their Pricing-as-a-Service Pla...
 
はじめてのOracle Cloud Infrastructure (Oracle Cloudウェビナーシリーズ: 2021年8月11日)
はじめてのOracle Cloud Infrastructure (Oracle Cloudウェビナーシリーズ: 2021年8月11日)はじめてのOracle Cloud Infrastructure (Oracle Cloudウェビナーシリーズ: 2021年8月11日)
はじめてのOracle Cloud Infrastructure (Oracle Cloudウェビナーシリーズ: 2021年8月11日)
 
AWS Black Belt Techシリーズ AWS Management Console
AWS Black Belt Techシリーズ AWS Management ConsoleAWS Black Belt Techシリーズ AWS Management Console
AWS Black Belt Techシリーズ AWS Management Console
 
[JAWS DAYS 2019] Amazon DocumentDB(with MongoDB Compatibility)入門
[JAWS DAYS 2019] Amazon DocumentDB(with MongoDB Compatibility)入門[JAWS DAYS 2019] Amazon DocumentDB(with MongoDB Compatibility)入門
[JAWS DAYS 2019] Amazon DocumentDB(with MongoDB Compatibility)入門
 
Making connections matter: 2 use cases on graphs & analytics solutions
Making connections matter: 2 use cases on graphs & analytics solutionsMaking connections matter: 2 use cases on graphs & analytics solutions
Making connections matter: 2 use cases on graphs & analytics solutions
 

Destaque

Neo4j - 5 cool graph examples
Neo4j - 5 cool graph examplesNeo4j - 5 cool graph examples
Neo4j - 5 cool graph examples
Peter Neubauer
 
Vorlesung Graphendatenbanken an der Universität Hof
Vorlesung Graphendatenbanken an der Universität HofVorlesung Graphendatenbanken an der Universität Hof
Vorlesung Graphendatenbanken an der Universität Hof
Henning Rauch
 

Destaque (20)

Employing Graph Databases as a Standardization Model towards Addressing Heter...
Employing Graph Databases as a Standardization Model towards Addressing Heter...Employing Graph Databases as a Standardization Model towards Addressing Heter...
Employing Graph Databases as a Standardization Model towards Addressing Heter...
 
Graph database Use Cases
Graph database Use CasesGraph database Use Cases
Graph database Use Cases
 
Neo4j - 5 cool graph examples
Neo4j - 5 cool graph examplesNeo4j - 5 cool graph examples
Neo4j - 5 cool graph examples
 
Introduction to Graph Databases
Introduction to Graph DatabasesIntroduction to Graph Databases
Introduction to Graph Databases
 
Data Modeling with Neo4j
Data Modeling with Neo4jData Modeling with Neo4j
Data Modeling with Neo4j
 
Converting Relational to Graph Databases
Converting Relational to Graph DatabasesConverting Relational to Graph Databases
Converting Relational to Graph Databases
 
Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...
 
Vorlesung Graphendatenbanken an der Universität Hof
Vorlesung Graphendatenbanken an der Universität HofVorlesung Graphendatenbanken an der Universität Hof
Vorlesung Graphendatenbanken an der Universität Hof
 
Modelling differential clustering and treatment effect heterogeneity in paral...
Modelling differential clustering and treatment effect heterogeneity in paral...Modelling differential clustering and treatment effect heterogeneity in paral...
Modelling differential clustering and treatment effect heterogeneity in paral...
 
HypergraphDB
HypergraphDBHypergraphDB
HypergraphDB
 
Frank Celler – Processing large-scale graphs with Google(TM) Pregel - NoSQL m...
Frank Celler – Processing large-scale graphs with Google(TM) Pregel - NoSQL m...Frank Celler – Processing large-scale graphs with Google(TM) Pregel - NoSQL m...
Frank Celler – Processing large-scale graphs with Google(TM) Pregel - NoSQL m...
 
Experimenting with Google Knowledge Graph & How Can we Potentially use it in...
 Experimenting with Google Knowledge Graph & How Can we Potentially use it in... Experimenting with Google Knowledge Graph & How Can we Potentially use it in...
Experimenting with Google Knowledge Graph & How Can we Potentially use it in...
 
Inside Google Knowledge Graph
Inside Google Knowledge GraphInside Google Knowledge Graph
Inside Google Knowledge Graph
 
Neo4j Graph Database Presentation (German)
Neo4j Graph Database Presentation (German)Neo4j Graph Database Presentation (German)
Neo4j Graph Database Presentation (German)
 
Enterprise Knowledge Graph
Enterprise Knowledge GraphEnterprise Knowledge Graph
Enterprise Knowledge Graph
 
Leveraging SAP, Hadoop, and Big Data to Redefine Business
Leveraging SAP, Hadoop, and Big Data to Redefine BusinessLeveraging SAP, Hadoop, and Big Data to Redefine Business
Leveraging SAP, Hadoop, and Big Data to Redefine Business
 
Neo4j Use Cases - Graphdatenbanken im Einsatz
Neo4j Use Cases - Graphdatenbanken im EinsatzNeo4j Use Cases - Graphdatenbanken im Einsatz
Neo4j Use Cases - Graphdatenbanken im Einsatz
 
Leveraging SAP, Hadoop, and Big Data to Redefine Business
Leveraging SAP, Hadoop, and Big Data to Redefine BusinessLeveraging SAP, Hadoop, and Big Data to Redefine Business
Leveraging SAP, Hadoop, and Big Data to Redefine Business
 
Enterprise knowledge graphs
Enterprise knowledge graphsEnterprise knowledge graphs
Enterprise knowledge graphs
 
API-Industrie
API-IndustrieAPI-Industrie
API-Industrie
 

Vortrag Graphendatenbanken Uni Stuttgart

  • 1. Henning Rauch henning@sones.de Sones GmbH Graphdatenbanken Vorlesung Uni Stuttgart Datenbanken Stuttgart 02/2011 Confidential sones GmbH| 2/9/2011 1
  • 2. Agenda  Einleitung  Graphdatenbanken  Nachteile des relationalen Models  Vorteile von Graphdatenbanken  Einsatzszenarien  Sones GraphDB 2 Confidential sones GmbH| 2/9/2011 1
  • 3. Einleitung / 1 – Aktuelle Situation  Datenintensive, komplexe, verteilte Anwendungen – Semantic Web – Empfehlungssysteme – Soziale Netzwerke – Geoinformationssysteme – Bioinformatik – …  Gemeinsamkeiten – Stark vernetzte, umfangreiche Datenmengen – Komplexe Strukturen – Stetiges Wachstum der Datenmenge – Strukturierte oder semi-strukturierte (schemalose) Beschreibung 3 Confidential sones GmbH| 2/9/2011 1
  • 4. Einleitung / 2 – Beispiel Soziales Netzwerk http://www.facebook.com/press/info.php?statistics 4 Confidential sones GmbH| 2/9/2011 1
  • 5. Einleitung / 3 – Neue Probleme  Effizientes (rekursives) Verknüpfen von Datensätzen?  Beschreibung der Daten / Datenmodellierung?  Effiziente (verteilte) Speicherung?  (Horizontale) Skalierbarkeit? 5 Confidential sones GmbH| 2/9/2011 1
  • 6. Einleitung / 4 – Neue Anforderungen  Rekursiv vernetze Informationen als neues Designziel  Einfache Verwaltung strukturierter, semistrukturierter, unstrukturierter Datensätze  Bessere Integration in objektorientierte Entwicklung  Replikation von Datensätzen  Versionierung von Datensätzen  Effiziente Partitionierung von Datensätzen  Graphenorientierte Operationen 6 Confidential sones GmbH| 2/9/2011 1
  • 7. Einleitung / 5 – Definition Graphdatenmodell  Graph G(Vertices,Edges) – Vertices – Menge von Knoten V – Edges – Menge von Kanten E Knoten Gerichtete Kante Vertex0 Vertex1  Einfache Modellierung alltäglicher Probleme 7 Confidential sones GmbH| 2/9/2011 1
  • 8. Einleitung / 6 – Definition Graphdatenmodell  Zusätzliche Knoten- / Kantengewichte Stuttgart 260 km Jena Berlin ungerichtete / gewichtete Kante 8 Confidential sones GmbH| 2/9/2011 1
  • 9. Graphdatenbanken / 1 – Definition A graph database is a database that uses graph structures with nodes, edges, and properties to represent and store information. General graph databases that can store any graph are distinct from specialized graph databases such as triplestores and network databases. http://en.wikipedia.org/wiki/Graph_database 9 Confidential sones GmbH| 2/9/2011 1
  • 10. Graphdatenbanken / 2 – Property Graph Datenmodell Name : Alice Kommuniziert mit Name : Bob ID : 0 ID : 1 Age : 23 Encrypted : true Age : 42 Method : RSA  Erweiterung des Graphdatenmodells – Zusätzliche Eigenschaften (Properties) an Knoten und Kanten – Properties sind Key/Value Paare (Age:23) – Keys werden vom Schema des Knotentyps vorgegeben  Property Graph ist ein gerichteter, multi-relationaler Graph 10 Confidential sones GmbH| 2/9/2011 1
  • 11. Graphdatenbanken / 3 – Property Graph Datenmodell Name : TU Name : Uni Ilmenau Stuttgart Name : Carol ID : 3 Age : 18 Name: Alice Kommuniziert mit Name : Bob ID : 0 ID : 1 Age : 23 Encrypted : true Age : 42 Method : RSA 11 Confidential sones GmbH| 2/9/2011 1
  • 12. Nachteile relationales Modell / 1 – Unflexible Datenhaltung  Änderungen des Schemas sehr aufwändig – ALTER TABLE  Keine semistrukturierten / unstrukturierten Daten – z.B. XML, JSON, …  Keine Listenattribute – List<String>, Set<Integer>, Set<User>  Keine Möglichkeit einfacher Versionierung von Datensätzen 12 Confidential sones GmbH| 2/9/2011 1
  • 13. Nachteile relationales Modell / 2 – Foreign Key Constraints  Darstellung von 1:n bzw. n:m nur über zusätzliche Mapping- Tabellen – Kein explizites Konzept für Beziehungen / Relationen  Verknüpfung von Tabellen über rechenintensive JOIN Anweisungen  Keine rekursiven JOINs User Kommunizert mit ID Name Alter User_ID1 User_ID2 0 Alice 23 0 1 1 Bob 42 1 0 13 Confidential sones GmbH| 2/9/2011 1
  • 14. Nachteile relationales Modell / 3 – Skalierbarkeit  Keine explizite Möglichkeit zur Skalierung und Partitionierung innerhalb des relationen Modells  Keine JOINs zwischen verteilten Datenbanksystemen / - herstellern  Keine integrierte Unterstützung aktueller state-of-the-art Web Technologien – HTTP/REST, Hypermedia, Semantic Web 14 Confidential sones GmbH| 2/9/2011 1
  • 15. Vorteile von Graphdatenbanken / 1 – Abstraktion  Explizites Datenmodell  Direkte Abbildung realer Netzwerkstrukturen  Besseres Verständnis der Anwendungsdomäne 15 Confidential sones GmbH| 2/9/2011 1
  • 16. Vorteile von Graphdatenbanken / 2 – Indexfreie Adjazenz  Beziehungen / Relationen über Kanten direkt am Knoten modelliert – Kein zusätzliches Mapping erforderlich  Keine Indizes für Relationen erforderlich – Hohe Performance beim Abfragen des Graphen – Jeder Knoten agiert als „mini-index“  Datenlokalität / effiziente Speicherung – Adjazente Knoten können „nah beieinander“ persistiert werden  Performance ist unabhängig von der Größe des Graphen 16 Confidential sones GmbH| 2/9/2011 1
  • 17. Vorteile von Graphdatenbanken / 3 – Traversierung  Eine der wichtigsten Operationen innerhalb von Graphdatenbanken  Teilweise oder vollständige Abfrage eines Graphen – Aufbau einer Baumstruktur  Suchen nach Knoten / Kanten mit bestimmen Eigenschaften – z.B. User mit mehr als 500 Freunden (Naben)  Verschiedene Traversierungsmethoden – Breitensuche, Tiefensuche, algorithmische Traversierung, Random Walks 17 Confidential sones GmbH| 2/9/2011 1
  • 18. Vorteile von Graphdatenbanken / 4 – Weitere Vorteile  Unterstützung von state-of-the-art Schnittstellen  Grundlage für wissenschaftliche Analysen realer Netzwerkstrukturen  Zusätzliche Indizes für einfache Attribute oder komplexe Subgraphen  Konzipiert für den Einsatz in verteilten Systemen / Cloud- Angeboten 18 Confidential sones GmbH| 2/9/2011 1
  • 19. Einsatzszenarien / 1 – Graphenbasierte Algorithmen  Bewerten von Websites in Suchmaschinen – page rank  Wer-kennt-wen in sozialen Netzwerken – shortest path  Empfehlungssysteme – biparite matching  Verkehrsinfrastrukturen – minimum spanning tree  Erkennen von Naben in Netzwerken – betweenness centrality  Transportplanoptimierung – maximum flow  … 19 Confidential sones GmbH| 2/9/2011 1
  • 20. Einsatzszenarien / 2 – Business Use-Cases  Web – Klickpfad-Analyse – Welche Wege nehmen die Kunden auf dem Portal?  Universal Data Access – Zentrales Metadaten-Repository – Unternehmensdaten zentral verwalten. Daten aus diversen redaktionellen Quellen (Bilder, Artikel, etc.) verknüpfen  eCommerce – Recommendations – Empfehlung der richtigen Produkte dem richtigen Kunden zur richtigen Zeit (kundenspezifische Werbung)  … 20 Confidential sones GmbH| 2/9/2011 1
  • 21. sones GraphDB / 1 - Überblick  URL http://www.sones.com  Kategorie Objektorientierte Graphdatenbank  Datenmodell Property-Hypergraph  Querymethode sones GQL, C#- / Java-API  Sprache C# 4.0 / .NET 4.0 / Mono  Protokoll REST (JSON, XML, HTML, GEXF), WebDAV  Ziele Management und Verknüpfung semistrukturierter Daten  Concurrency MVCC  Replikation Master Slave Replikation  Persistenz OSE: In-Memory GraphFS Enterprise: Proprietäres persistentes GraphFS  Lizenz AGPLv3 und proprietär kommerziell 21 Confidential sones GmbH| 2/9/2011 1
  • 22. sones GraphDB / 2 – Property Hypergraph Edge Person Freund Bob ID = 2 seit : 2009/09/21 Hyperedge Alter = 23 Alice SET<Person> Freunde ID = 1 SetMaxNumber : 12 Alter = 21 Hyperedge-Properties Person Freund Carol ID = 3 seit : 2010/04/11 Alter = 20 22 Confidential sones GmbH| 2/9/2011 1
  • 23. sones GraphDB / 3 – Graph Query Language // sones GQL Example // define Vertex Type (QDL) CREATE VERTEX User ADD ATTRIBUTES (String Name, SET<User> Friends) INDICES (Name) // add vertices Alice and Bob (QML) INSERT INTO User VALUES (Name = "Alice", Age = 23) INSERT INTO User VALUES (Name = "Bob", Age = 42) // add edges between Alice and Bob (QML) LINK User(Name = ‘Alice') VIA Friends TO User(Name = ‘Bob') LINK User(Name = ‘Bob') VIA Friends TO User(Name = ‘Alice‘) 23 Confidential sones GmbH| 2/9/2011 1
  • 24. sones GraphDB / 4 – Live Demo Demo 24 Confidential sones GmbH| 2/9/2011 1
  • 25. Kontakt Henning Rauch Head of R&D henning@sones.com Xing: Henning_Rauch Twitter: cosh23 sones GmbH Schillerstraße 5 04109 Leipzig +49-341-3929680 25 Confidential sones GmbH| 2/9/2011 1