SlideShare uma empresa Scribd logo
1 de 40
Baixar para ler offline
GraphQL ♥ Graph Database
15/03/2018
Marco Liberati
@dej611
Enrico Risa
@wolf4ood
Agenda
- GraphQL Introduction
- GraphQL Schema Definition (Meetup)
- Why GraphQL ♥ Graph Database?
- Schema Impl with a GraphDB
WHY GRAPHQL?
Let’s Talk About Rest first
● Resource Based
● HTTP Verbs
○ GET
○ PUT
○ PATCH
○ DELETE
○ POST
Actions -> Verbs + Uris
Meetup model with REST
● https://api.meetup.com/:urlname
● https://api.meetup.com/:urlname/members
● https://api.meetup.com/:urlname/events
● https://api.meetup.com/:urlname/events/:event_id/rsvp
Sounds Cool, Let’s Use it
Multiple Round Trips Problem
How Do we Handle That?
GET /GraphRM?fields=topics
…And What about Over-fetching?
GET /GraphRM?only=id,name
I need only those fields
You will probably end up with some custom
endpoints
API Documentation
● How can i use those APIs ?
● What parameters this endpoint support?
● Is this parameter required?
● Swagger
● JSON Schema
● JSON:API
● API Blueprint
Documentation should be good in order to let
people use our APIs without headache
Potential Problems
● Multiple Round trips
● Over/Under fetching
● Documentation
What GraphQL IS NOT..
● A query language for Graph Databases
● Database / Storage Engine
● A library
● It’s not language specific
What Is IT ?
GraphQL is a query language for APIs and a runtime for fulfilling those queries
with your existing data. GraphQL provides a complete and understandable
description of the data in your API, gives clients the power to ask for exactly what
they need and nothing more, makes it easier to evolve APIs over time, and
enables powerful developer tools.
Just a spec
● A declarative query language
● A type system
● A runtime that fetch and mutate data
Hello GraphQL
Hello GraphQL (with nesting)
How does it work ?
● The server describe what is possible (a type system)
● The client can asks exactly what data it requires
● The server then gives back results with the same shape as the query
Power to the client
Powerful Type System
● Hierarchical
● Strongly-Typed
● Self Documenting
● Enable Introspection
● Client-specified queries
Types
● Objects
● Scalar
○ Boolean
○ Int
○ Float
○ String
○ Custom Types
● Enums
● Lists
● Unions
● Interfaces
GraphQL Schema Language
● GraphQL type system
● Describes what data can be queried
● Language-agnostic
GraphQL Schema Language Example
Mutation
Introspection
… Enables Tools
● GraphiQL
● Documentation
● IDE plugins
● Code generation
● Client Side Validation
● …
GraphQL Schema Definition (Meetup)
● Entity
○ User
○ Meetup
○ Tag
○ Event
● Query
○ meetupsByName
○ usersByName
GraphQL Schema Definition (Meetup)
Demo time!
https://github.com/GraphRM/graphql-graphdb
Why GraphQL ♥ Graph Database?
A GraphQL query represents a description of a relationship:
Why GraphQL ♥ Graph Database?
Person “me”
:id
:name
Person
:name
Person
:name
A GraphQL query represents a description of a relationship:
Why GraphQL ♥ Graph Database?
Person “me”
:id
:name
Person
:name
Person
:name
Problem:
● For each Person the GraphQL
reducer will go to the database and
ask for data.
● This is known as the N+1 query
problem.
● Which in turns mean poor
performance
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
● This could prevent the N+1 queries problem
● A GraphDB is designed to run traversals
● Bonus: if the schema is the same for both GraphQL and DB that is a
huge win!
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
● This is still a PoC but the idea is:
○ Parse the Schema and the query
○ Traverse the query and build a database query
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
This is not fully compatible yet but there are some PoC:
● GraphQL -> Neo4J Cypher:
https://github.com/neo4j-graphql/neo4j-graphql-js
● GraphQL -> OrientDB Gremlin + MATCH
https://github.com/kensho-technologies/graphql-compiler
What if we could translate one GraphQL query to a single GraphDB query?
Why GraphQL ♥ Graph Database?
Demo time!
https://github.com/GraphRM/graphql-graphdb
Grazie :)
Resources
● GraphQL: http://graphql.org/learn/
● AST Explorer: https://astexplorer.net/
● GRANDstack: https://grandstack.io/
● GraphQL + OrientDB:
https://blog.kensho.com/compiled-graphql-as-a-database-query-language-72e1
06844282
● GraphQL + Neo4J: https://neo4j.com/developer/graphql/
● Five common pitfalls with GraphQL and how Neo4J-GraphQL aims to solve
them:
https://blog.grandstack.io/five-common-graphql-problems-and-how-neo4j-graph
ql-aims-to-solve-them-e9a8999c8d43

