This document discusses GraphQL and DGraph with GO. It begins by introducing GraphQL and some popular GraphQL implementations in GO like graphql-go. It then discusses DGraph, describing it as a distributed, high performance graph database written in GO. It provides examples of using the DGraph GO client to perform CRUD operations, querying for single and multiple objects, committing transactions, and more.
2017/9/7 db tech showcase Tokyo 2017(JPOUG in 15 minutes)にて発表した内容です。
SQL大量発行に伴う処理遅延は、ミッションクリティカルシステムでありがちな性能問題のひとつです。
SQLをまとめて発行したり、処理の多重度を上げることができれば高速化可能です。ですが・・・
AP設計に起因する性能問題のため、開発工程の終盤においては対処が難しいことが多々あります。
そのような状況において、どのような改善手段があるのか、Oracleを例に解説します。
2017/9/7 db tech showcase Tokyo 2017(JPOUG in 15 minutes)にて発表した内容です。
SQL大量発行に伴う処理遅延は、ミッションクリティカルシステムでありがちな性能問題のひとつです。
SQLをまとめて発行したり、処理の多重度を上げることができれば高速化可能です。ですが・・・
AP設計に起因する性能問題のため、開発工程の終盤においては対処が難しいことが多々あります。
そのような状況において、どのような改善手段があるのか、Oracleを例に解説します。
GraphQL and its schema as a universal layer for database accessConnected Data World
GraphQL is a query language mostly used to streamline access to REST APIs. It is seeing tremendous growth and adoption, in organizations like Airbnb, Coursera, Docker, GitHub, Twitter, Uber, and Facebook, where it was invented.
As REST APIs are proliferating, the promise of accessing them all through a single query language and hub, which is what GraphQL and GraphQL server implementations bring, is alluring.
A significant recent addition to GraphQL was SDL, its schema definition language. SDL enables developers to define a schema governing interaction with the back-end that GraphQL servers can then implement and enforce.
Prisma is a productized version of the data layer leveraging GraphQL to access any database. Prisma works with MySQL, Postgres, and MongoDB, and is adding to this list.
Prisma sees the GraphQL community really coming together around the idea of schema-first development, and wants to use GraphQL SDL as the foundation for all interfaces between systems.
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...Databricks
Graph data and graph analytics are increasingly important in data science and engineering. Cypher is an open language used for querying and updating graph databases and analytics platforms, which is now available in the Apache Spark environment. Neo4j Morpheus leverages the open source graph language project to integrate data from Neo4j operational graph databases with Hive and JDBC SQL data sources, using new Cypher features like the Property Graph Catalog, named graphs, graph projection, parameterized graph view functions, and graph/table views. Input and output graphs can be loaded and stored as structured collections of DataFrames with strong graph schemas to ensure data consistency and graph query optimization. Property graphs can also be analyzed and transformed using graph algorithms such as those in the GraphFrames project. Besides describing and demonstrating these capabilities, this talk also discusses the Spark Project Improvement Proposal to bring Cypher into Spark 3.0, and outlines current work to unify Cypher with other graph query languages to form a new ISO standard Graph Query Language.
Speakers: Alastair Green, Martin Junghanns
GraphQL is query language for APIs, but what are the advantages and how would one implement such in their microservices/APIs. In this session, I will go through the basics of GraphQL, different aspects of GraphQL and architecture of such APIs. How 4 different ways we can implement GraphQL for a Springboot microservice/API.
ScalaTo July 2019 - No more struggles with Apache Spark workloads in productionChetan Khatri
Scala Toronto July 2019 event at 500px.
Pure Functional API Integration
Apache Spark Internals tuning
Performance tuning
Query execution plan optimisation
Cats Effects for switching execution model runtime.
Discovery / experience with Monix, Scala Future.
GraphQL is query language for APIs, but what are the advantages and how would one implement such in their microservices/APIs. In this session, I will go through the basics of GraphQL, different aspects of GraphQL and architecture of such APIs. There will be a demo/live-coding on, how 4 different ways we can implement GraphQL for a Springboot microservice/API. Lots of examples, live coding and helpful comparison on structure, usage and implementations of GraphQL in Springboot & Java world.
Remember the last time you tried to write a MapReduce job (obviously something non trivial than a word count)? It sure did the work, but has lot of pain points from getting an idea to implement it in terms of map reduce. Did you wonder how life will be much simple if you had to code like doing collection operations and hence being transparent* to its distributed nature? Did you want/hope for more performant/low latency jobs? Well, seems like you are in luck.
In this talk, we will be covering a different way to do MapReduce kind of operations without being just limited to map and reduce, yes, we will be talking about Apache Spark. We will compare and contrast Spark programming model with Map Reduce. We will see where it shines, and why to use it, how to use it. We’ll be covering aspects like testability, maintainability, conciseness of the code, and some features like iterative processing, optional in-memory caching and others. We will see how Spark, being just a cluster computing engine, abstracts the underlying distributed storage, and cluster management aspects, giving us a uniform interface to consume/process/query the data. We will explore the basic abstraction of RDD which gives us so many awesome features making Apache Spark a very good choice for your big data applications. We will see this through some non trivial code examples.
Session at the IndicThreads.com Confence held in Pune, India on 27-28 Feb 2015
http://www.indicthreads.com
http://pune15.indicthreads.com
GraphQL across the stack: How everything fits togetherSashko Stubailo
My talk from GraphQL Summit 2017!
In this talk, I talk about a future for GraphQL which builds on the idea that GraphQL enables lots of tools to work together seamlessly across the stack. I present this through the lens of 3 examples: Caching, performance tracing, and schema stitching.
Stay tuned for the video recording from GraphQL Summit!
GraphQL is a syntax that describes how to ask for data, and is generally used to load data from a server to a client. GraphQL has three main characteristics:
It lets the client specify exactly what data it needs.
It makes it easier to aggregate data from multiple sources.
It uses a type system to describe data.
GraphRAG is All You need? LLM & Knowledge GraphGuy Korland
Guy Korland, CEO and Co-founder of FalkorDB, will review two articles on the integration of language models with knowledge graphs.
1. Unifying Large Language Models and Knowledge Graphs: A Roadmap.
https://arxiv.org/abs/2306.08302
2. Microsoft Research's GraphRAG paper and a review paper on various uses of knowledge graphs:
https://www.microsoft.com/en-us/research/blog/graphrag-unlocking-llm-discovery-on-narrative-private-data/
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Let's dive deeper into the world of ODC! Ricardo Alves (OutSystems) will join us to tell all about the new Data Fabric. After that, Sezen de Bruijn (OutSystems) will get into the details on how to best design a sturdy architecture within ODC.
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...James Anderson
Effective Application Security in Software Delivery lifecycle using Deployment Firewall and DBOM
The modern software delivery process (or the CI/CD process) includes many tools, distributed teams, open-source code, and cloud platforms. Constant focus on speed to release software to market, along with the traditional slow and manual security checks has caused gaps in continuous security as an important piece in the software supply chain. Today organizations feel more susceptible to external and internal cyber threats due to the vast attack surface in their applications supply chain and the lack of end-to-end governance and risk management.
The software team must secure its software delivery process to avoid vulnerability and security breaches. This needs to be achieved with existing tool chains and without extensive rework of the delivery processes. This talk will present strategies and techniques for providing visibility into the true risk of the existing vulnerabilities, preventing the introduction of security issues in the software, resolving vulnerabilities in production environments quickly, and capturing the deployment bill of materials (DBOM).
Speakers:
Bob Boule
Robert Boule is a technology enthusiast with PASSION for technology and making things work along with a knack for helping others understand how things work. He comes with around 20 years of solution engineering experience in application security, software continuous delivery, and SaaS platforms. He is known for his dynamic presentations in CI/CD and application security integrated in software delivery lifecycle.
Gopinath Rebala
Gopinath Rebala is the CTO of OpsMx, where he has overall responsibility for the machine learning and data processing architectures for Secure Software Delivery. Gopi also has a strong connection with our customers, leading design and architecture for strategic implementations. Gopi is a frequent speaker and well-known leader in continuous delivery and integrating security into software delivery.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
2. James tan
@ Okestra Systems Sdn Bhd | https://okestra.co/ | james@okestra.co | 0123221812
2
Workflow management simplified
Let’s make GO fun!
With AI (soon)
3. What is GraphQL?
GraphQL is a query language for APIs and a runtime for fulfilling those queries
with your existing data.
3
7. Multiple Round
Trip
7
● fetch /pages/1
● fetch /comments?pageID=1
● fetch /users/2
query page($id: Int) {
page(ID: $id) {
title
description
comments {
id
message
created_by {
id
name
}
}
}
}
REST:
GraphQL:
8. Multiple Round
Trip
8
● fetch /pages/1
● fetch /comments?pageID=1
● fetch /users/2
query page($id: Int) {
page(ID: $id) {
title
description
comments {
id
message
created_by {
id
name
}
}
}
announcements() {
edges {
node: {
id
title
message
}
}
}
REST:
GraphQL:
9. Over fetching data
9
● Frontend: fetch /pages
● Admin: fetch /pages
Frontend:
Admin:
title date
description
title date
description
...
ID title Created by Created on Published
1 Title here ... ... Yes
2 comments
5 comments
[
{ id: 1, title: “title”,
description: “...”,
created_at: “...”,
created_by: { name: “...” },
Comments_count: 2
}, …
]
REST Frontend & admin:
10. Over fetching data
10
Frontend:
Admin:
title date
description
title date
description
...
ID title Created by Created on Published
1 Title here ... ... Yes
2 comments
5 comments
query page($id: Int) {
page(ID: $id) {
title
description
Comment_count
…
}}
GraphQL frontend:
query page($id: Int) {
page(ID: $id) {
Title
…
}}
GraphQL admin:
11. Schema Documentation
11
Allow API Discovery and exploration
REST:
schema {
query: Query
mutation: Mutation
}
type Query {
user(email: String!): User
users(first: Int, after: String): UsersConnection!
}
type Mutation {
createUser(email: String!, password: String!): User
}
12. Implementing GraphQL
● graphql-go: An implementation of GraphQL for Go / Golang.
● graph-gophers/graphql-go: An active implementation of GraphQL in Golang (was
https://github.com/graph-gophers/graphql-go).
● GQLGen - Go generate based graphql server library.
● graphql-relay-go: A Go/Golang library to help construct a graphql-go server supporting
react-relay.
● machinebox/graphql: An elegant low-level HTTP client for GraphQL.
● samsarahq/thunder: A GraphQL implementation with easy schema building, live queries,
and batching
12
https://graphql.org/code/#go
13. Graphql-go
● minimal API
● support for context.Context
● support for the OpenTracing standard
● schema type-checking against resolvers
● resolvers are matched to the schema based on method sets (can resolve a GraphQL schema with a Go
interface or Go struct).
● handles panics in resolvers
● parallel execution of resolvers
● Subscriptions
https://github.com/graph-gophers/graphql-go
13
24. What is DGraph?
24
Dgraph is a distributed, low-latency, high throughput graph database, written in Go. It puts a lot of emphasis on good
design, concurrency and minimizing network calls required to execute a query in a distributed environment.
Why build Dgraph?
We think graph databases are currently second class citizens. They are not considered mature enough to be run as the
sole database, and get run alongside other SQL/NoSQL databases. Also, we’re not happy with the design decisions of
existing graph databases, which are either non-native or non-distributed, don’t manage underlying data or suffer from
performance issues.
Is Dgraph production ready?
We recommend Dgraph to be used in production at companies.
https://dgraph.io/
26. What is Graph database?
26
What is Graph?
A graph is composed of two elements: a node and a relationship.
Each node represents an entity (a person, place, thing, category or other piece of data), and each relationship
represents how two nodes are associated. This general-purpose structure allows you to model all kinds of
scenarios – from a system of roads, to a network of devices, to a population’s medical history or anything else
defined by relationships.
source: https://neo4j.com/why-graph-databases/
27. What is Graph database?
27
A graph database is an online database management system with Create, Read, Update and Delete (CRUD)
operations working on a graph data model.
source: https://neo4j.com/why-graph-databases/
29. Performance
Example SQL with “Join”s
SELECT 'paper_review'::text AS type, paper_reviews.id, paper_reviews.user_id, concat_ws(' '::text, users.first_name, users.last_name) AS
user_full_name, users.title AS user_title, users.photo AS user_photo, users.organization AS user_organization, users.username,
paper_reviews.paper_id, NULL::character varying AS language_framework, NULL::text AS performance_description, paper_reviews.score_tech,
paper_reviews.score_original,
( SELECT count(comments.id) AS count FROM public.comments WHERE ((comments.source_id = paper_reviews.id) AND (comments.vote = 1))) AS
likes_count,
( SELECT count(comments.id) AS count FROM public.comments WHERE ((comments.source_id = paper_reviews.id) AND (comments.vote = 0))) AS
comments_count FROM ((public.paper_reviews LEFT JOIN public.papers ON ((paper_reviews.paper_id = papers.id))) LEFT JOIN public.users ON
((paper_reviews.user_id = users.id)))
UNION SELECT 'paper_code'::text AS type, paper_codes.id, paper_codes.user_id, concat_ws(' '::text, users.first_name, users.last_name) AS
user_full_name, users.title AS user_title, ...
Why Graph database?
29
31. Flexibility
SQL based:
More joins!, more indexing, more optimisations, more group by OR more sub select, or refactor
NoSQL based:
More round trip for additional collection, more indexing
GraphDB
Add relation, add to graphql query, more indexing (for non relation field)
Why Graph database?
31
33. DGraph Setup
● Zero node: controls the Dgraph cluster, assigns servers to a group and re-balances data between server
groups
● Alpha node: hosts predicates and indexes
● Ratel: UI to run queries, mutations & altering schema (alike pgadmin)
https://docs.dgraph.io/get-started/
https://tour.dgraph.io/intro/1/
https://gist.github.com/u007/f47f9e42ae4f7a94b29c542955d698bc - docker-compose example
33