国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true

這篇具有很好參考價(jià)值的文章主要介紹了You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true。希望對(duì)大家有所幫助。如果存在錯(cuò)誤或未考慮完全的地方,請(qǐng)大家不吝賜教,您也可以點(diǎn)擊"舉報(bào)違法"按鈕提交疑問(wèn)。

遇到一個(gè)問(wèn)題
You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true
關(guān)鍵點(diǎn):
You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.

翻譯一下:
CST 2022 WARN:不建議在沒(méi)有服務(wù)器身份驗(yàn)證的情況下建立SSL連接。 根據(jù)MySQL 5.5.45+、5.6.26+和5.7.6+的要求,如果沒(méi)有設(shè)置顯式選項(xiàng),默認(rèn)必須建立SSL連接。 為了符合不使用SSL的現(xiàn)有應(yīng)用程序,verifyServerCertificate屬性被設(shè)置為’false’。 您需要通過(guò)設(shè)置useSSL=false顯式禁用SSL,或者設(shè)置useSSL=true并為服務(wù)器證書(shū)驗(yàn)證提供信任存儲(chǔ)區(qū)。

解決:
找到數(shù)據(jù)庫(kù)和項(xiàng)目連接的配置文件
application-prod.properties

spring.datasource.url=jdbc:mysql://localhost:3306/life_vest?useUnicode=true&characterEncoding=UTF8&autoReconnect=true&zeroDateTimeBehavior=convertToNull&useSSL=false

//原來(lái):
//spring.datasource.url=jdbc:mysql://127.0.0.1:3306/life_vest?useUnicode=true&characterEncoding=utf-8

試錯(cuò):
直接添加&useSSL=false,沒(méi)有效果

spring.datasource.url=jdbc:mysql://127.0.0.1:3306/life_vest?useUnicode=true&characterEncoding=utf-8&useSSL=false
或者
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/life_vest?useSSL=false&useUnicode=true&characterEncoding=utf-8

查到的資料

第一種處理辦法
jdbcUrl=jdbc:mysql://localhost:3306/zht?useUnicode=true&characterEncoding=utf-8&useSSL=false

1.先將mysql-connector-java的版本改到5.5.45之下
2.再將jdbcUrl改成如下

jdbcUrl=jdbc:mysql://localhost:3306/zht?useUnicode=true&characterEncoding=utf-8
第二種處理辦法

如果你覺(jué)得更喜歡5.5.45以后的版本,那么需要將jdbc.properties里jdbcUrl換成新的:

jdbc:mysql://localhost:3306/zht?useUnicode=true&characterEncoding=UTF8&autoReconnect=true&zeroDateTimeBehavior=convertToNull

參數(shù)名稱(chēng) | 參數(shù)說(shuō)明
user | 數(shù)據(jù)庫(kù)用戶(hù)名(用于連接數(shù)據(jù)庫(kù))
password | 用戶(hù)密碼(用于連接數(shù)據(jù)庫(kù))
useUnicode | 是否使用Unicode字符集,如果參數(shù)characterEncoding | 設(shè)置為gb2312或gbk,本參數(shù)值必須設(shè)置為true
characterEncoding | 當(dāng)useUnicode設(shè)置為true時(shí),指定字符編碼。比如可設(shè)置為gb2312或gbk
autoReconnect | 當(dāng)數(shù)據(jù)庫(kù)連接異常中斷時(shí),是否自動(dòng)重新連接?
autoReconnectForPools | 是否使用針對(duì)數(shù)據(jù)庫(kù)連接池的重連策略
failOverReadOnly | 自動(dòng)重連成功后,連接是否設(shè)置為只讀?
maxReconnects | autoReconnect設(shè)置為true時(shí),重試連接的次數(shù)
initialTimeout | autoReconnect設(shè)置為true時(shí),兩次重連之間的時(shí)間間隔,單位:秒
connectTimeout | 和數(shù)據(jù)庫(kù)服務(wù)器建立socket連接時(shí)的超時(shí),單位:毫秒。 0表示永不超時(shí),適用于JDK 1.4及更高版本
socketTimeout | socket操作(讀寫(xiě))超時(shí),單位:毫秒。 0表示永不超時(shí)

附錄:

完整application-prod.properties
阿里云 配置springboot與mysql數(shù)據(jù)庫(kù)