Mais conteúdo relacionado

Mais procurados

ドライブレコーダの動画を使った道路情報の自動差分抽出
ドライブレコーダの動画を使った道路情報の自動差分抽出ドライブレコーダの動画を使った道路情報の自動差分抽出
ドライブレコーダの動画を使った道路情報の自動差分抽出Tetsutaro Watanabe
 
OpenAI FineTuning を試してみる
OpenAI FineTuning を試してみるOpenAI FineTuning を試してみる
OpenAI FineTuning を試してみるiPride Co., Ltd.
 
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介ippei_suzuki
 
Data ingestion and distribution with apache NiFi
Data ingestion and distribution with apache NiFiData ingestion and distribution with apache NiFi
Data ingestion and distribution with apache NiFiLev Brailovskiy
 
Knowledge Graphs and Generative AI
Knowledge Graphs and Generative AIKnowledge Graphs and Generative AI
Knowledge Graphs and Generative AINeo4j
 
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化gree_tech
 
異次元のグラフデータベースNeo4j
異次元のグラフデータベースNeo4j異次元のグラフデータベースNeo4j
異次元のグラフデータベースNeo4j昌桓 李
 
Prometheus入門から運用まで徹底解説
Prometheus入門から運用まで徹底解説Prometheus入門から運用まで徹底解説
Prometheus入門から運用まで徹底解説貴仁 大和屋
 
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)Preferred Networks
 
【論文紹介】How Powerful are Graph Neural Networks?
【論文紹介】How Powerful are Graph Neural Networks?【論文紹介】How Powerful are Graph Neural Networks?
【論文紹介】How Powerful are Graph Neural Networks?Masanao Ochi
 
Intro to Neo4j - Nicole White
Intro to Neo4j - Nicole WhiteIntro to Neo4j - Nicole White
Intro to Neo4j - Nicole WhiteNeo4j
 
Snowflake Architecture and Performance
Snowflake Architecture and PerformanceSnowflake Architecture and Performance
Snowflake Architecture and PerformanceMineaki Motohashi
 
Workshop - Neo4j Graph Data Science
Workshop - Neo4j Graph Data ScienceWorkshop - Neo4j Graph Data Science
Workshop - Neo4j Graph Data ScienceNeo4j
 
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話Yahoo!デベロッパーネットワーク
 
Intro to Neo4j presentation
Intro to Neo4j presentationIntro to Neo4j presentation
Intro to Neo4j presentationjexp
 
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送Google Cloud Platform - Japan
 

Mais procurados (20)

DBpedia Japaneseとは?
DBpedia Japaneseとは?DBpedia Japaneseとは?
DBpedia Japaneseとは?
 
ドライブレコーダの動画を使った道路情報の自動差分抽出
ドライブレコーダの動画を使った道路情報の自動差分抽出ドライブレコーダの動画を使った道路情報の自動差分抽出
ドライブレコーダの動画を使った道路情報の自動差分抽出
 
OpenAI FineTuning を試してみる
OpenAI FineTuning を試してみるOpenAI FineTuning を試してみる
OpenAI FineTuning を試してみる
 
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介
グラフデータベース:Neo4j、そしてRDBからの移行手順の紹介
 
Data ingestion and distribution with apache NiFi
Data ingestion and distribution with apache NiFiData ingestion and distribution with apache NiFi
Data ingestion and distribution with apache NiFi
 
Knowledge Graphs and Generative AI
Knowledge Graphs and Generative AIKnowledge Graphs and Generative AI
Knowledge Graphs and Generative AI
 
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化
グラフデータベースNeo4Jでアセットダウンロードの構成管理と最適化
 
異次元のグラフデータベースNeo4j
異次元のグラフデータベースNeo4j異次元のグラフデータベースNeo4j
異次元のグラフデータベースNeo4j
 
Prometheus入門から運用まで徹底解説
Prometheus入門から運用まで徹底解説Prometheus入門から運用まで徹底解説
Prometheus入門から運用まで徹底解説
 
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)
自然言語処理を 役立てるのはなぜ難しいのか(2022/10/25東大大学院「自然言語処理応用」)
 
