会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
为乐而来
我们不生产代码,我们只是搜索引擎的搬运工,纯天然的弱咸性代码,让你运用自如。
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
7
8
9
10
···
25
下一页
2020年6月24日
python运行的时候报错line 192, in _run_module_as_main return _run_code(code, main_globals, None,
摘要: 用的pytone3.8,很久没有搞python了,用vscode运行以前的py代码居然报错: Traceback (most recent call last): File "C:\Program Files (x86)\Python\Python38-32\lib\runpy.py", line
阅读全文
posted @ 2020-06-24 14:14 为乐而来
阅读(16548)
评论(1)
推荐(0)
2020年6月15日
java entity转js的json对象
摘要: 前后端分离开发时,有时候从entity实体中复制字段到前端要一个一个替换比较麻烦写了一个批量替换的方法 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Java entity to json</title> </head> <b
阅读全文
posted @ 2020-06-15 17:16 为乐而来
阅读(973)
评论(0)
推荐(0)
2020年6月3日
解决idea连接mysql连接失败Could not create connection to database server. Attempted reconnect 3 times. Giving up.
摘要: 如下图 解决办法: 在URL后面添加参数即可: ?useUnicode=true&characterEncoding=UTF-8&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=UTC
阅读全文
posted @ 2020-06-03 20:56 为乐而来
阅读(12525)
评论(0)
推荐(0)
2020年5月25日
Linux监控软件排行 CentOS 7上安装Munin监控 ntopng安装
摘要: Linux监控软件开源排行,根据Star数量来 软件名 开发语言 Star数量 github地址 说明 ntopng Lua/c++ 3.7K https://github.com/ntop/ntopng 安装简单,要安装Redis LibreNMS Php 2.1K https://github.
阅读全文
posted @ 2020-05-25 17:32 为乐而来
阅读(1159)
评论(0)
推荐(0)
2020年5月18日
解决hibernate项目添加集成jpa使用EntityManager时报错No qualifying bean of type 'javax.persistence.EntityManagerFactory' available: expected single matching bean but found 2: sessionFactory,entityManagerFactory
摘要: 项目本来使用的是SrpingMVC+Hibernate,想要加入Jpa到项目中,常用的功能没问题 但是在Service中要使用EntityManager如下 @PersistenceContext public EntityManager em;// 类似hibernate session //给子
阅读全文
posted @ 2020-05-18 13:25 为乐而来
阅读(4238)
评论(0)
推荐(0)
2020年5月13日
jpa could not initialize proxy [com.modelname#1] - no Session 解决办法
摘要: jpa测试Dao.getOne的时候报错could not initialize proxy [com.modelname#1] - no Session 测试代如下 @Test public void findOne_getOne() { System.out.println(" findPage
阅读全文
posted @ 2020-05-13 12:52 为乐而来
阅读(651)
评论(0)
推荐(0)
2020年5月12日
jpa 分页查询几种demo Example分页/ExampleMatcher/Specification分页/SQL分页
摘要: 以下都是基于spring-data-jpa2.1.8 1.单纯分页,没有条件 /*** * 直接用dao调用分页 */ @Test public void findPageDao1() { try { System.out.println(" findPage " ); //jpa 1.*写法 //
阅读全文
posted @ 2020-05-12 13:55 为乐而来
阅读(3265)
评论(0)
推荐(0)
2020年5月11日
jpa中PageRequest @Deprecated和Sort @Deprecated的最新使用方法
摘要: jpa2.0以下用 new PageRequest jpa2.0及以上由 PageRequest.of替代 jpa2.0以下new Sort jpa2.0及以上由 Sort.by 替代 这是对比图片: 以下是上面截图的代码: @Test public void now() { List<Sort.O
阅读全文
posted @ 2020-05-11 17:22 为乐而来
阅读(832)
评论(0)
推荐(0)
2020年5月8日
MinIO安装及使用教程(windows) 及java 上传 下载 windows minio 修改密码修改 MINIO_ACCESS_KEY minio开机启动
摘要: 1.下载安装地址(我下的是windows版本):https://min.io/download#/windows 2.新建一个目录存放minio文件,我建的文件名叫 D:\minioData,CMD进入刚刚下载的minio.exe所在目录, 直接在cmd下运行:minio.exe server D:
阅读全文
posted @ 2020-05-08 17:08 为乐而来
阅读(20904)
评论(0)
推荐(2)
CentOS下mysql忘记root密码解决办法,centOS7中Host is not allowed to connect
摘要: 1,停止mysql服务命令 systemctl stop mysqld 2,修改配置文件/etc/my.cnf 在[mysqld]下添加 skip-grant-tables 意思是忽略验证,保存并退出 3,启动Mysql命令 systemctl start mysqld 4,修改密码 执行命令:my
阅读全文
posted @ 2020-05-08 14:30 为乐而来
阅读(286)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
7
8
9
10
···
25
下一页
公告