springboot整合neo4j

【Springboot集成Neo4j完整版教程】 【Springboot集成Neo4j完整版教程】本文展示了如何使用Neo4J和Spring Boot整合,如何在Spring Boot应用程序中使用Neo4J数据库来持久化数据、使用CQL语言进行高效的查询操作,并提供了一个非常简单的例子以演示如何使用Neo4J数据库。相信通过本文的学习,读者已经掌握了如何使用Neo4J和Spring Boot整合,并且具备将此应用于实际项目的能力。 阅读详情

springboot整合neo4j 执行指令

之前上网搜索配置都很凌乱,于是在 springboot neo4j文档 中摸索了下。
- pom配置

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-neo4j</artifactId>
        </dependency>
        <!-- add this dependency if you want to use the HTTP driver -->
        <dependency>
            <groupId>org.neo4j</groupId>
            <artifactId>neo4j-ogm-http-driver</artifactId>
            <version>3.0.1</version>
        </dependency>
  • application.properties
# 写入自己neo4j配置
spring.data.neo4j.uri=http://fp-bd13:7474
spring.data.neo4j.username=neo4j
spring.data.neo4j.password=admin
  • 实体Po
@Data //lombok注解
@NodeEntity
@ToString
public class Table {
    @Id
    @GeneratedValue
    private Long id;
    @Property
    private String name;
    @Property
    private String desc;
    @Property
    private String fields;
}
  • Dao

继承 Neo4jRepository 接口

@Repository
public interface TableDao extends Neo4jRepository<Table,Long> {
}
  • Service

注入Dao,如果注入neo4j的SessionFactory获取session可以用来执行cql命令。

@RestController
@RequestMapping("/v1/table")
public class TableService {

    @Autowired
    private SessionFactory sessionFactory;

    @Autowired
    TableDao tableDao;

    @RequestMapping("/create")
    public void create(@RequestBody Table table) {
        tableDao.save(table);
    }

    @RequestMapping("/executeCQL")
    public void executeCQL(String cypher){
        // cypher = "match (n: Table} ) delete n"
        sessionFactory.openSession().query(cypher,new HashMap<>());
    }
}
SpringBoot集成neo4j实战 图形数据库也被称为图形数据库管理系统(GDBMS),现发展比较成熟的图数据库有Neo4j、OracleNoSQL、OrientDB、HypherGraphDB和GraphBase等。随着社交、电商、金融、零售、物联网等行业的快速发展。现实社会织起了了一张庞大而复杂的关系网,传统数据库很难处理关系运算。大数据行业需要处理的数据之间的关系随数据量呈几何级数增长,急需一种支持海量复杂数据关系运算的数据库,图数据库应运而生。社交额域Facebook,Twitter,Linkedin用它来管理社交关系。... 阅读详情

相关推荐

毕设20200512 Spring Boot项目的Neo4j Session Factory配置

文章目录依赖 依赖 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-neo4j</artifactId> </dependency> 也许有人会说,这边要加嵌入式的neo4j的驱动依赖,或者http、bolt的驱动依赖。 其实在spring-boot-starter-data-ne

JayXu's Blog 1999

SpringBoot 整合 Neo4j

Java层角度操作 Neo4j 图形数据库,并整合 Springboot

Xiang想 2942

【Neo4j系列】Neo4j概念简介及整合SpringBoot

本文将针对Neo4j相关概念进行介绍,同时讲解Neo4j整合SpringBoot的详细步骤。

c18213590220的博客 2371

Spring Boot整合neo4j

Spring Boot整合neo4j

weixin_43618754的博客 5807

【微服务】springboot整合neo4j使用详解

springboot整合neo4j使用详解

congge_study的博客 7625

UE5.3.2 + VS2022社区版在Win11上的C++编译环境配置全解