【論文紹介】How Powerful are Graph Neural Networks?
【論文紹介】How Powerful are Graph Neural Networks?【論文紹介】How Powerful are Graph Neural Networks?
【論文紹介】How Powerful are Graph Neural Networks?
 
Intro to Neo4j - Nicole White
Intro to Neo4j - Nicole WhiteIntro to Neo4j - Nicole White
Intro to Neo4j - Nicole White
 
Snowflake Architecture and Performance
Snowflake Architecture and PerformanceSnowflake Architecture and Performance
Snowflake Architecture and Performance
 
Workshop - Neo4j Graph Data Science
Workshop - Neo4j Graph Data ScienceWorkshop - Neo4j Graph Data Science
Workshop - Neo4j Graph Data Science
 
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話
1000台規模のHadoopクラスタをHive/Tezアプリケーションにあわせてパフォーマンスチューニングした話
 
Intro to Neo4j presentation
Intro to Neo4j presentationIntro to Neo4j presentation
Intro to Neo4j presentation
 
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送
[Cloud OnAir] Bigtable に迫る!基本機能も含めユースケースまで丸ごと紹介 2018年8月30日 放送
 
Grafana.pptx
Grafana.pptxGrafana.pptx
Grafana.pptx
 
MLflow + Kubeflow MLプラットフォーム事例 #sparktokyo
MLflow + Kubeflow MLプラットフォーム事例 #sparktokyoMLflow + Kubeflow MLプラットフォーム事例 #sparktokyo
MLflow + Kubeflow MLプラットフォーム事例 #sparktokyo
 
Graph Convolutional Network 概説
Graph Convolutional Network 概説Graph Convolutional Network 概説
Graph Convolutional Network 概説
 

Semelhante a GraphQL ♥︎ GraphDB

GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0Tobias Meixner
 
Kotlin REST & GraphQL API
Kotlin REST & GraphQL APIKotlin REST & GraphQL API
Kotlin REST & GraphQL APISean O'Brien
 
GraphQL API Crafts presentation
GraphQL API Crafts presentationGraphQL API Crafts presentation
GraphQL API Crafts presentationSudheer J
 
Modular GraphQL with Schema Stitching
Modular GraphQL with Schema StitchingModular GraphQL with Schema Stitching
Modular GraphQL with Schema StitchingSashko Stubailo
 
Introduction to GraphQL
Introduction to GraphQLIntroduction to GraphQL
Introduction to GraphQLKnoldus Inc.
 
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)Ayla Khan
 
Building Fullstack Serverless GraphQL APIs In The Cloud
Building Fullstack Serverless GraphQL APIs In The CloudBuilding Fullstack Serverless GraphQL APIs In The Cloud
Building Fullstack Serverless GraphQL APIs In The CloudNordic APIs
 
Training Week: GraphQL 2022
Training Week: GraphQL 2022Training Week: GraphQL 2022
Training Week: GraphQL 2022Neo4j
 
Green Custard Friday Talk 8: GraphQL
Green Custard Friday Talk 8: GraphQLGreen Custard Friday Talk 8: GraphQL
Green Custard Friday Talk 8: GraphQLGreen Custard
 
Introduction to Graph QL
Introduction to Graph QLIntroduction to Graph QL
Introduction to Graph QLDeepak More
 
Tutorial: Building a GraphQL API in PHP
Tutorial: Building a GraphQL API in PHPTutorial: Building a GraphQL API in PHP
Tutorial: Building a GraphQL API in PHPAndrew Rota
 
Getting Started with Spring for GraphQL
Getting Started with Spring for GraphQLGetting Started with Spring for GraphQL
Getting Started with Spring for GraphQLVMware Tanzu
 
Training Series: Build APIs with Neo4j GraphQL Library
Training Series: Build APIs with Neo4j GraphQL LibraryTraining Series: Build APIs with Neo4j GraphQL Library
Training Series: Build APIs with Neo4j GraphQL LibraryNeo4j
 
REST vs GraphQL
REST vs GraphQLREST vs GraphQL
REST vs GraphQLSquareboat
 
GraphQL (Graphene-Django)
GraphQL (Graphene-Django)GraphQL (Graphene-Django)
GraphQL (Graphene-Django)Selo Lee
 
GraphQL @ Manc.JS (March 2018)
GraphQL @ Manc.JS (March 2018)GraphQL @ Manc.JS (March 2018)
GraphQL @ Manc.JS (March 2018)Chris Grice
 
