自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

zx20110729的博客

给时光以生命而不是给生命以时光

  • 博客(9)
  • 资源 (6)
  • 收藏
  • 关注

原创 Mybatis的mapper-locations配置多个mapper路径

一、 在spring中使用在创建SqlSessionFactoryBean中指定参数,代码如下: @Bean public SqlSessionFactoryBean sqlSessionFactoryBean(DataSource dataSource) throws IOException { SqlSessionFactoryBean bean = new SqlSessionFactoryBean(); ResourcePatternResol

2022-04-10 16:37:07 25946

原创 git命令别名配置

配置文件路径mac下路径为/Users/xxx/.gitconfig配置文件内容[user] name = xxx email = xxx@csdn.net[alias] st = status s = status co = checkout ci = commit cm = commit -m pl = pull ps = push br = branch re = rebase df = dif

2021-10-21 17:27:01 118

原创 Redis集群本地搭建-MAC

1、安装redisbrew install redis安装后的目录在/opt/homebrew/celler/redis配置文件在 /opt/homebrew/etc下面2、修改配置文件此处根据redis.conf文件复制出4个配置文件,3个主节点,1个从节点。修改端口号 port ,分别为7000、7001、7002、7003修改cluster-enabled为yes修改rdb保存目录为对应的端口号,dir /opt/homebrew/var/db/redis/redis-7000

2021-09-08 15:32:33 262

原创 Redis集群中给节点批量指定slot脚本

Redis集群中给节点批量指定slot脚本#!/bin/sh# 起始槽begin_slot=$1# 终点槽end_slot=$2# ipm_host=$3# 端口m_port=$4for((i=$begin_slot;i<=$end_slot;i++));do m_slot="${m_slot} ${i}"doneecho “add slots from ${begin_slot} to ${end_slot}!”redis-cli -h ${m_host} -p

2021-09-07 11:46:11 464 1

原创 继续前行

We are all in the gutter, but some of us are looking at the stars. 我们都生活在阴沟里,但仍有人仰望星空。王尔德 《温德米尔夫人的扇子》

2021-02-22 15:52:37 61

原创 IDEA启动项目时Command line is too long解决方案

Command line is too longidea启动项目时报Error running… Command line is too long…解决方案:在该项目文件夹.idea/workspace.xml中找到节点,添加如下配置即可。

2020-12-16 14:41:14 150

原创 MessageFormat格式化数值类型问题

在使用java.text.MessageFormat工具类进行格式化字符串时,应当注意在使用数值型参数替换占位符时,要将数值型参数转换为字符串,否则有可能产生与预期不符的字符串。增加英文逗号 如下示例 id,id2,id3,id4,id5丢失精度 如下示例 id2,id4,id5public static void main(String[] args){ int id = 123456; float id2 = 123456.789012F; long id3 = 123

2020-12-02 15:17:06 820

原创 使用BigInteger添加和校验权限

public static void main(String[] args) throws ParseException { int[] rights = {1, 2, 3, 4, 5, 6, 7, 8}; BigInteger sum = sumRights(rights); boolean flag = testRights(sum,9); System.out

2020-03-21 16:18:11 135

原创 Idea 终端打印的日志中文乱码

问题描述:windows环境,Idea中新建了一个简单的java应用,运行main方法时,控制台打印的中文字符乱码。如下图(改正后的结果):解决方法:点击Help按钮,选择Edit Custom VM Options...,在打开的vmoptions文件中新增一行“-Dfile.encoding=UTF-8”。重启Idea之后即可正常显示中文字符。...

2020-03-21 16:15:22 1042 2

SSM三大框架整合详细教程

Spring+SpringMVC+MyBatis三大框架整合详细教程

2016-12-09

深入JAVA虚拟机第二版

深入JAVA虚拟机第二版

2016-12-09

Spring框架入门教程

Spring框架入门教程

2016-12-09

Java23种设计模式

Java23种设计模式

2016-12-08

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除