Unreal Engine 5的C++开发依赖严格的工具链协同,其核心在于Visual Studio编译器版本、Windows SDK与引擎构建系统(UBT)的精准匹配。UE5.3.2强制要求MSVC v143.4(即VS2022 17.4+)及Windows 11 SDK 10.0.22621.0,任何偏差都会引发LNK2019链接失败、C1083头文件缺失或MSB8066构建中断等典型错误。该配置不仅关乎安装顺序,更涉及注册表清理、PATH环境变量、SDK路径注入与运行时DLL加载等底层机制。适用于Wi

weixin_33978722的博客 367

Spring Boot 整合 Neo4j

Neo4j 是一个高性能的 ​​,适用于存储和查询 ​​ 和 ​​ 的数据。本教程将带你从零开始,在 ​​ 项目中整合 ​​,并实现基本的 ​​ 操作。

weixin_52578852的博客 1872

【效率手册】Kylin-Desktop-V10-SP1 麒麟系统核心组件实战——从入门到精通的6个关键场景

本文针对Kylin-Desktop-V10-SP1麒麟系统用户,通过文件管理、系统监视、设置优化等6个核心场景实战,深度解析如何高效运用系统内置工具解决文件混乱、性能卡顿、外设驱动等实际问题,帮助用户从功能认知跃升至场景化应用,真正释放国产操作系统的生产力潜能。

weixin_29208327的博客 119

springBoot 与neo4j的简单整合

Neo4j简介 Neo4j是基于java语言实现的世界领先的图形数据库, 是一个高性能的图形存储,具有成熟和强大的数据库所需的所有功能,如友好的查询语言(Cypher)和ACID事务。对于许多应用程序,与关系数据库相比,Neo4j提供了数量级的性能优势。主要应用于图检索和关系计算。其优点在于: 节点没上线(3.0以后去掉了限制) 扩展性...

weixin_33953249的博客 1685

AD20丝印层导入图片logo保姆级教程(附黑白预览避坑技巧)

本文提供了一份详尽的AD20丝印层导入图片Logo的实战指南。核心在于将图片预处理为高质量的单色BMP位图,并独家分享了利用Windows画图工具进行“黑白预览”的关键技巧,以提前规避转换失真。教程涵盖了从脚本获取、图片处理、参数设置到生产规范的完整流程,帮助硬件工程师高效、准确地在PCB的Top Overlay层添加个性化标识。

weixin_29194255的博客 385

复信号的调制与解调(基带)

Digital modulation methods can be considered as digital-to-analog conversion and the corresponding demodulation or detection as analog-to-digital conversion. 数字调制可以看成是数字到模拟的变换,同样,数字解调也可以看作是模拟向数字的转换。

JonTargaryen的博客 1万+

SpringBoot整合Neo4j以及Docker部署Neo4j

docker部署neo4j,springboot整合neo4j

Huahua_student的博客 1536

AI Agent开发第85课-DeepSeek-OCR 安装全指南:从 Transformers 到 vLLM,手把手教你跑通企业级 OCR

本文系统讲解 DeepSeek-OCR 的两种部署方式——基于 Hugging Face Transformers 的标准推理与基于 vLLM 的高性能加速推理。详细说明 CUDA 与 PyTorch 版本匹配、环境验证、依赖安装等关键细节,并提供可直接运行的完整代码示例。无论你是单卡调试还是高并发服务部署,都能在这里找到清晰路径。

打造全国最全的AI Agent开发知识领域的博客 2542

Neo4j图数据库学习(二)——SpringBoot整合Neo4j

本文介绍如何通过SpringBoot整合Neo4j的方式,对图数据库进行简单的操作。Neo4j和SpringBoot的知识不再赘述。Neo4j图数据库学习(一)——初识CQL由于作者的水平非常有限,难免会出现错误,欢迎各位指正!假如您有任何想法,也欢迎交流!

bsefef的博客 1949

【NI Multisim 14.0原理图设计基础——元器件分类】