PHP, the GraphQL ecosystem and GraphQLite
PHP, the GraphQL ecosystem and GraphQLitePHP, the GraphQL ecosystem and GraphQLite
PHP, the GraphQL ecosystem and GraphQLiteJEAN-GUILLAUME DUJARDIN
 

Semelhante a GraphQL ♥︎ GraphDB (20)

GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0GraphQL Bangkok meetup 5.0
GraphQL Bangkok meetup 5.0
 
Kotlin REST & GraphQL API
Kotlin REST & GraphQL APIKotlin REST & GraphQL API
Kotlin REST & GraphQL API
 
GraphQL + relay
GraphQL + relayGraphQL + relay
GraphQL + relay
 
GraphQL API Crafts presentation
GraphQL API Crafts presentationGraphQL API Crafts presentation
GraphQL API Crafts presentation
 
Modular GraphQL with Schema Stitching
Modular GraphQL with Schema StitchingModular GraphQL with Schema Stitching
Modular GraphQL with Schema Stitching
 
Introduction to GraphQL
Introduction to GraphQLIntroduction to GraphQL
Introduction to GraphQL
 
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)
Build GraphQL APIs with Graphene (Big Mountain Data & Dev 2019)
 
Building Fullstack Serverless GraphQL APIs In The Cloud
Building Fullstack Serverless GraphQL APIs In The CloudBuilding Fullstack Serverless GraphQL APIs In The Cloud
Building Fullstack Serverless GraphQL APIs In The Cloud
 
Training Week: GraphQL 2022
Training Week: GraphQL 2022Training Week: GraphQL 2022
Training Week: GraphQL 2022
 
Green Custard Friday Talk 8: GraphQL
Green Custard Friday Talk 8: GraphQLGreen Custard Friday Talk 8: GraphQL
Green Custard Friday Talk 8: GraphQL
 
Introduction to Graph QL
Introduction to Graph QLIntroduction to Graph QL
Introduction to Graph QL
 
Tutorial: Building a GraphQL API in PHP
Tutorial: Building a GraphQL API in PHPTutorial: Building a GraphQL API in PHP
Tutorial: Building a GraphQL API in PHP
 
Getting Started with Spring for GraphQL
Getting Started with Spring for GraphQLGetting Started with Spring for GraphQL
Getting Started with Spring for GraphQL
 
Training Series: Build APIs with Neo4j GraphQL Library
Training Series: Build APIs with Neo4j GraphQL LibraryTraining Series: Build APIs with Neo4j GraphQL Library
Training Series: Build APIs with Neo4j GraphQL Library
 
REST vs GraphQL
REST vs GraphQLREST vs GraphQL
REST vs GraphQL
 
GraphQL (Graphene-Django)
GraphQL (Graphene-Django)GraphQL (Graphene-Django)
GraphQL (Graphene-Django)
 
Elixir absinthe-basics
Elixir absinthe-basicsElixir absinthe-basics
Elixir absinthe-basics
 
Attacking GraphQL
Attacking GraphQLAttacking GraphQL
Attacking GraphQL
 
GraphQL @ Manc.JS (March 2018)
GraphQL @ Manc.JS (March 2018)GraphQL @ Manc.JS (March 2018)
GraphQL @ Manc.JS (March 2018)
 
PHP, the GraphQL ecosystem and GraphQLite
PHP, the GraphQL ecosystem and GraphQLitePHP, the GraphQL ecosystem and GraphQLite
PHP, the GraphQL ecosystem and GraphQLite
 

Mais de GraphRM

A gentle introduction to random and strategic networks
A gentle introduction to random and strategic networksA gentle introduction to random and strategic networks
A gentle introduction to random and strategic networksGraphRM
 
How to leverage Kafka data streams with Neo4j
How to leverage Kafka data streams with Neo4jHow to leverage Kafka data streams with Neo4j
How to leverage Kafka data streams with Neo4jGraphRM
 
From zero to gremlin hero - Part I
From zero to gremlin hero - Part IFrom zero to gremlin hero - Part I
From zero to gremlin hero - Part IGraphRM
 
Topology Visualization at Sysdig
Topology Visualization at SysdigTopology Visualization at Sysdig
Topology Visualization at SysdigGraphRM
 
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...GraphRM
 