spring.datasource.type=com.alibaba.druid.pool.DruidDataSource
spring.datasource.driverClassName=com.mysql.jdbc.Driver
spring.datasource.url=jdbc:mysql://localhost:3306/life_vest?useUnicode=true&characterEncoding=UTF8&autoReconnect=true&zeroDateTimeBehavior=convertToNull&useSSL=false
//數(shù)據(jù)庫(kù)名稱(chēng)
spring.datasource.username=root
//數(shù)據(jù)庫(kù)密碼
spring.datasource.password=
//指定啟動(dòng)連接池時(shí),初始建立的連接數(shù)量
spring.datasource.initialSize=5  
//指定必須保持連接的最小值(For DBCP and Tomcat connection pools)
spring.datasource.minIdle=5 
//指定連接池中最大的活躍連接數(shù).
spring.datasource.maxActive=20  
//指定連接池等待連接返回的最大等待時(shí)間,毫秒單位.
spring.datasource.maxWait=60000  
//指定空閑連接檢查、廢棄連接清理、空閑連接池大小調(diào)整之間的操作時(shí)間間隔
spring.datasource.timeBetweenEvictionRunsMillis=60000  
//指定一個(gè)空閑連接最少空閑多久后可被清除.
spring.datasource.minEvictableIdleTimeMillis=300000  
//指定獲取連接時(shí)連接校驗(yàn)的sql查詢(xún)語(yǔ)句.
spring.datasource.validationQuery=SELECT 1 FROM DUAL  
//當(dāng)連接空閑時(shí),是否執(zhí)行連接測(cè)試.
spring.datasource.testWhileIdle=true  
//當(dāng)從連接池借用連接時(shí),是否測(cè)試該連接.
spring.datasource.testOnBorrow=false  
//在連接歸還到連接池時(shí)是否測(cè)試該連接.
spring.datasource.testOnReturn=false  
//指定是否池化statements.
spring.datasource.poolPreparedStatements=true  
//
spring.datasource.maxPoolPreparedStatementPerConnectionSize=20  
//
spring.datasource.filters=stat,wall,log4j  
//在使用DBCP connection pool時(shí)指定要配置的屬性
spring.datasource.connectionProperties=druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000

本地的話(huà)可以改成

jdbc:mysql://192.16.30.40:3306/life_vest

參考:
mysql 建立SSL連接問(wèn)題,設(shè)置useSSL=false顯式禁用SSL,或者設(shè)置useSSL=true

springboot配置mysql數(shù)據(jù)庫(kù)spring.datasource.url報(bào)錯(cuò)的解決文章來(lái)源地址http://www.zghlxwxcb.cn/news/detail-400836.html

