原创 suse下安裝apache

環境:SUSE 11 SP1 軟件包:httpd-2.2.25.tar.gz、tomcat-connectors-1.2.31-src.tar.gz  步驟 1.創建apache2目錄 2.將以上2個tar.gz包上傳至apac

原创 spring boot servlet filter linstener

在spring boot中可以直接申明的servlet,fiter或者listener,只要將其申明爲bean後spring boot自然識別, 因此在spring boot中申明filter有兩種方式(servlet,listen

原创 maven項目 關於Eclipse報:" cannot be read or is not a valid ZIP file"的解決方案

這中情況 說明依賴的jar包沒有完全下好。到repository 中刪去相應的jar目錄 讓maven重新去下載。 如果還報錯 1、刪除maven報錯,eclipse中打開pom.xml 編輯狀態 重新保存。看看最新的報錯信息,進入對應的

原创 springboot中logback自動發送error日誌告警到釘釘

1、自定義appender,先在logback.xml中配置 <appender name="SendErrorMsgAppender" class="com.xxx.xxx.xxx.common.Sen

原创 nginx反向代理websocket wss failed: Error during WebSocket handshake: Unexpected response code: 403

failed: Error during WebSocket handshake: Unexpected response code: 403 在nginx配置proxy_set_header Origin ''; server {

原创 spring aop獲取代理目標對象

TransitionDataStrategy strategy = context.getBean(beanName, TransitionDataStrategy.class); if (AopUtils.is

原创 log4j2詳解

1、配置文件說明 1.1、log4j2默認會在classpath目錄下尋找log4j.json、log4j.jsn、log4j2.xml等名稱的文件,如果都沒有找到,則會按默認配置輸出,也就是輸出到控制檯。 下面我們按默認配置添加一

原创 both methods have same erasure, yet neither overrides the other

這段代碼會報一個編譯錯誤,both methods have same erasure, yet neither overrides the other。 這個錯誤的意思是,兩個方法在類型擦除後,具有相同的原生類型參數列表,但是也不能覆蓋

原创 mysql for update悲觀鎖能否鎖住一條不存在的記錄

  行鎖的3種算法 鎖是針對索引加鎖,如果查詢條件無索引,全表掃描、全表鎖。不討論! 1.Record LOCK 單行記錄上的鎖 2.Gap LOCK 間隙鎖,鎖定一個範圍,但不包含記錄本身 3.Next-KEY Lock:Gap LOC

原创 spring 常用工具類

Spring 常用的一些工具類   學習Java的人,或者開發很多項目,都需要使用到Spring 這個框架,這個框架對於java程序員來說。學好spring 就不怕找不到工作。我們時常會寫一些工具類,但是有些時候 我們不清楚,我們些的工具

原创 nginx反向代理websokcekt wss failed: Error during WebSocket handshake: Unexpected response code: 403

failed: Error during WebSocket handshake: Unexpected response code: 403 在nginx配置proxy_set_header Origin ''; server {

原创 Tcc框架

tcc-transaction https://github.com/changmingxie/tcc-transaction Hmily https://github.com/yu199195/hmily ByteTCC https

原创 springboot中logback自動發送error日誌告警到釘釘羣

1、自定義appender,先在logback.xml中配置 <appender name="SendErrorMsgAppender" class="com.xxx.xxx.xxx.common.Sen

原创 Mysql DeadLock 死鎖

表結構 CREATE TABLE `t_custom_sku_price` ( `id` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主鍵', `customSkuId` BIGINT