aRangodb, un package per l'utilizzo di ArangoDB con R
aRangodb, un package per l'utilizzo di ArangoDB con RaRangodb, un package per l'utilizzo di ArangoDB con R
aRangodb, un package per l'utilizzo di ArangoDB con RGraphRM
 
The power of the cosmos in a DB .... CosmosDB
The power of the cosmos in a DB .... CosmosDBThe power of the cosmos in a DB .... CosmosDB
The power of the cosmos in a DB .... CosmosDBGraphRM
 
OrientDB graph e l'importanza di una relazione mancante
OrientDB graph e l'importanza di una relazione mancanteOrientDB graph e l'importanza di una relazione mancante
OrientDB graph e l'importanza di una relazione mancanteGraphRM
 
Il "Knowledge Graph" della Pubblica Amministrazione Italiana
Il "Knowledge Graph" della Pubblica Amministrazione ItalianaIl "Knowledge Graph" della Pubblica Amministrazione Italiana
Il "Knowledge Graph" della Pubblica Amministrazione ItalianaGraphRM
 
Elastic loves Graphs
Elastic loves GraphsElastic loves Graphs
Elastic loves GraphsGraphRM
 
From text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge GraphsFrom text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge GraphsGraphRM
 
Graph analysis over relational database
Graph analysis over relational databaseGraph analysis over relational database
Graph analysis over relational databaseGraphRM
 
GraphRM - Introduzione al Graph modelling
GraphRM  - Introduzione al Graph modellingGraphRM  - Introduzione al Graph modelling
GraphRM - Introduzione al Graph modellingGraphRM
 
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018GraphRM
 

Mais de GraphRM (14)

A gentle introduction to random and strategic networks
A gentle introduction to random and strategic networksA gentle introduction to random and strategic networks
A gentle introduction to random and strategic networks
 
How to leverage Kafka data streams with Neo4j
How to leverage Kafka data streams with Neo4jHow to leverage Kafka data streams with Neo4j
How to leverage Kafka data streams with Neo4j
 
From zero to gremlin hero - Part I
From zero to gremlin hero - Part IFrom zero to gremlin hero - Part I
From zero to gremlin hero - Part I
 
Topology Visualization at Sysdig
Topology Visualization at SysdigTopology Visualization at Sysdig
Topology Visualization at Sysdig
 
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...
Tecniche per la Visualizzazione di Grafi di Grandi Dimensioni Basate sulla Co...
 
aRangodb, un package per l'utilizzo di ArangoDB con R
aRangodb, un package per l'utilizzo di ArangoDB con RaRangodb, un package per l'utilizzo di ArangoDB con R
aRangodb, un package per l'utilizzo di ArangoDB con R
 
The power of the cosmos in a DB .... CosmosDB
The power of the cosmos in a DB .... CosmosDBThe power of the cosmos in a DB .... CosmosDB
The power of the cosmos in a DB .... CosmosDB
 
OrientDB graph e l'importanza di una relazione mancante
OrientDB graph e l'importanza di una relazione mancanteOrientDB graph e l'importanza di una relazione mancante
OrientDB graph e l'importanza di una relazione mancante
 
Il "Knowledge Graph" della Pubblica Amministrazione Italiana
Il "Knowledge Graph" della Pubblica Amministrazione ItalianaIl "Knowledge Graph" della Pubblica Amministrazione Italiana
Il "Knowledge Graph" della Pubblica Amministrazione Italiana
 
Elastic loves Graphs
Elastic loves GraphsElastic loves Graphs
Elastic loves Graphs
 
From text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge GraphsFrom text to entities: Information Extraction in the Era of Knowledge Graphs
From text to entities: Information Extraction in the Era of Knowledge Graphs
 
Graph analysis over relational database
Graph analysis over relational databaseGraph analysis over relational database
Graph analysis over relational database
 
GraphRM - Introduzione al Graph modelling
GraphRM  - Introduzione al Graph modellingGraphRM  - Introduzione al Graph modelling
GraphRM - Introduzione al Graph modelling
 
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018
Costruiamo un motore di raccomandazione con Neo4J - Workshop 25/1/2018
 

Último

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdfChristopherTHyatt
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 

