1. 程式人生 > >spring boot伺服器啟動報錯'spring.datasource.url' is not specified

spring boot伺服器啟動報錯'spring.datasource.url' is not specified

報錯資訊

'spring.datasource.url' is not specified and no embedded datasource could be auto-configured.

原因資料庫沒有配置,在啟動的檔案的註解@SpringBootApplication中加入引數

@SpringBootApplication(exclude = {DataSourceAutoConfiguration.class})
最後成功解決錯誤,因為新專案剛剛搭建,還沒有連線資料庫。

相關推薦

spring boot伺服器啟動'spring.datasource.url' is not specified

報錯資訊'spring.datasource.url' is not specified and no embedded datasource could be auto-configured.原因資料庫沒有配置,在啟動的檔案的註解@SpringBootApplication

spring-boot:run啟動

cti filter col mave main -m 報錯 pre shared Intellij Idea中的spring boot項目,使用main方法運行可以啟動,但是使用mvn spring-boot:run啟動總是報錯 大概意思就是找不到類:org/apache

Spring Boot專案啟動com.sun.jersey.api.client.ClientHandlerException: java.net.ConnectException: Connec

報錯內容: com.sun.jersey.api.client.ClientHandlerException: java.net.ConnectException: Connection refused: connect 或者com.netflix.discovery.s

第一個Spring Boot程式啟動

建立完成第一個Spring Boot專案後,準備執行,嘗一下勝利的果實。 啟動日誌如下 . ____ _ __ _ _ /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_

spring boot專案啟動,找不到XXX類

不是很懂csdn如何提問,所以先記錄下來,也希望知道解決方案的能給點提示。問題描述:    新建一個spring boot工程,並且有如下專案:    專案一:cust-service,有啟動類CustApplication、有依賴一個base服務(base沒有applica

SpringBoot啟動:Failed to auto-configure a DataSource: 'spring.datasource.url' is not specified and

      今天倒騰了一下自己的SpringBoot demo的程式碼,發現啟動報瞭如下的錯誤: *************************** APPLICATION FAILED TO START *************************** Des

mvn spring-boot:repackage神坑“'spring.datasource.url' is not specified and no embedded datasource...”

問題: 一開始以為是`spring.datasource.url`配置有問題,後來發現Intellij idea下能執行,但是打成jar包就不能執行,於是反應過來,應該是application.properties等配置檔案,沒有被打進包裡面去。解壓jar包,果

Namenode啟動Operation category JOURNAL is not supported in state standby

org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.ipc.StandbyException): Operation category JOURNAL is not supported in state standby  at org.ap

mysql啟動,提示MySQL is not running, but PID file exists

mysql所在機器關機重啟後,mysql無法啟動,啟動一直報錯MySQL is not running, but PID file exists, 嘗試了所有的啟動方式,都無法啟動,在使用mysqld

Spring boot2.0 啟動 Failed to auto-configure a DataSource

今天Spring Boot 2.0正式版釋出,尋思著搭個小demo嘗試一下Spring Boot的新特性,使用idea建立專案。在選擇元件時添加了mysql、mybatis 然後在第一次啟動的時候啟動報錯,錯誤資訊如下:APPLICATION FAILED TO STARTDescription:Failed

啟動Spring boot註冊中心:RENEWALS ARE LESSER THAN THE THRESHOLD. THE SELF PRESERVATION MODE IS TURNED OFF

服務提供者和服務消費者配置檔案問題: eureka.client.service-url.defaultZone= http://localhost:8080/eureka/ 問題:LoginService.loginTest: com.netflix.cl

spring boot Mybatis】:org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.newhope.interview.dao.UserMapper.add

使用 ase err abstract internal tin mic pre uestc 報錯如下: org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): c

resin發布spring-boot項目“java.lang.NoSuchMethodError: org.jboss.logging.Logger.getMessageLogger”

圖片 ssa 項目啟動 chm dep bubuko ava initial 4.3 說白了還是jar包沖突問題,直接說解決方式: 首先將resin/lib下的validation-api-1.0.0.GA.jar替換成項目中的包validation-api-2.0.1.F

Spring boot配置資料來源之java.sql.SQLException和java.sql.SQLNonTransientConnectionException

週末想自己用Spring boot整合Mybatis寫點簡單的demo,沒想到出了點以前沒遇到過的bug,特記錄一下 java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or repre

spring-boot相關包

最近剛從exlipse轉到idea,在start-spring-io上下載了一個專案。 idea匯入後,在什麼都沒修改的情況下,出現【import org.springframework.boot.SpringApplication;】報錯。 先去檢查maven包,沒有問

spring boot 連線redis org.springframework.data.redis.RedisConnectionFailureException

spring boot 連線redis報錯 org.springframework.data.redis.RedisConnectionFailureException 檢查配置 application.properties 配置 (spring bo

spring boot初始化

解決方法: 將pom檔案中新增如下依賴         <dependency>               <groupId>org.springframework.boot</groupId>               <

Spring Boot連線MySQL8:java.sql.SQLException: Unknown system variable 'tx_isolation'

報錯資訊:java.sql.SQLException: Unknown system variable 'tx_isolation'at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:964) ~[mysql

Jetty在Spring工程中啟動

啟動時報錯資訊如下: java.lang.ArrayIndexOutOfBoundsException: 48188 at org.objectweb.asm.ClassReader.readClass(Unknown Source) at org.objectwe

Spring boot mybatis整合Caused by: org.xml.sax.SAXParseException: 前言中不允許有內容

今天整合Spring boot和mybatis整合的時候,報了這麼一個錯誤! 經過斷點除錯發現錄製進去的xml檔案的二進位制流是空的,也就是說沒有讀到xml檔案,但是又沒有說沒有讀到xml檔案,這點很