- 博客(114)
- 资源 (5)
- 收藏
- 关注
原创 Nginx异常信息:forbidden (13: Permission denied)
Nginx 异常:13: Permission denied
2025-02-12 10:28:28
280
原创 network: error getting ClusterInformation: connection is unauthorized: Unauthorized
networkPlugin cni failed to teardown pod "direct-rent-front-b59b57859-bc5fz_pre-cgr" network: error getting ClusterInformation: connection is unauthorized: Unauthorized]
2024-09-14 16:04:36
912
1
原创 Jenkins 构建后操作(Send build artifacts over SSH)
Jenkins中在Send build artifacts over SSH中的注意事项
2024-09-11 09:57:57
1758
原创 Rabbit MQ和Kafka的区别
优点: 提供丰富的消息路由功能,适合复杂的消息传递和任务处理,支持多种消息传递模式,适合需要低延迟和高可靠性的场景。缺点: 吞吐量和扩展性相对较低,不适合大规模数据流处理。
2024-06-13 10:37:21
1936
5
原创 【 -bash: /usr/bin/id: 参数列表过长】
/etc/profile.d/colorgrep.sh:行3: /usr/libexec/grepconf.sh: 参数列表过长/etc/profile.d/vim.sh:行3: /usr/bin/id: 参数列表过长/etc/profile.d/vim.sh: 第 4 行:[: : 期待整数表达式/etc/profile:行31: /usr/bin/id: 参数列表过长
2023-07-12 10:44:58
2363
原创 Mac m1 pro启动 UTM 提示异常:qemu-x86_64-softmmu: -netdev vmnet-bridged,id=net0,ifname=3: unsupported ifnam
Mac m1 pro启动 UTM 异常
2022-07-27 16:47:34
945
原创 重温win 10安装(这么久没安装了,TMD连安装一个window都安装了我这么久。。)
需要一个8G+的优盘需要一台正常的电脑(用于制作微PE辅助)我首先参考了一下B站 UP主 的视频采用的是微PE辅助安装在MSDN上面下载了win10的ISO镜像(比较推荐去这下载window系统)我这次安装的是联想笔记本电脑(其他的也类似)上面的准备条件都充足的情况下可以进行下面的操作流程:6. 先确定电脑的BIOS有开启USB作为启动盘启动,在BIOS界面中选择BOOT,将下面的USB设置为enable(联想 Fn+F2)7. 重启电脑,在图标刚刚显示出来的时候 按Fn+F12,进入.
2022-01-22 03:01:01
219
原创 在Spring boot 项目中想要在项目启动完成进行一些操作(CommandLineRunner)
推荐实现CommandLineRunner使用方法:自定义Class 通过@Component标识,如果有多个CommandLineRunner 的实现类,可以通过@Order 去区分优先级比较 @PostConstruct VS 实现CommandLineRunner1. @PostConstruct 在服务器加载Servlet的时候运行,init()之后执行,PreDestroy()之前执行2. 实现CommandLineRunner 在Spring Boot服务启动完成之后执行/**
2021-09-15 17:28:10
161
原创 dubbo升级(com.alibaba.dubbo 2..6.6 升级为org.apache.dobbu 2.7.12) 遇到的问题
dubbo升级(com.alibaba.dubbo 2…6.6 升级为org.apache.dobbu 2.7.12)异常:APPLICATION FAILED TO STARTDescription:An attempt was made to call the method org.apache.curator.framework.api.CreateBuilder.creatingParentsIfNeeded()Lorg/apache/curator/framework/api/Prot
2021-09-13 12:28:51
2136
原创 在Spring-boot使用easy-rules规则执行引擎
在Spring- boot使用easy- rules规则执行引擎使用规则引擎的背景:pom依赖提供测试方法使用规则引擎的背景:在项目中需要使用到用户自定义策略,比如:(订单金额 > 50) && ((用户姓名 contains '张') || ( 用户姓名 contains '王'))对于上面这种格式使用规则引擎在合适不过,自己工作量太大。。并且还会有一些列未知的bug下面开始贴代码pom依赖<properties> <easy.rules.
2021-06-27 17:38:37
3970
原创 服务器日志报错:java.io.IOException: Broken pipe
[ INFO ] [2020-12-14 14:56:49] [b5e9df5d7c052385] [http-nio-8080-exec-6] com.bunnymaicai.operate.common.APILogAspect [55] - SPEND TIME: 602msorg.apache.catalina.connector.ClientAbortException: java.io.IOException: Broken pipeat org.apache.catalina.conne.
2021-06-27 17:12:39
766
转载 docker-compose 安装mysql报错 chown: changing ownership of ‘/var/lib/mysql/‘: Permi
解决方法连接1、/usr/sbin/sestatus -v ##如果SELinux status参数为enabled即为开启状态SELinux status: enabled2、getenforce ##也可以用这个命令检查关闭SELinux:1、临时关闭(不用重启机器):setenforce 0 ##设置SELinux 成为permissive模式 ...
2021-05-05 15:13:36
1983
原创 Java线程(Thread)的生命周期
线程的生命周期 新建(new) 新创建了一个线程对象,但还没有调用start()方法 运行(runnable) java线程中将就绪(ready)和运行中(running),两种状态笼统称为“运行”。线程对象创建后,其他线程调用了该对象的start()方法。该状态的线程位于可运行线程池中。等待被线程调度选中,获取cpu的使用权,此时处于就绪状态(ready)。就绪(ready)状态获取cpu时间片后变成运行中(running)状态 就绪状态(run.
2021-03-29 10:37:47
461
原创 Spring 项目中将resources目录下的.xml文件导入项目中
使用背景:在特殊的业务场景下需要配合.xml文件进行对象操作使用方式:@ImportResource(value = "classpath:/springBean.xml")使用@ImportResource注解将.xml文件导入项目中@ComponentScan(value = {"com.bunnymaicai.boot.kafka"})@SpringBootApplication@ImportResource(value = "classpath:/springBean.xml
2021-02-28 22:56:23
986
1
原创 Spring boot读取自定义的配置文件
比如我在项目中的resources目录下新建了一个mysql.properties文件此时需要读取当前文件怎么办???可以使用@PropertySource(value="classpath:/mysql.properties")配合@Configuration 进行配置,通过Environment读取/** * * @author youshang * @date 2021/02/26 16:29 **/@PropertySource(value = "classpath:/mysql
2021-02-26 19:00:28
482
原创 @Configuration和@Conditional同时存在的时候导致@Configuration下的Bean失效
本文涉及到的关注点1. 项目中存在MyConfig和MyConfig2这两个本文中是实验对象2. 自定义OnBeanCondition 实现Condition ,通过特定条件执行特定的需求3.Mybean和Mybean2 充当本文中的路人甲,乙4.ConfigurationCondition充当本文中的幕后 King5.项目结构目录,扫描的也是启动文件的当前目录1. 咋们先来看看两个实验对象import com.youshang520i.demo.LocalCond..
2021-02-26 18:08:18
1258
1
原创 关于Spring @Configuration注解的full和lite模式导致事务没办法回滚
1.先说说在使用这个注解的时候遇到的问题吧!!!在学习Spring transaction的时候想要实现遇到报错然后回滚,结果总是回滚失败!!最后请求大佬支援看到了我的傻逼问题我先说说我的傻逼问题,我把@Configuration写成了@Configurable 然后在代码中使用的是:@Configurable//这是错误的 应该改成@Configuration@ComponentScan("com.youshang520i")@EnableTransactionManagement@M
2021-02-25 18:10:57
342
原创 Spring 源码中的重点注解(日后会经常更新)
@EventListener注解使用的底层实现类:EventListenerMethodProcessor
2021-02-20 18:14:14
148
原创 Mac构建Spring Boot 源码
报错信息:1.[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project spring-boot-test-support: Compilation failure[ERROR] No compiler is provided in this environment. Perhaps you are runnin
2021-02-03 15:41:27
297
原创 Spring 使用 AopConfigUtils.registerAutoProxyCreatorIfNecessary(registry); 注册代理
原先有问题的代码自定义注解@Retention(RetentionPolicy.RUNTIME)@Target(ElementType.TYPE)@Documented@Import(RateLimiterImportBeanDefinitionRegistrar.class)public @interface EnableRateLimiter { /** * 扫描路径 * @return */ boolean proxyTargetClass
2020-12-21 18:58:08
577
原创 Spring源码工具收集
根据你传进来的basePackage路径获取当前路径下面的所有classString basePackage = "com.youshang520i";//拼接成指定的表达式:classpath*:com/youshang520i/**/*.classString packageSearchPath = ResourcePatternResolver.CLASSPATH_ALL_URL_PREFIX + resolveBasePackage(basePackage) + '/' + t
2020-11-25 16:18:51
217
原创 Spring 使用自定义注解 + Cglib + RateLimiter进行限流操作
当前项目的作用,可以生成一个对应的Jar包丢进项目中,然后引用对应的注解@EnableRateLimiter 表示全局开启 限流,在接口上面使用@RateLimiter 添加对应的参数实现限流操作有什么问题欢迎讨论git@gitee.com:liaojuhui/spring-cglib-ratelimiter.git...
2020-11-11 17:26:19
318
原创 apache-sqoop 1.4.6 搭建总结
准备工作:1.linux 系统,Java 使用的是 jdk8.02. 下载apache-sqoop包准备解压下载地址:http://archive.apache.org/dist/sqoop/1.4.6/我下载的是:sqoop-1.4.6.bin__hadoop-2.0.4-alpha.tar.gz3. 下载apache-hadoop包准备解压下载地址:http://archive.apache.org/dist/hadoop/core/hadoop-2.7.5/我下载的...
2020-11-10 18:20:34
252
转载 压测测试
压测wrk -t1 -c10 -d2s http://127.0.0.1:8080/access使⽤⽅法: wrk <选项> <被测HTTP服务的URL> Options: -c, --connections <N> 跟服务器建⽴并保持的TCP连接数量 -d, --duration <T> 压测时间 -t, --threads <N> 使⽤多少个线程进⾏压测 -s, --script <S> 指定Lua脚本路径.
2020-10-28 09:19:26
202
原创 git常见提交问题
管理员账号提交 已经存在的项目提示下面的内容(没有权限)git@gitlab.com: Permission denied (publickey).fatal: Could not read from remote repository.Please make sure you have the correct access rightsand the repository exists.解决方案:1.https://www.jianshu.com/p/cf41412c4d2d2. .
2020-10-12 11:20:35
197
原创 Spring 项目中报错提示:Invalid bound statement (not found): com.youshang520i.**.**] with root cause
报错信息:2020-09-25 10:23:13.834 ERROR 1539 --- [nio-8008-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.apache
2020-09-25 11:21:24
7110
3
原创 Linux总结:分析服务器Java程序运行内存异常
测试环境:在服务器上面部署一个Java程序,比如一个项目调用一个接口达到死循环皆可输入top 可以得到下面的界面https://blog.youkuaiyun.com/qq_31860135/article/details/83620093上面这篇博客有详细讲解top中的每个参数以及字段找到异常的进程 执行 ps -mp 3303 -o THREAD,tid,time 得到下面的结果接着执行: printf '%x' 3398 jstack 3303 |
2020-09-22 17:51:24
309
原创 Spring cloud 集成 seata 报错信息
2020-09-02 11:30:36.253 INFO 4237 --- [ main] io.seata.core.rpc.netty.RmRpcClient : RM will register :jdbc:mysql://192.168.3.123:3306/seata2020-09-02 11:30:36.254 INFO 4237 --- [ main] i.s.core.rpc.netty.NettyPoolableFactory :.
2020-09-02 11:40:15
5632
原创 Spring boot 通过 @ConfigurationProperties获取属性
假设配置文件的属性是这样的。。spring: cloud: consul: config: enabled: true #enabled 设置config是否启用,默认为true format: yaml #format 设置配置的值的格式,可以yaml和properties prefix: config
2020-07-27 14:56:41
542
原创 电脑有网却打不开网页(能ping通)
报错前我的操作内容1. 使用了vpn然后我断开vpn导致电脑能连网但是访问不了浏览器解决方案:1. 修改网络连接 -> 属性 -> integer 协议版本4的DNS 但是你改了之后你要是换了wifi或者网线怎么办???而且我也没实现2. 看浏览器的报错信息中间有一条检查代理服务器和防火墙 然后跟着步骤走最后发现是我启用VPN的时候默认开启了我的代理服务所以访问不到浏览器。。...
2020-07-26 11:00:42
3294
1
原创 eureka-config-client @Value找不到注册中心的配置信息
报错信息:org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'eurekaConfigClientApplication': Injection of autowired dependencies failed; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholde
2020-07-07 18:58:10
542
2
原创 Spring初始化Bean的三种形式
大致使用这三种方式BeanPostProcessor@PostConstruct @PreDestroyinitMenthod DestroyBeanPostProcessor 两个方法 postProcessBeforeInitialization postProcessAfterInitialization@PostConstruct 和 postProcessBeforeInitializationpostProcessBeforeInitialization 在 @PostCons.
2020-06-29 09:21:54
2650
原创 什么是动态代理?Spring中有哪几种实现?有什么区别?
什么是动态代理?Spring中有哪几种实现?有什么区别?答: 1.可以任意的控制任意对象的执行过程,这个对象的执行过程可以由客户端灵活的指定 2. 两种 3.jdk和CGLibJDK 1. JDK version <= 1.6 的时候实现InvocationHandler,重写invoke,自定义初始化对象(method.invoke(Object,args)) 2.利用拦截器(必须要实现InvocationHandler接口)加上反射机制生成一个代理接口的匿名类,在..
2020-06-29 09:02:03
1244
原创 harbor有部分容器启动失败 harbor Error response from daemon: Get https://192.168.0.106/v2/: dial tcp **.***.0.
执行:docker login 192.168.**.***:8888报错提示:harbor Error response from daemon: Get https://192.168.**.***/v2/: dial tcp **.***.0.***:443: connect: connection refused有可能的报错原因:vim/etc/docker/daemon.json没有配置http访问 "insecure-registries"报错提示:Error re.
2020-06-23 16:45:52
5217
4
原创 docker-compose install
curl -L https://get.daocloud.io/docker/compose/releases/download/1.22.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-composechmod +x /usr/local/bin/docker-composedocker-compose --version# 默认会选择docker-compose.yaml|docker-compose.ym.
2020-06-19 09:06:55
266
java缩略图
2018-03-30
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人