当前位置:网站首页>Integration of ongdb graph database and spark
Integration of ongdb graph database and spark
2022-07-04 16:40:00 【Ma Chao's blog】
Quickly explore graph data and graph calculation
Graph computing is the study of anything in the objective world and the relationship between things , Make a complete description of it 、 A technique of calculation and analysis . Graph computation depends on the underlying graph data model , Calculate and analyze on the basis of graph data model Spark Is a very popular and mature and stable computing engine . The following article starts from ONgDB And Spark Start of integration 【 Use TensorFlow The scheme of analyzing graph data with equal depth learning framework is beyond the scope of this paper , Only from the field of graph database Spark The integration of is a popular solution , You can do some calculation and pre training of basic map data and submit it to TensorFlow】, Introduce the specific integration implementation scheme . Downloading the source code of the case project can help novices quickly start exploring , No need to step on the pit . The general process is first Spark Cluster integration diagram database plug-in , Then use specific API Build graph data analysis code .
stay Spark Cluster installation neo4j-spark plug-in unit
- Download components
https://github.com/ongdb-contrib/neo4j-spark-connector/releases/tag/2.4.1-M1
- Download components on spark Installation directory jars Folder
E:\software\ongdb-spark\spark-2.4.0-bin-hadoop2.7\jars
The basic component depends on information
- Version information
Spark 2.4.0 http://archive.apache.org/dist/spark/spark-2.4.0/
ONgDB 3.5.x
Neo4j-Java-Driver 1.7.5
Scala 2.11
JDK 1.8
hadoop-2.7.7
https://mirrors.tuna.tsinghua.edu.cn/apache/hadoop/common/
neo4j-spark-connector-full-2.4.1-M1 https://github.com/neo4j-contrib/neo4j-spark-connector
- Download the installation package for
hadoop-2.7.7
spark-2.4.0-bin-hadoop2.7
winutils
neo4j-spark-connector-full-2.4.1-M1 【 hold jar Put the bag in spark/jars Folder 】
scala-2.11.12
Create test data
UNWIND range(1,100) as id
CREATE (p:Person {id:id}) WITH collect(p) as people
UNWIND people as p1
UNWIND range(1,10) as friend
WITH p1, people[(p1.id + friend) % size(people)] as p2
CREATE (p1)-[:KNOWS {years: abs(p2.id - p2.id)}]->(p2)
FOREACH (x in range(1,1000000) | CREATE (:Person {name:"name"+x, age: x%100}));
UNWIND range(1,1000000) as x
MATCH (n),(m) WHERE id(n) = x AND id(m)=toInt(rand()*1000000)
CREATE (n)-[:KNOWS]->(m);
remarks
- Case project 【 To avoid stepping on this under the pit Java-Scala The mixed case project can be referred to 】
https://github.com/ongdb-contrib/ongdb-spark-java-scala-example
If there is a problem downloading the dependent package, please check whether the following website can be downloaded normally Spark dependent JAR package
http://dl.bintray.com/spark-packages/maven
- Screenshot of case project 【 Start locally before use Spark】
- Please read the original text for the installation of relevant components and other references
边栏推荐
- %F format character
- Redis' optimistic lock and pessimistic lock for solving transaction conflicts
- Sql实现Split
- Function test - knowledge points and common interview questions
- Research Report on surgical otorhinolaryngology equipment industry - market status analysis and development prospect prediction
- China's roof ladder market trend report, technological innovation and market forecast
- [North Asia data recovery] data recovery case of database data loss caused by HP DL380 server RAID disk failure
- Communication mode based on stm32f1 single chip microcomputer
- ~89 deformation translation
- 同构图与异构图CYPHER-TASK设计与TASK锁机制
猜你喜欢
Detailed process of DC-2 range construction and penetration practice (DC range Series)
What is torch NN?
《吐血整理》保姆级系列教程-玩转Fiddler抓包教程(2)-初识Fiddler让你理性认识一下
[native JS] optimized text rotation effect
The new generation of domestic ORM framework sagacity sqltoy-5.1.25 release
Stress, anxiety or depression? Correct diagnosis and retreatment
Software Engineer vs Hardware Engineer
Vscode prompt Please install clang or check configuration 'clang executable‘
[North Asia data recovery] a database data recovery case where the partition where the database is located is unrecognized due to the RAID disk failure of HP DL380 server
[hcie TAC] question 5 - 1
随机推荐
Will the memory of ParticleSystem be affected by maxparticles
Practice: fabric user certificate revocation operation process
Change the mouse pointer on ngclick - change the mouse pointer on ngclick
Selenium element interaction
Application of clock wheel in RPC
话里话外:流程图绘制初级:六大常见错误
多年锤炼,迈向Kata 3.0 !走进开箱即用的安全容器体验之旅| 龙蜥技术
System. Currenttimemillis() and system Nanotime (), which is faster? Don't use it wrong!
The four most common errors when using pytorch
Scientific research cartoon | what else to do after connecting with the subjects?
Anta is actually a technology company? These operations fool netizens
Digital recognition system based on OpenCV
Stress, anxiety or depression? Correct diagnosis and retreatment
Lv166 turned over
[hcie TAC] question 5 - 1
Four point probe Industry Research Report - market status analysis and development prospect prediction
Hair and fuzz interceptor Industry Research Report - market status analysis and development prospect forecast
Final consistency of MESI cache in CPU -- why does CPU need cache
Hair growth shampoo industry Research Report - market status analysis and development prospect forecast
Opencv learning -- geometric transformation of image processing