Spring Boot应用程序

运行春季启动应用程序时出现NullPointerException异常,它由一个Maven多模块项目组成,其中我具有Domain层,Persistence层和Web层。

我没有逻辑或bean,只是一个简单的Main @SpringBootApplication类来启动服务器。

结构

http://img3.mukewang.com/60ae0ea300015b2602530529.jpg

主要的

@SpringBootApplication

public class Aplication {


    public static void main(final String[] args) {


        SpringApplication.run(Aplication.class, args);


    }


}


哔哔one
浏览 131回答 1
1回答

犯罪嫌疑人X

添加依赖项之类的。<dependency>&nbsp; &nbsp; &nbsp; &nbsp; <groupId>org.springframework.boot</groupId>&nbsp; &nbsp; &nbsp; &nbsp; <artifactId>spring-boot-starter-web</artifactId>&nbsp; &nbsp; </dependency>&nbsp; &nbsp; <dependency>&nbsp; &nbsp; &nbsp; &nbsp; <groupId>org.springframework.boot</groupId>&nbsp; &nbsp; &nbsp; &nbsp; <artifactId>spring-boot-starter-data-jpa</artifactId>&nbsp; &nbsp; </dependency>或与数据库相关的依赖项。
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

Java