Último (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

GraphQL ♥︎ GraphDB

  • 1. GraphQL ♥ Graph Database 15/03/2018
  • 3. Agenda - GraphQL Introduction - GraphQL Schema Definition (Meetup) - Why GraphQL ♥ Graph Database? - Schema Impl with a GraphDB
  • 5. Let’s Talk About Rest first ● Resource Based ● HTTP Verbs ○ GET ○ PUT ○ PATCH ○ DELETE ○ POST Actions -> Verbs + Uris
  • 6. Meetup model with REST ● https://api.meetup.com/:urlname ● https://api.meetup.com/:urlname/members ● https://api.meetup.com/:urlname/events ● https://api.meetup.com/:urlname/events/:event_id/rsvp
  • 9. How Do we Handle That? GET /GraphRM?fields=topics
  • 10. …And What about Over-fetching? GET /GraphRM?only=id,name I need only those fields
  • 11. You will probably end up with some custom endpoints
  • 12. API Documentation ● How can i use those APIs ? ● What parameters this endpoint support? ● Is this parameter required? ● Swagger ● JSON Schema ● JSON:API ● API Blueprint Documentation should be good in order to let people use our APIs without headache
  • 13. Potential Problems ● Multiple Round trips ● Over/Under fetching ● Documentation
  • 14.
  • 15. What GraphQL IS NOT.. ● A query language for Graph Databases ● Database / Storage Engine ● A library ● It’s not language specific
  • 16. What Is IT ? GraphQL is a query language for APIs and a runtime for fulfilling those queries with your existing data. GraphQL provides a complete and understandable description of the data in your API, gives clients the power to ask for exactly what they need and nothing more, makes it easier to evolve APIs over time, and enables powerful developer tools.
  • 17. Just a spec ● A declarative query language ● A type system ● A runtime that fetch and mutate data
  • 20. How does it work ? ● The server describe what is possible (a type system) ● The client can asks exactly what data it requires ● The server then gives back results with the same shape as the query Power to the client
  • 21. Powerful Type System ● Hierarchical ● Strongly-Typed ● Self Documenting ● Enable Introspection ● Client-specified queries
  • 22. Types ● Objects ● Scalar ○ Boolean ○ Int ○ Float ○ String ○ Custom Types ● Enums ● Lists ● Unions ● Interfaces
  • 23. GraphQL Schema Language ● GraphQL type system ● Describes what data can be queried ● Language-agnostic
  • 27. … Enables Tools ● GraphiQL ● Documentation ● IDE plugins ● Code generation ● Client Side Validation ● …
  • 28. GraphQL Schema Definition (Meetup) ● Entity ○ User ○ Meetup ○ Tag ○ Event ● Query ○ meetupsByName ○ usersByName
  • 29. GraphQL Schema Definition (Meetup) Demo time! https://github.com/GraphRM/graphql-graphdb
  • 30. Why GraphQL ♥ Graph Database?
  • 31. A GraphQL query represents a description of a relationship: Why GraphQL ♥ Graph Database? Person “me” :id :name Person :name Person :name
  • 32. A GraphQL query represents a description of a relationship: Why GraphQL ♥ Graph Database? Person “me” :id :name Person :name Person :name Problem: ● For each Person the GraphQL reducer will go to the database and ask for data. ● This is known as the N+1 query problem. ● Which in turns mean poor performance
  • 33. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database? ● This could prevent the N+1 queries problem ● A GraphDB is designed to run traversals ● Bonus: if the schema is the same for both GraphQL and DB that is a huge win!
  • 34. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database?
  • 35. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database?
  • 36. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database? ● This is still a PoC but the idea is: ○ Parse the Schema and the query ○ Traverse the query and build a database query
  • 37. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database? This is not fully compatible yet but there are some PoC: ● GraphQL -> Neo4J Cypher: https://github.com/neo4j-graphql/neo4j-graphql-js ● GraphQL -> OrientDB Gremlin + MATCH https://github.com/kensho-technologies/graphql-compiler
  • 38. What if we could translate one GraphQL query to a single GraphDB query? Why GraphQL ♥ Graph Database? Demo time! https://github.com/GraphRM/graphql-graphdb
  • 40. Resources ● GraphQL: http://graphql.org/learn/ ● AST Explorer: https://astexplorer.net/ ● GRANDstack: https://grandstack.io/ ● GraphQL + OrientDB: https://blog.kensho.com/compiled-graphql-as-a-database-query-language-72e1 06844282 ● GraphQL + Neo4J: https://neo4j.com/developer/graphql/ ● Five common pitfalls with GraphQL and how Neo4J-GraphQL aims to solve them: https://blog.grandstack.io/five-common-graphql-problems-and-how-neo4j-graph ql-aims-to-solve-them-e9a8999c8d43