草庐IT

boot-args

全部标签

java - 没有 Spring Boot 的 Spring Data JPA

SpringBoot不适用于GoogleAppEngine(至少不适合我)。无论GitHub或其他存储库中编写或提供的许多示例都使用SpringBoot,是否有任何不使用SpringBoot并使用纯上下文XML的Spring-Data-JPA示例和以前一样?这会显示-spring/context.xml(或servlet-context.xml) 最佳答案 刚刚为您创建了这个示例:src/main/webapp/WEB-INF/spring/context.xml${hibernate.dialect}/src/main/webap

spring - 将 Spring Boot 与 gRPC 和 Protobuf 一起使用

任何人有任何使用gRPC和SpringBoot的示例或想法吗? 最佳答案 如果它仍然对你有用,我已经创建了gRPCspring-boot-starterhere.grpc-spring-boot-starter使用@GRpcService-enabledbean自动配置和运行嵌入式gRPC服务器。最简单的例子:@GRpcService(grpcServiceOuterClass=GreeterGrpc.class)publicstaticclassGreeterServiceimplementsGreeterGrpc.Greeter

spring - 将 Spring Boot 与 gRPC 和 Protobuf 一起使用

任何人有任何使用gRPC和SpringBoot的示例或想法吗? 最佳答案 如果它仍然对你有用,我已经创建了gRPCspring-boot-starterhere.grpc-spring-boot-starter使用@GRpcService-enabledbean自动配置和运行嵌入式gRPC服务器。最简单的例子:@GRpcService(grpcServiceOuterClass=GreeterGrpc.class)publicstaticclassGreeterServiceimplementsGreeterGrpc.Greeter

java - 将 Spring Boot 部署到 Tomcat

所以我是Spring新手-所以我想我会尝试SpringBoot我正在使用Maven构建-我设置了一个View请求,当我运行它时,“App”看起来像是它自己启动了tomcat,并且我在默认的8080端口有一个服务,所以当我调用localhost:8080/service一切都好。但是,当我尝试将其打包为WAR以部署到服务器时,它不起作用所以我想我会回到基础并将其部署到本地的tomcat服务器上,看看会发生什么所以首先什么都没发生-404-做了一些谷歌搜索发现我需要包含这样的网络入口点-这是我的主要类(class)@ComponentScan@EnableAutoConfiguration

java - 将 Spring Boot 部署到 Tomcat

所以我是Spring新手-所以我想我会尝试SpringBoot我正在使用Maven构建-我设置了一个View请求,当我运行它时,“App”看起来像是它自己启动了tomcat,并且我在默认的8080端口有一个服务,所以当我调用localhost:8080/service一切都好。但是,当我尝试将其打包为WAR以部署到服务器时,它不起作用所以我想我会回到基础并将其部署到本地的tomcat服务器上,看看会发生什么所以首先什么都没发生-404-做了一些谷歌搜索发现我需要包含这样的网络入口点-这是我的主要类(class)@ComponentScan@EnableAutoConfiguration

spring - 非常慢的 Spring Boot 应用程序启动

我有一个简单的SpringBoot应用程序,它连接到PostgreSQL数据库并用作JSON服务。不知何故,启动变得非常缓慢,请参阅时间10:37:10和10:38:00:2015-05-0910:37:09.649INFO20880---[lication.main()]o.apache.catalina.core.StandardService:StartingserviceTomcat2015-05-0910:37:09.651INFO20880---[lication.main()]org.apache.catalina.core.StandardEngine:Starting

spring - 非常慢的 Spring Boot 应用程序启动

我有一个简单的SpringBoot应用程序,它连接到PostgreSQL数据库并用作JSON服务。不知何故,启动变得非常缓慢,请参阅时间10:37:10和10:38:00:2015-05-0910:37:09.649INFO20880---[lication.main()]o.apache.catalina.core.StandardService:StartingserviceTomcat2015-05-0910:37:09.651INFO20880---[lication.main()]org.apache.catalina.core.StandardEngine:Starting

带有 JPA : move @Entity to different package 的 Spring Boot

我在使用Spring-Boot和JPA的第一步时遇到了问题。我从一个非常简约的examplefromGit开始使用Gradle。现在只需将Customer移动到另一个包,假设hello2会导致异常Causedby:java.lang.IllegalArgumentException:Notanmanagedtype:类hello2.Customer。我尝试添加@ComponentScan(basePackageClasses={Customer.class})//ANDOR@EnableJpaRepositories(basePackageClasses={Customer.class

带有 JPA : move @Entity to different package 的 Spring Boot

我在使用Spring-Boot和JPA的第一步时遇到了问题。我从一个非常简约的examplefromGit开始使用Gradle。现在只需将Customer移动到另一个包,假设hello2会导致异常Causedby:java.lang.IllegalArgumentException:Notanmanagedtype:类hello2.Customer。我尝试添加@ComponentScan(basePackageClasses={Customer.class})//ANDOR@EnableJpaRepositories(basePackageClasses={Customer.class

Spring Boot 日志记录模式

我在SpringBoot应用程序中对Logback的配置有问题。我希望我的consoleAppender看起来像默认的SpringBoot控制台附加程序。如何从SpringBoot默认控制台appender继承模式?下面是我的consoleAppender配置%d{yyyy-MM-ddHH:mm:ss}[%thread]%-5level%logger{36}-%msg%n 最佳答案 一旦你包含了默认配置,你就可以在你自己的logback-spring.xml配置中使用它的值:${CONSOLE_LOG_PATTERN}utf8…