到了這里,關(guān)于You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來(lái)自互聯(lián)網(wǎng)用戶(hù)投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場(chǎng)。本站僅提供信息存儲(chǔ)空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請(qǐng)注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實(shí)不符,請(qǐng)點(diǎn)擊違法舉報(bào)進(jìn)行投訴反饋,一經(jīng)查實(shí),立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • nginx報(bào)錯(cuò):./configure: error: SSL modules require the OpenSSL library. You can either

    nginx報(bào)錯(cuò):./configure: error: SSL modules require the OpenSSL library. You can either 在nginx中配置監(jiān)聽(tīng)443端口后重新加載配置文件出現(xiàn)此報(bào)錯(cuò), 原因:未安裝 ngx_http_ssl_module 模塊 解決方法:

    2024年02月05日
    瀏覽(26)
  • 【Django BUG 已解決】You must either define the environment variable DJANGO_SETTINGS_MODULE or call ...

    【Django BUG 已解決】You must either define the environment variable DJANGO_SETTINGS_MODULE or call ...

    ???????????? 哈嘍!大家好,我是「奇點(diǎn)」,江湖人稱(chēng) singularity。剛工作幾年,想和大家一同進(jìn)步???? 一位上進(jìn)心十足的【Java ToB端大廠(chǎng)領(lǐng)域博主】!?????? 喜歡java和python,平時(shí)比較懶,能用程序解決的堅(jiān)決不手動(dòng)解決?????? ? 如果有對(duì)【java】感興趣的【小可

    2023年04月09日
    瀏覽(21)
  • ./configure: error: SSL modules require the OpenSSL library. You can either do not enable the module

    ?Ubuntu22系統(tǒng),參考nginx文檔Support for QUIC and HTTP/3?執(zhí)行如下命令: 時(shí)報(bào)錯(cuò)如下: 但其實(shí)系統(tǒng)是有openssl庫(kù)的: ? ?out git:(v1.1.0) ? openssl version OpenSSL 3.0.2 15 Mar 2022 (Library: OpenSSL 3.0.2 15 Mar 2022) 必應(yīng)了一下,參考了這兩個(gè):https://forum.nginx.org/read.php?2,299223??#2605 (NGINX + BoringSSL b

    2024年04月27日
    瀏覽(28)
  • 2023/8/18 - You need to rely on yourself to achieve the life you want
  • django: You may need to add ‘localhost‘ to ALLOWED_HOSTS

    參考:https://blog.csdn.net/qq_21744873/article/details/87857279 python manage.py runserver后頁(yè)面訪(fǎng)問(wèn)失敗,提示: DisallowedHost at /admin/ Invalid HTTP_HOST header: ‘localhost:8000’. You may need to add ‘localhost’ to ALLOWED_HOSTS. 解決方法: 這里項(xiàng)目名稱(chēng)為test 打開(kāi)test/test/settings.py配置文件,找到ALLOWED_HOSTS配置

    2024年02月07日
    瀏覽(21)
  • You may use special comments to disable some warnings. Use // eslint-disable-next-line to ignore the

    問(wèn)題: Use // eslint-disable-next-line to ignore the next line. Use /* eslint-disable */ to ignore all warnings in a file. 解決方法 找到build目錄下的webpack.base.conf.js文件,注釋掉其中的與有關(guān)的eslint規(guī)則即可。 關(guān)閉編碼規(guī)范檢查,編輯webpack.base.conf.js,找到module節(jié)點(diǎn)下的rules節(jié)點(diǎn),注釋掉這一行:

    2024年04月09日
    瀏覽(17)
  • vue解決:You may use special comments to disable some warnings.Use // eslint-disable-next-line to ign

    vue解決:You may use special comments to disable some warnings.Use // eslint-disable-next-line to ign

    錯(cuò)誤描述:項(xiàng)目啟動(dòng)時(shí),出現(xiàn) ? ?You may use special comments to disable some warnings.的翻譯是: 你可以使用一些特殊的注釋來(lái)禁用一些警告 出現(xiàn)這樣的問(wèn)題是:ESLint 對(duì)語(yǔ)法的要求過(guò)于嚴(yán)格,出現(xiàn)這樣的問(wèn)題并不是寫(xiě)的代碼有異常,是代碼的格式有問(wèn)題 解決辦法:取消ESLint驗(yàn)證規(guī)則

    2024年02月16日
    瀏覽(20)
  • ElasticSearch 錯(cuò)誤 Fielddata is disabled on text fields by default. Set fielddata=true 解決辦法

    情況: 頁(yè)面查詢(xún)ES數(shù)據(jù),Java查詢(xún)報(bào)這個(gè)錯(cuò)誤,但是,通過(guò)打印的語(yǔ)句,構(gòu)建curl 查詢(xún)時(shí)候又是正常的,這就讓我很費(fèi)解。 報(bào)錯(cuò)信息: 網(wǎng)上的解決辦法: https://blog.csdn.net/qq_16417621/article/details/105859887 這個(gè)解決辦法其實(shí)是正確的,但是,有個(gè)前提條件,我們已經(jīng)導(dǎo)入過(guò)模板,所

    2024年02月16日
    瀏覽(16)
  • 成功解決Pycharm報(bào)錯(cuò):Note: you may need to restart the kernel to use updated packages.

    成功解決Pycharm報(bào)錯(cuò):Note: you may need to restart the kernel to use updated packages.

    pycharm中 import sklearn 報(bào)錯(cuò): 然后在pycharm的控制臺(tái)console中使用 pip install sklearn 安裝了sklearn包,使用 pip list 命令查看安裝成功: 但是,最 玄學(xué) 的事情來(lái)了,明明安裝成功,import卻還是和剛開(kāi)始一樣的報(bào)錯(cuò)。 細(xì)看發(fā)現(xiàn) pip list 的末尾有一句: 我知道jupyter怎么重啟內(nèi)核,但是p

    2024年02月04日
    瀏覽(63)
  • 3 個(gè) ChatGPT 插件您需要立即下載3 ChatGPT Extensions You need to Download Immediately

    3 個(gè) ChatGPT 插件您需要立即下載3 ChatGPT Extensions You need to Download Immediately

    在16世紀(jì),西班牙探險(xiǎn)家皮薩羅帶領(lǐng)約200名西班牙士兵和37匹馬進(jìn)入了印加帝國(guó)。盡管印加帝國(guó)的軍隊(duì)數(shù)量達(dá)到了數(shù)萬(wàn),其中包括5,000名精銳步兵和3,000名弓箭手,他們裝備有大刀、長(zhǎng)矛和弓箭等傳統(tǒng)武器。但皮薩羅的軍隊(duì)中有100名火槍手,50名弩手,以及37名騎兵,他們都裝備

    2024年02月12日
    瀏覽(23)

覺(jué)得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請(qǐng)作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包