- 博客(36)
- 收藏
- 关注
原创 mac上虚拟机上的Redis连接不上报错Could not get a resource from the pool; nested exception
本人用的window虚拟机1.检查yml配置文件是否正确2.用命令ping IP+redis端口(Mac命令是 nc -vz -w 2 10.211.44.6 6379 windows自己百度)3.如果ping不通IP+端口,关闭防火墙、开放端口 windows是在控制面板 - 系统和安全 - 高级设置 -入站规则 -新建规则****4.修改config配置文件降build 修改成 bind 0.0.0.05.如果还是不行,那就将springboot yml配置文件后缀改成yaml。
2023-02-23 01:05:32
695
原创 java.lang.IllegalMonitorStateException
一开始代码 代码会抛出异常java.lang.IllegalMonitorStateException。解决:只需要将tasks.notifyAll();放到synchronized代码块中执行。我的问题是 没有将 notifyAll放到synchronized代码块中。
2023-01-04 23:03:01
208
原创 解决Error:Kotlin: Module was compiled with an incompatible version of Kotlin
Error:Kotlin: Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.5.1, expected version is 1.1.13.
2022-10-17 22:14:20
786
原创 解决 centos 7 eans33 网络
查看IP地址 :ifconfig 输出的 ens33:看不到 inet *** netmask 255.255.255.0。最后在查看ifconfig,在到windows ping 一下 ip。修改文件 ifcfg-ens33 将。
2022-09-04 02:23:06
1230
原创 Method breakpoints may dramatically slow down debugging 项目启动不了
解决 取消断点就行了。
2022-08-04 15:26:44
112
原创 Optional long parameter ‘PactId‘ is present but cannot be translated into a null value due to being
不能为null值将long接收转成Long。
2022-07-20 10:03:17
407
原创 Row was updated or deleted by another transaction or unsaved-value mapping was incorrect解决
我的问题处在,子对象里面fk不为0jpa会报Rowwasupdatedordeletedbyanothertransactionorunsaved-valuemappingwasincorrect。Rowwasupdatedordeletedbyanothertransactionorunsaved-valuemappingwasincorrect记录报错。使用jpa进行update时错误。将jpa子对象fk置0。下面继承自己封装的。......
2022-07-19 16:06:17
1031
原创 with identifier [6854395]: optimistic locking failed; nested exception is org.hibernate.StaleObjectS
with identifier [6854395]: optimistic locking failed; nested exception is org.hibernate.StaleObjectStateException:我这里的原因是 version 版本号在数据库为null
2022-07-12 09:52:12
403
原创 nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet
nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet往下看具体日志:我这里是标识无效,表示数据库没有这个字段 或者映射字段失败java.sql.SQLSyntaxErrorException: ORA-00904: \"POLICYINTE3_\".\"VERSION\": 标识符无效\n\r\n\tat oracle.jdbc.driver.T4CTTIoer11..
2022-05-10 10:31:58
1828
原创 Error running ‘StartBasicApp‘: Command line is too long. Shorten command line for StartBasicApp or a
<component name="PropertiesComponent"> <property name="dynamic.classpath" value="true"/>
2022-04-29 10:44:40
126
原创 小程序使用内嵌页面https请求不进去web-view组件实现小程序内嵌网页
小程序使用内嵌页面https请求不进去web-view组件实现小程序内嵌网页
2022-04-21 10:38:48
322
原创 linux jdk.18 安装
jdk1.8下载1. mkdir /usr/local/java2. tar -zxvf jdk-18_linux-x64_bin.tar.gz 3. vim /etc/profile 配置环境变量export JAVA_HOME=/usr/local/java/jdk-18export JRE_HOME=${JAVA_HOME}/jreexport CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/libexport PATH=$PATH:$JAVA_HOME
2022-03-27 00:20:08
3626
原创 java获取当前日期 前后 几个月的 日期期间 往前 2个月 往后 2个月
java获取当前日期 前后 几个月的 日期期间需要原因 返回的String 格式private Map<String,String> getDuringDate(){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd"); Date date = new Date(); String returnEndDate = simpleDateFormat.form
2022-03-25 18:17:12
2336
原创 Incorrect string value: ‘\xE7\xA8\x8B\xE5\xBA\x8F...‘ for column ‘course‘ at row 1 插入中文错误
Incorrect string value: ‘\xE7\xA8\x8B\xE5\xBA\x8F…’ for column ‘course’ at row 1 插入中文错误原因 数据库表没有设置utf-8 或 字段不为 utf-8DROP TABLE IF EXISTS xquark_twitter_market_audits;DROP TABLE IF EXISTS xquark_twitter_market_audits;CREATE TABLE xquark_twitter_market_a
2022-03-17 14:50:17
963
原创 Creating Server TCP listening socket *:6379: bind: No error
Creating Server TCP listening socket *:6379: bind: No error
2022-03-05 12:52:24
358
原创 Process ‘command ‘C:/Program Files/Java/jdk1.8.0_192/bin/java.exe‘‘ finished with non-zero exit valu
Process ‘command ‘C:/Program Files/Java/jdk1.8.0_192/bin/java.exe’’ finished with non-zero exit value 1解决
2022-02-14 11:56:27
5941
原创 springboot错误: 找不到或无法加载主类
springboot错误: 找不到或无法加载主类在网上找到了不少,都没解决这个问题!1.配置jdk不要有特殊符号,路径中文2.配置的gradle和maven 同 jdk一样3项目路径不要中文修改完成后 解决
2021-12-29 10:05:15
393
原创 获取当前月的 下一个月1号
获取当前月的 下一个月1号 private static Date TimeTools(Date date) throws ParseException { Calendar calendar = Calendar.getInstance();//日历对象 calendar.setTime(date); int year = calendar.get(Calendar.YEAR); //获取年 int month = calendar.ge
2021-12-16 17:42:12
877
原创 Linux安装redis6
1.使用 wget 下载 :wget http://download.redis.io/releases/redis-6.0.6.tar.gz2.安装 gccsudo yum -y install gcc automake autoconf libtool make2.解压 tar -zxvf redis-6.0.6.tar.gz3.cd 进入redis目录执行 mark(将redis 进行编译成C的文件 然后执行 make install进行安装) 命令gcc版本过低 进行升级yum
2021-07-11 16:47:15
125
原创 POI导出功能exel
导入依赖 <!--poi 03版本exel 后缀。xls xml--> <dependency> <groupId>org.apache.poi</groupId> <artifactId>poi</artifactId> <version>3.17</version> </dependency>
2021-06-12 20:37:05
125
原创 JAVA时间工具类
JAVA时间类型转换 时间搓转Date Stirng转Datepackage com.example.demo.util;import cn.hutool.core.date.DateUtil;import java.text.ParseException;import java.text.ParsePosition;import java.text.SimpleDateFormat;import java.time.LocalDateTime;import java.util.Date;
2021-05-28 16:18:11
172
原创 Error creating bean with name ‘marketCluesController‘: Unsatisfied dependency expressed through fiel
忘记实service了Error creating bean with name 'marketCluesController': Unsatisfied dependency expressed through field 'marketCluesPlanService'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'me
2021-05-25 10:54:57
192
原创 Error:java: Can‘t generate mapping method with primitive return type.
Spring项目中使用了JPA以及Mybatis–mapper文件注解引错包导致编译错误错误导入 jpaimport org.mapstruct.Mapper;正确导入 mybatisPlusimport org.apache.ibatis.annotations.Mapper;
2021-05-24 11:48:57
9927
22
原创 oracler最近一周的数据
最近 一周查询最近一周数据SELECT * FROM DATA_PRESCRIPTION_DETAIL1 WHERE NEW_CREATION_TIME(T_RKSJ,'YYYY-MM-DD')=NEW_CREATION_TIME(SYSDATE,'YYYY-MM-DD')查询今天数据SELECT * FROM DATA_PRESCRIPTION_DETAIL1 WHERE NEW_CREATION_TIME(T_RKSJ,'YYYY-MM-DD')=NEW_CREATION_TIME(SYSDA
2021-05-24 11:28:36
1367
原创 文件上传到本地tomcat服务器 或者项目部署服务器,前端根据ip回显图片
下载一个tomcat,tomcat需要将包创建到 webapps下,项目部署服务器随便编写工具类UploadUtilpublic class UploadUtil { /**照片保存地址*/ private static final String BASE_PATH="D:/apache-tomcat-8.5.65-windows-x64/apache-tomcat-8.5.65/webapps/upload_img/"; /**服务器 图片访问*/ private
2021-05-24 01:11:50
500
原创 冒泡排序
冒泡排序思想:通过对待排序,序列从前向后,一次比较相邻元素的排序码,若发现逆 序则交换,排序码较大的元素,从前往后移 /** * 冒泡排序 * 思想,通过对待排序,序列从前向后,一次比较相邻元素的排序码, * 若发现逆序则交换,排序码较大的元素,从前往后移 */ @Test public void bubbleSort(){ int [] array1=new int[]{3,4,7,5,22,33,18,1
2021-05-24 00:51:16
108
原创 二分法查找
二分法查找:也称折半查找,前台数组必须有序/** * 二分法查找 :前提必须有序 */ @Test public void arrayBinarySearch(){ int [] array1=new int[]{-40,10,20,30,40,50,60,70,80,90}; int dest=100; int head=0;//初始索引 int end=array1.length-1;//初始.
2021-05-23 23:37:00
176
原创 controller.ActivityHistoryController.delActivityHistory(java.util.List<java.lang.Long>)
@GetMapping("/del")@ApiOperation("删除") public R delActivityHistory( List<Long> id){ /*逻辑删除*/ activityHistoryService.removeByIds(id); return R.ok(); }报错org.springframework.http.converter.HttpMessageNotReadableExcept
2021-04-16 11:10:20
134
原创 mybatis-plues .xml ava.sql.SQLException: Parameter index out of range (2 >;参数个数,为1)。
Caused by: org.apache.ibatis.type.TypeException: Error setting non null for parameter #2 with JdbcType null . Try setting a different JdbcType for this parameter or a different configuration property. Cause: java.sql.SQLException: Parameter index out of ra
2021-04-16 10:31:16
205
原创 前台传入 时间类型 2021-04-16T02:07:21.729Z 后端接收 数据类型为 date 为null
com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type java.util.Date from String “2021-04-16T02:07:21.729Z”: not a valid representation (error: Failed to parse Date value ‘2021-04-16T02:07:21.729Z’: Unparseable date: “
2021-04-16 10:19:49
716
原创 git上传到码云
第一步:在码云上新建仓库,找到要上传的文件 右击 gitbase打开 git创亏输入命令1.git config --global user.name “昵称”2.git config --global user.email “邮箱”3.git init 初始化仓库4.git add . 将文件添加到暂存区里5.git commit -m ‘描述内容’6.git remote add origin 仓库地址7.git push -u origin master 完成...
2021-03-28 19:12:38
151
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人