电阻(RESISTOR):该元器件栏中的电阻都是标称电阻,是根据真实电阻元器件而设计的,其电阻值不能改变。 排阻(RESISTOR PACK):相当于多个电阻并列封装在一个壳内,它们具有相同的阻值。 电位器(POTENTIOMETER):即可调电阻,可以通过键盘字母动态调节电阻,大写表示增加电阻值,小写表示减小电阻值,调节增量可以设置。 电容(CAPACITOR):所有电容都是无极性的,不能改变参数,没有考虑误差,也未考虑耐压大小。 电解电容器(CAP_ELECTROLIT):所有电容都是有极性的,“+”极

RL2698853114的博客 4万+

【精细解读】xapp585(多通道LVDS接口ADC)

xapp585的参考设计有Verilog和VHDL两种源码。

FPGA艺术家的博客 532

SpringBoot整合Neo4j案例源码

SpringBoot整合Neo4j案例源码 【下载地址】SpringBoot整合Neo4j案例源码 本仓库提供了一个SpringBoot整合Neo4j的案例源码,帮助开发者快速上手使用SpringBoot与Neo4j数据库进行开发。通过本案例,您可以学习如何在SpringBoot项目中集成Neo4j,并实现基本的CRUD...

gitblog_09750的博客 896

【服务器电源架构与关键技术发展趋势】AI数据中心迅猛发展,服务器电源如何演变?

功率级跃升:机柜功率从 100kW 向 1MW 级发展,供电架构采用 HVDC + 固态变压器(SST),省去传统 UPS、PFC 环节; 母线电压升级:从 48V 向 400V→800V 演进,配套 AI 电弧检测、智能运维解决高压安全与维护难题; 能效(PUE)提升:目标 PUE<1.3,通过液冷 CDU 替代传统风冷,可将 PUE 降至 1.16(传统 AI 集群 PUE 达 1.6); 拓扑控制复杂化:功率拓扑从单相→三相、单级→多交错结构,适配高功率需求; 安全维度扩展:新增网络安全防护需求。

昔时扬尘处 1450

SpringBoot整合Neo4j简单操作

SpringBoot整合Neo4j简单操作。

qq_43430966的博客 2203

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

neo4j springboot 日志_springBoot 与neo4j的简单整合

Neo4j简介Neo4j是基于java语言实现的世界领先的图形数据库, 是一个高性能的图形存储,具有成熟和强大的数据库所需的所有功能,如友好的查询语言(Cypher)和ACID事务。对于许多应用程序,与关系数据库相比,Neo4j提供了数量级的性能优势。主要应用于图检索和关系计算。其优点在于:节点没上线(3.0以后去掉了限制)扩展性很好,支持集群和企业版数据ETL有丰富的工具支持,自带GUI良好的W...

weixin_39848347的博客 337

efm32 入门.pdf

本PDF共计22页,介绍的是操作驱动API,下载与否自己斟酌。

SpringBoot整合Neo4j(SpringBoot+Mybatis+Druid+Neo4j)

前面几篇文章简单的描述了Neo4j的安装、配置及导数的内容,这篇就来写下实际项目中如何整合应用Neo4j。下面要整合的是SpringBoot+Mybatis+Druid+Neo4j这样的一个框架。废话不多说,直接开始吧(这里我用的是2018.1.8版本的IntelliJ IDEA、jdk1.8)。 第一步:创建一个SpringBoot的WebService项目。 打开IDEA点击Create New Project。 选择Spring Initializr,再点击Next下一步。 填写好项目

minantadd的博客 7285

Outlook Express 6 (OE6) for Win7/Win8/Win10

英文版 Outlook Express6.0, 兼容Win7/Win10/WinXP,解压就可用。

图数据库 Neo4j 学习之SpringBoot整合

相对于Java通过Neo4j驱动来连接Neo4j数据库操作来说,SpringBoot引入starter组件来操作Neo4j 简直要上天,简单易用。

qq_19283249的博客 3339
上一篇: Presto Error moving data files from hdfs
下一篇: Spark NoSuchMethodError
yyoc97
博客等级 码龄12年 272粉丝 91原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值