I am trying to deploy springboot application with mysql as database on openshift platform. I have pulled the database image and its running. But when i pulled the spring application, it is deployed and connecting to database. But, still i am not able to hit the endpoint and when i check the pods i am getting Crashloopback error.
Can anyone help me to get it resolve.
NAME READY STATUS RESTARTS AGE
mysql-3-deploy 0/1 Completed 0 43m
mysql-3-p2rb6 1/1 Running 0 43m
partydetailswithdb-1-deploy 0/1 Completed 0 46m
partydetailswithdb-2-cs8jp 0/1 CrashLoopBackOff 12 41m
partydetailswithdb-2-deploy 0/1 Completed 0 41m
2019-09-06 05:19:09.519 INFO 1 --- [ main] c.c.openbanking.PartydetailsApplication : Starting PartydetailsApplication
v0.0.1-SNAPSHOT on partydetailswithdb-2-cs8jp with PID 1 (/partyv2.jar started
by 1000880000 in /)
2019-09-06 05:19:09.532 INFO 1 --- [ main] c.c.openbanking.PartydetailsApplication : No active profile set, falling back to default profiles: default
2019-09-06 05:19:09.817 INFO 1 --- [ main] ConfigServletWebServerApplicationContext : Refreshing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#16b4a017: startup date [Fri Sep 06 05:19:09 GMT 2019]; root of context hierarchy
2019-09-06 05:19:15.003 INFO 1 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'webServiceConfig' of type [com.cg.openbanking.configuration.WebServiceConfig$$EnhancerBySpringCGLIB$$1f075603] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-09-06 05:19:15.015 INFO 1 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.ws.config.annotation.DelegatingWsConfiguration' of type [org.springframework.ws.config.annotation.DelegatingWsConfiguration$$EnhancerBySpringCGLIB$$b5052733] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-09-06 05:19:15.143 INFO 1 --- [ main] .w.s.a.s.AnnotationActionEndpointMapping : Supporting [WS-Addressing August 2004, WS-Addressing 1.0]
2019-09-06 05:19:15.237 INFO 1 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'io.opentracing.contrib.spring.cloud.async.DefaultAsyncAutoConfiguration$DefaultTracedAsyncConfigurerSupport' of type [io.opentracing.contrib.spring.cloud.async.DefaultAsyncAutoConfiguration$DefaultTracedAsyncConfigurerSupport$$EnhancerBySpringCGLIB$$55d5a4ef] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-09-06 05:19:15.600 INFO 1 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$106d6234] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-09-06 05:19:16.139 INFO 1 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'io.opentracing.contrib.spring.cloud.async.DefaultAsyncAutoConfiguration' of type [io.opentracing.contrib.spring.cloud.async.DefaultAsyncAutoConfiguration$$EnhancerBySpringCGLIB$$56f3758c] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2019-09-06 05:19:18.896 INFO 1 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat initialized with port(s): 9999 (http)
2019-09-06 05:19:19.108 INFO 1 --- [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat]
2019-09-06 05:19:19.109 INFO 1 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache Tomcat/8.5.35
2019-09-06 05:19:19.202 INFO 1 --- [ost-startStop-1] o.a.catalina.core.AprLifecycleListener : The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [/usr/lib/jvm/java-1.8-openjdk/jre/lib/amd64/server:/usr/lib/jvm/java-1.8-openjdk/jre/lib/amd64:/usr/lib/jvm/java-1.8-openjdk/jre/../lib/amd64:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib]
2019-09-06 05:19:19.501 INFO 1 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2019-09-06 05:19:19.501 INFO 1 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 9692 ms
2019-09-06 05:19:19.895 INFO 1 --- [ost-startStop-1] o.c.s.w.a.ServerTracingAutoConfiguration : Creating FilterRegistrationBean bean with TracingFilter mapped to [/], skip pattern is "/api-docs.|/autoconfig|/configprops|/dump|/health|/info|/metrics.|/mappings|/swagger.|..png|..css|..js|..html|/favicon.ico|/hystrix.stream"
2019-09-06 05:19:20.131 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'tracingFilter' to urls: [/*]
2019-09-06 05:19:20.132 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2019-09-06 05:19:20.132 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2019-09-06 05:19:20.132 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2019-09-06 05:19:20.132 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2019-09-06 05:19:20.132 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Servlet messageDispatcherServlet mapped to [/ws/*]
2019-09-06 05:19:20.133 INFO 1 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Servlet dispatcherServlet mapped to [/]
2019-09-06 05:19:21.301 INFO 1 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Starting...
2019-09-06 05:19:22.303 INFO 1 --- [ main] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Start completed.
2019-09-06 05:19:22.825 INFO 1 --- [ main] j.LocalContainerEntityManagerFactoryBean : Building JPA container EntityManagerFactory for persistence unit 'default'
2019-09-06 05:19:22.933 INFO 1 --- [ main] o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing PersistenceUnitInfo [
name: default
...]
2019-09-06 05:19:23.230 INFO 1 --- [ main] org.hibernate.Version : HHH000412: Hibernate Core {5.2.17.Final}
2019-09-06 05:19:23.234 INFO 1 --- [ main] org.hibernate.cfg.Environment : HHH000206: hibernate.properties not found
Related
I run maven spring boot application with mvn spring-boot:run.
I declared https configuration with application.properties as follow:
server.port = 8443
server.ssl.key-store = keystore.jks
server.ssl.key-store-password = 123456
server.ssl.key-password = 123456
The spring started on right port with follow output:
2018-04-10 10:49:42.074 INFO 6794 --- [ main] ru.ias.Main : Starting Main on IAS-WS-UX02 with PID 6794 (/home/opshenichnikova/NetBeansProjects/bot-integrity/target/classes started by opshenichnikova in /home/opshenichnikova/NetBeansProjects/bot-integrity)
2018-04-10 10:49:42.077 INFO 6794 --- [ main] ru.ias.Main : No active profile set, falling back to default profiles: default
2018-04-10 10:49:42.147 INFO 6794 --- [ main] ConfigServletWebServerApplicationContext : Refreshing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#41d792be: startup date [Tue Apr 10 10:49:42 MSK 2018]; root of context hierarchy
2018-04-10 10:49:42.834 INFO 6794 --- [ main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2018-04-10 10:49:43.044 INFO 6794 --- [ main] org.eclipse.jetty.util.log : Logging initialized #3904ms to org.eclipse.jetty.util.log.Slf4jLog
2018-04-10 10:49:43.110 INFO 6794 --- [ main] o.s.b.w.e.j.JettyServletWebServerFactory : Server initialized with port: 8445
2018-04-10 10:49:43.120 INFO 6794 --- [ main] org.eclipse.jetty.server.Server : jetty-9.4.8.v20171121, build timestamp: 2017-11-22T00:27:37+03:00, git hash: 82b8fb23f757335bb3329d540ce37a2a2615f0a8
2018-04-10 10:49:43.318 INFO 6794 --- [ main] org.eclipse.jetty.server.session : DefaultSessionIdManager workerName=node0
2018-04-10 10:49:43.318 INFO 6794 --- [ main] org.eclipse.jetty.server.session : No SessionScavenger set, using defaults
2018-04-10 10:49:43.339 INFO 6794 --- [ main] org.eclipse.jetty.server.session : Scavenging every 660000ms
2018-04-10 10:49:43.355 INFO 6794 --- [ main] o.e.j.s.h.ContextHandler.application : Initializing Spring embedded WebApplicationContext
2018-04-10 10:49:43.356 INFO 6794 --- [ main] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 1211 ms
2018-04-10 10:49:43.475 INFO 6794 --- [ main] o.s.b.w.servlet.ServletRegistrationBean : Servlet dispatcherServlet mapped to [/]
2018-04-10 10:49:43.477 INFO 6794 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2018-04-10 10:49:43.477 INFO 6794 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2018-04-10 10:49:43.477 INFO 6794 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2018-04-10 10:49:43.478 INFO 6794 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2018-04-10 10:49:43.480 INFO 6794 --- [ main] o.e.jetty.server.handler.ContextHandler : Started o.s.b.w.e.j.JettyEmbeddedWebAppContext#3f0831d8{/,[file:///tmp/jetty-docbase.8895474277820779181.8445/],AVAILABLE}
2018-04-10 10:49:43.481 INFO 6794 --- [ main] org.eclipse.jetty.server.Server : Started #4342ms
2018-04-10 10:49:43.720 INFO 6794 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for #ControllerAdvice: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#41d792be: startup date [Tue Apr 10 10:49:42 MSK 2018]; root of context hierarchy
2018-04-10 10:49:43.788 INFO 6794 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/admin/account/list],methods=[GET]}" onto public java.util.List<ru.ias.orm.Account> ru.ias.controllers.admin.AdminController.getAccounts()
2018-04-10 10:49:43.790 INFO 6794 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/admin/invoices],methods=[GET]}" onto public java.util.List<ru.ias.orm.Invoice> ru.ias.controllers.admin.InvoiceController.getInvoices(javax.servlet.http.HttpServletResponse)
2018-04-10 10:49:43.794 INFO 6794 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2018-04-10 10:49:43.794 INFO 6794 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2018-04-10 10:49:43.829 INFO 6794 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2018-04-10 10:49:43.830 INFO 6794 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2018-04-10 10:49:43.871 INFO 6794 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2018-04-10 10:49:44.049 INFO 6794 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2018-04-10 10:49:44.066 INFO 6794 --- [ main] o.e.j.s.h.ContextHandler.application : Initializing Spring FrameworkServlet 'dispatcherServlet'
2018-04-10 10:49:44.066 INFO 6794 --- [ main] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization started
2018-04-10 10:49:44.076 INFO 6794 --- [ main] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization completed in 10 ms
2018-04-10 10:49:44.432 INFO 6794 --- [ main] o.e.jetty.util.ssl.SslContextFactory : x509=X509#22dbd246(jetty,h=[tbot-test.ias.su],w=[]) for SslContextFactory#2cfff4aa[provider=null,keyStore=file:///home/opshenichnikova/NetBeansProjects/bot-integrity/keystore.jks,trustStore=null]
2018-04-10 10:49:44.507 INFO 6794 --- [ main] o.e.jetty.server.AbstractConnector : Started ServerConnector#139688ed{SSL,[ssl, http/1.1]}{0.0.0.0:8445}
2018-04-10 10:49:44.509 INFO 6794 --- [ main] o.s.b.web.embedded.jetty.JettyWebServer : Jetty started on port(s) 8445 (ssl, http/1.1) with context path '/'
2018-04-10 10:49:44.512 INFO 6794 --- [ main] ru.ias.Main : Started Main in 2.726 seconds (JVM running for 5.372)
^C2018-04-10 10:52:08.108 INFO 6794 --- [ Thread-11] ConfigServletWebServerApplicationContext : Closing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext#41d792be: startup date [Tue Apr 10 10:49:42 MSK 2018]; root of context hierarchy
2018-04-10 10:52:08.109 INFO 6794 --- [ Thread-11] o.s.j.e.a.AnnotationMBeanExporter : Unregistering JMX-exposed beans on shutdown
2018-04-10 10:52:08.116 INFO 6794 --- [ Thread-11] o.e.jetty.server.AbstractConnector : Stopped ServerConnector#139688ed{SSL,[ssl, http/1.1]}{0.0.0.0:8445}
2018-04-10 10:52:08.119 INFO 6794 --- [ Thread-11] org.eclipse.jetty.server.session : Stopped scavenging
2018-04-10 10:52:08.121 INFO 6794 --- [ Thread-11] o.e.j.s.h.ContextHandler.application : Destroying Spring FrameworkServlet 'dispatcherServlet'
2018-04-10 10:52:08.122 INFO 6794 --- [ Thread-11] o.e.jetty.server.handler.ContextHandler : Stopped o.s.b.w.e.j.JettyEmbeddedWebAppContext#3f0831d8{/,[file:///tmp/jetty-docbase.8895474277820779181.8445/],UNAVAILABLE}
I try to access /admin/account/list path declared in controller:
package ru.ias.controllers.admin;
import java.util.ArrayList;
import java.util.List;
import org.hibernate.Session;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import ru.ias.orm.Account;
import ru.ias.config.HibernateUtil;
/**
*
* #author opshenichnikova
*/
#RestController
public class AdminController
{
#GetMapping("/admin/account/list")
#CrossOrigin(origins = "*")
public List<Account> getAccounts()
{
Session session = HibernateUtil
.getInstance()
.getSessionFactory()
.openSession();
session.beginTransaction();
Account account = new Account();
account.setFirstName("Olga");
account.setLastName("Pshenichnikova");
session.save(account);
session.getTransaction().commit();
List<Account> accounts = new ArrayList<>();
accounts.add(account);
return accounts;
}
}
The Main class declared as follow:
package ru.ias;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
#SpringBootApplication
public class Main extends SpringBootServletInitializer
{
#Override
protected SpringApplicationBuilder configure(
SpringApplicationBuilder application
) {
return application.sources(Main.class);
}
public static void main(String[] args)
{
SpringApplication.run(Main.class, args);
}
}
Unfortunately I get follow response:
You are accessing the page via http, not https. Change the URL in your browser to https://localhost:8443/admin/account/list
My springboot application is not starting. The eclipse console is not giving any hint. Earlier it used to start, but now its screwed up. Also, my colleague have almost identical workspace. And it app starts on his machine. Is anyone able to spot anything in this eclipse log:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/C:/Users/593932/.m2/repository/ch/qos/logback/logback-classic/1.1.11/logback-classic-1.1.11.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/C:/Users/593932/.m2/repository/org/slf4j/slf4j-log4j12/1.7.25/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]
2017-07-21 17:22:26.612 DEBUG 7316 --- [ main] o.s.boot.SpringApplication : Loading source class org.springframework.cloud.netflix.eureka.config.EurekaDiscoveryClientConfigServiceBootstrapConfiguration,class org.springframework.cloud.config.client.ConfigServiceBootstrapConfiguration,class org.springframework.cloud.config.client.DiscoveryClientConfigServiceBootstrapConfiguration,class org.springframework.cloud.bootstrap.config.PropertySourceBootstrapConfiguration,class org.springframework.cloud.bootstrap.encrypt.EncryptionBootstrapConfiguration,class org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration,class org.springframework.boot.autoconfigure.PropertyPlaceholderAutoConfiguration
2017-07-21 17:22:26.734 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Activated profiles dev3
2017-07-21 17:22:26.735 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Loaded config file 'file:/C:/Mahesh/workspaces/xyzws8/blueprint-graph/target/classes/bootstrap.properties' (classpath:/bootstrap.properties)
2017-07-21 17:22:26.735 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Skipped (empty) config file 'file:/C:/Mahesh/workspaces/xyzws8/blueprint-graph/target/classes/bootstrap.properties' (classpath:/bootstrap.properties) for profile dev3
2017-07-21 17:22:26.741 INFO 7316 --- [ main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext#2118cddf: startup date [Fri Jul 21 17:22:26 IST 2017]; root of context hierarchy
2017-07-21 17:22:27.501 INFO 7316 --- [ main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-07-21 17:22:27.633 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'configurationPropertiesRebinderAutoConfiguration' of type [org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$7474b600] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:28.183 DEBUG 7316 --- [ main] utoConfigurationReportLoggingInitializer :
=========================
AUTO-CONFIGURATION REPORT
=========================
Positive matches:
-----------------
ConfigServiceBootstrapConfiguration#configServicePropertySource matched:
- #ConditionalOnProperty (spring.cloud.config.enabled) matched (OnPropertyCondition)
ConfigurationPropertiesRebinderAutoConfiguration matched:
- #ConditionalOnBean (types: org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor; SearchStrategy: all) found bean 'org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor' (OnBeanCondition)
ConfigurationPropertiesRebinderAutoConfiguration#configurationPropertiesBeans matched:
- #ConditionalOnMissingBean (types: org.springframework.cloud.context.properties.ConfigurationPropertiesBeans; SearchStrategy: current) did not find any beans (OnBeanCondition)
ConfigurationPropertiesRebinderAutoConfiguration#configurationPropertiesRebinder matched:
- #ConditionalOnMissingBean (types: org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder; SearchStrategy: current) did not find any beans (OnBeanCondition)
EncryptionBootstrapConfiguration matched:
- #ConditionalOnClass found required class 'org.springframework.security.crypto.encrypt.TextEncryptor'; #ConditionalOnMissingClass did not find unwanted class (OnClassCondition)
PropertyPlaceholderAutoConfiguration#propertySourcesPlaceholderConfigurer matched:
- #ConditionalOnMissingBean (types: org.springframework.context.support.PropertySourcesPlaceholderConfigurer; SearchStrategy: current) did not find any beans (OnBeanCondition)
Negative matches:
-----------------
ConfigServiceBootstrapConfiguration.RetryConfiguration:
Did not match:
- #ConditionalOnClass did not find required class 'org.springframework.retry.annotation.Retryable' (OnClassCondition)
DiscoveryClientConfigServiceBootstrapConfiguration:
Did not match:
- #ConditionalOnProperty (spring.cloud.config.discovery.enabled) did not find property 'spring.cloud.config.discovery.enabled' (OnPropertyCondition)
EncryptionBootstrapConfiguration.RsaEncryptionConfiguration:
Did not match:
- Keystore nor key found in Environment (EncryptionBootstrapConfiguration.KeyCondition)
Matched:
- #ConditionalOnClass found required class 'org.springframework.security.rsa.crypto.RsaSecretEncryptor'; #ConditionalOnMissingClass did not find unwanted class (OnClassCondition)
EncryptionBootstrapConfiguration.VanillaEncryptionConfiguration:
Did not match:
- #ConditionalOnMissingClass found unwanted class 'org.springframework.security.rsa.crypto.RsaSecretEncryptor' (OnClassCondition)
EurekaDiscoveryClientConfigServiceBootstrapConfiguration:
Did not match:
- #ConditionalOnProperty (spring.cloud.config.discovery.enabled) did not find property 'spring.cloud.config.discovery.enabled' (OnPropertyCondition)
Matched:
- #ConditionalOnClass found required class 'org.springframework.cloud.config.client.ConfigServicePropertySourceLocator'; #ConditionalOnMissingClass did not find unwanted class (OnClassCondition)
Exclusions:
-----------
None
Unconditional classes:
----------------------
None
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v1.5.3.RELEASE)
2017-07-21 17:22:28.874 INFO 7316 --- [ main] c.c.c.ConfigServicePropertySourceLocator : Fetching config from server at: http://localhost:8888
2017-07-21 17:22:30.026 WARN 7316 --- [ main] c.c.c.ConfigServicePropertySourceLocator : Could not locate PropertySource: I/O error on GET request for "http://localhost:8888/pqr/dev3": Connection refused: connect; nested exception is java.net.ConnectException: Connection refused: connect
2017-07-21 17:22:30.029 INFO 7316 --- [ main] com.abc.xyz.pqr.pqrApplication : The following profiles are active: dev3
2017-07-21 17:22:30.033 DEBUG 7316 --- [ main] o.s.boot.SpringApplication : Loading source class com.abc.xyz.pqr.pqrApplication
2017-07-21 17:22:30.056 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Activated profiles dev3
2017-07-21 17:22:30.057 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Loaded config file 'jar:file:/C:/Users/593932/.m2/repository/com/abc/xyz/utils/logger/2.0.0.1-SNAPSHOT/logger-2.0.0.1-SNAPSHOT.jar!/application.properties' (classpath:/application.properties)
2017-07-21 17:22:30.057 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Loaded config file 'file:/C:/Mahesh/workspaces/xyzws8/pqr-rest/target/classes/application-dev3.properties' (classpath:/application-dev3.properties)
2017-07-21 17:22:30.057 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Skipped (empty) config file 'file:/C:/Mahesh/workspaces/xyzws8/pqr-rest/target/classes/application-dev3.properties' (classpath:/application-dev3.properties) for profile dev3
2017-07-21 17:22:30.057 DEBUG 7316 --- [ main] o.s.b.c.c.ConfigFileApplicationListener : Skipped (empty) config file 'jar:file:/C:/Users/593932/.m2/repository/com/abc/xyz/utils/logger/2.0.0.1-SNAPSHOT/logger-2.0.0.1-SNAPSHOT.jar!/application.properties' (classpath:/application.properties) for profile dev3
2017-07-21 17:22:30.057 INFO 7316 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#590c73d3: startup date [Fri Jul 21 17:22:30 IST 2017]; parent: org.springframework.context.annotation.AnnotationConfigApplicationContext#2118cddf
2017-07-21 17:22:30.061 DEBUG 7316 --- [ main] ationConfigEmbeddedWebApplicationContext : Bean factory for org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#590c73d3: org.springframework.beans.factory.support.DefaultListableBeanFactory#6c67e137: defining beans [org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,org.springframework.context.event.internalEventListenerProcessor,org.springframework.context.event.internalEventListenerFactory,pqrApplication]; parent: org.springframework.beans.factory.support.DefaultListableBeanFactory#5afa3c9
2017-07-21 17:22:54.813 INFO 7316 --- [ main] o.s.b.f.s.DefaultListableBeanFactory : Overriding bean definition for bean 'dataSource' with a different definition: replacing [Root bean: class [null]; scope=; abstract=false; lazyInit=false; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration$Hikari; factoryMethodName=dataSource; initMethodName=null; destroyMethodName=(inferred); defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Hikari.class]] with [Root bean: class [null]; scope=; abstract=false; lazyInit=false; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration$Tomcat; factoryMethodName=dataSource; initMethodName=null; destroyMethodName=(inferred); defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Tomcat.class]]
2017-07-21 17:22:56.472 INFO 7316 --- [ main] o.s.cloud.context.scope.GenericScope : BeanFactory id=913a3bd9-b3c0-3356-9fa2-16200e317e2e
2017-07-21 17:22:56.572 INFO 7316 --- [ main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-07-21 17:22:56.727 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'com.abc.xyz.workitem.client.WorkItemClient' of type [org.springframework.cloud.netflix.feign.FeignClientFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:57.254 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$585ab303] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:57.706 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.apache.camel.spring.boot.CamelAutoConfiguration' of type [org.apache.camel.spring.boot.CamelAutoConfiguration$$EnhancerBySpringCGLIB$$7a847922] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:57.946 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.cloud.netflix.metrics.MetricsInterceptorConfiguration$MetricsRestTemplateConfiguration' of type [org.springframework.cloud.netflix.metrics.MetricsInterceptorConfiguration$MetricsRestTemplateConfiguration$$EnhancerBySpringCGLIB$$8a875944] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:57.998 INFO 7316 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration' of type [org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$7474b600] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-21 17:22:58.013 DEBUG 7316 --- [ main] ationConfigEmbeddedWebApplicationContext : Unable to locate MessageSource with name 'messageSource': using default [org.springframework.context.support.DelegatingMessageSource#2589d787]
2017-07-21 17:22:58.013 DEBUG 7316 --- [ main] ationConfigEmbeddedWebApplicationContext : Unable to locate ApplicationEventMulticaster with name 'applicationEventMulticaster': using default [org.springframework.context.event.SimpleApplicationEventMulticaster#1788cb61]
2017-07-21 17:22:59.563 DEBUG 7316 --- [ main] .t.TomcatEmbeddedServletContainerFactory : Code archive: C:\Users\593932\.m2\repository\org\springframework\boot\spring-boot\1.5.3.RELEASE\spring-boot-1.5.3.RELEASE.jar
2017-07-21 17:22:59.564 DEBUG 7316 --- [ main] .t.TomcatEmbeddedServletContainerFactory : Code archive: C:\Users\593932\.m2\repository\org\springframework\boot\spring-boot\1.5.3.RELEASE\spring-boot-1.5.3.RELEASE.jar
2017-07-21 17:22:59.564 DEBUG 7316 --- [ main] .t.TomcatEmbeddedServletContainerFactory : Document root: C:\Mahesh\workspaces\xyzws8\pqr-rest\src\main\webapp
2017-07-21 17:22:59.685 INFO 7316 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 0 (http)
Jul 21, 2017 5:22:59 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Tomcat
Jul 21, 2017 5:22:59 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/8.5.14
Jul 21, 2017 5:23:02 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring embedded WebApplicationContext
2017-07-21 17:23:02.138 INFO 7316 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 32081 ms
2017-07-21 17:23:02.513 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Added existing Servlet initializer bean 'dispatcherServletRegistration'; order=2147483647, resource=class path resource [org/springframework/boot/autoconfigure/web/DispatcherServletAutoConfiguration$DispatcherServletRegistrationConfiguration.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'metricsFilter'; order=-2147483648, resource=class path resource [org/springframework/boot/actuate/autoconfigure/MetricFilterAutoConfiguration.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'characterEncodingFilter'; order=-2147483648, resource=class path resource [org/springframework/boot/autoconfigure/web/HttpEncodingAutoConfiguration.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'hiddenHttpMethodFilter'; order=-10000, resource=class path resource [org/springframework/boot/autoconfigure/web/WebMvcAutoConfiguration.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'httpPutFormContentFilter'; order=-9900, resource=class path resource [org/springframework/boot/autoconfigure/web/WebMvcAutoConfiguration.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'requestContextFilter'; order=-105, resource=class path resource [org/springframework/boot/autoconfigure/web/WebMvcAutoConfiguration$WebMvcAutoConfigurationAdapter.class]
2017-07-21 17:23:03.639 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'webRequestLoggingFilter'; order=2147483637, resource=class path resource [org/springframework/boot/actuate/autoconfigure/TraceWebFilterAutoConfiguration.class]
2017-07-21 17:23:03.640 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.s.ServletContextInitializerBeans : Created Filter initializer for bean 'applicationContextIdFilter'; order=2147483647, resource=class path resource [org/springframework/boot/actuate/autoconfigure/EndpointWebMvcAutoConfiguration$ApplicationContextFilterConfiguration.class]
2017-07-21 17:23:03.674 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-07-21 17:23:03.700 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'metricsFilter' to: [/*]
2017-07-21 17:23:03.701 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-07-21 17:23:03.720 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-07-21 17:23:03.721 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-07-21 17:23:03.721 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-07-21 17:23:03.721 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'webRequestLoggingFilter' to: [/*]
2017-07-21 17:23:03.721 INFO 7316 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'applicationContextIdFilter' to: [/*]
2017-07-21 17:23:03.913 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedRequestContextFilter : Initializing filter 'requestContextFilter'
2017-07-21 17:23:03.916 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedRequestContextFilter : Filter 'requestContextFilter' configured successfully
2017-07-21 17:23:03.917 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.ApplicationContextHeaderFilter : Initializing filter 'applicationContextIdFilter'
2017-07-21 17:23:03.917 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.ApplicationContextHeaderFilter : Filter 'applicationContextIdFilter' configured successfully
2017-07-21 17:23:03.917 DEBUG 7316 --- [ost-startStop-1] .s.b.w.f.OrderedHttpPutFormContentFilter : Initializing filter 'httpPutFormContentFilter'
2017-07-21 17:23:03.917 DEBUG 7316 --- [ost-startStop-1] .s.b.w.f.OrderedHttpPutFormContentFilter : Filter 'httpPutFormContentFilter' configured successfully
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedHiddenHttpMethodFilter : Initializing filter 'hiddenHttpMethodFilter'
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedHiddenHttpMethodFilter : Filter 'hiddenHttpMethodFilter' configured successfully
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedCharacterEncodingFilter : Initializing filter 'characterEncodingFilter'
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.w.f.OrderedCharacterEncodingFilter : Filter 'characterEncodingFilter' configured successfully
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.a.trace.WebRequestTraceFilter : Initializing filter 'webRequestLoggingFilter'
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.a.trace.WebRequestTraceFilter : Filter 'webRequestLoggingFilter' configured successfully
2017-07-21 17:23:03.918 DEBUG 7316 --- [ost-startStop-1] o.s.b.a.autoconfigure.MetricsFilter : Initializing filter 'metricsFilter'
2017-07-21 17:23:03.919 DEBUG 7316 --- [ost-startStop-1] o.s.b.a.autoconfigure.MetricsFilter : Filter 'metricsFilter' configured successfully
2017-07-21 17:23:06.527 DEBUG 7316 --- [ main] o.s.b.a.AutoConfigurationPackages : #EnableAutoConfiguration was declared on a class in the package 'com.abc.xyz,com.abc.xyz.pqr'. Automatic #Repository and #Entity scanning is enabled.
2017-07-21 17:23:08.193 INFO 7316 --- [ main] j.LocalContainerEntityManagerFactoryBean : Building JPA container EntityManagerFactory for persistence unit 'default'
2017-07-21 17:23:08.608 INFO 7316 --- [ main] o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing PersistenceUnitInfo [
name: default
...]
2017-07-21 17:23:10.167 INFO 7316 --- [ main] org.hibernate.Version : HHH000412: Hibernate Core {5.0.12.Final}
2017-07-21 17:23:10.180 INFO 7316 --- [ main] org.hibernate.cfg.Environment : HHH000205: Loaded properties from resource hibernate.properties: {hibernate.temp.use_jdbc_metadata_defaults=false, hibernate.bytecode.use_reflection_optimizer=false}
2017-07-21 17:23:10.181 INFO 7316 --- [ main] org.hibernate.cfg.Environment : HHH000021: Bytecode provider name : javassist
2017-07-21 17:23:10.602 INFO 7316 --- [ main] o.hibernate.annotations.common.Version : HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
2017-07-21 17:23:11.278 INFO 7316 --- [ main] org.hibernate.dialect.Dialect : HHH000400: Using dialect: com.abc.xyz.hibernate.dialect.JSONBPostgreSQLDialect
2017-07-21 17:23:11.355 INFO 7316 --- [ main] o.h.e.j.e.i.LobCreatorBuilderImpl : HHH000422: Disabling contextual LOB creation as connection was null
2017-07-21 17:23:11.361 INFO 7316 --- [ main] org.hibernate.type.BasicTypeRegistry : HHH000270: Type registration [java.util.UUID] overrides previous : org.hibernate.type.UUIDBinaryType#18811c42
2017-07-21 17:23:12.153 WARN 7316 --- [ main] org.hibernate.id.UUIDHexGenerator : HHH000409: Using org.hibernate.id.UUIDHexGenerator which does not generate IETF RFC 4122 compliant UUID values; consider using org.hibernate.id.UUIDGenerator instead
2017-07-21 17:23:13.606 INFO 7316 --- [ main] org.hibernate.tool.hbm2ddl.SchemaUpdate : HHH000228: Running hbm2ddl schema update
2017-07-21 17:23:15.246 INFO 7316 --- [ main] j.LocalContainerEntityManagerFactoryBean : Initialized JPA EntityManagerFactory for persistence unit 'default'
2017-07-21 17:23:15.326 INFO 7316 --- [ main] o.s.aop.framework.CglibAopProxy : Final method [protected final void org.springframework.boot.web.support.SpringBootServletInitializer.setRegisterErrorPageFilter(boolean)] cannot get proxied via CGLIB: Calls to this method will NOT be routed to the target instance and might lead to NPEs against uninitialized fields in the proxy instance.
2017-07-21 17:23:15.908 INFO 7316 --- [ main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext#691eb389: startup date [Fri Jul 21 17:23:15 IST 2017]; parent: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#590c73d3
2017-07-21 17:23:16.015 INFO 7316 --- [ main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
Jul 21, 2017 5:23:18 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Tomcat
Is this line an issue?:
2017-07-21 17:23:11.355 INFO 7316 --- [ main] o.h.e.j.e.i.LobCreatorBuilderImpl : HHH000422: Disabling contextual LOB creation as connection was null
Earlier I used to get following:
2017-07-21 16:43:44.438 INFO 7008 --- [ main] o.h.e.j.e.i.LobCreatorBuilderImpl : HHH000424: Disabling contextual LOB creation as createClob() method threw error : java.lang.reflect.InvocationTargetException
So I added
hibernate.temp.use_jdbc_metadata_defaults=false
to properties file.
Notice that the tomcat stops abruptly (last two lines):
Jul 21, 2017 5:23:18 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Tomcat
Sorry for putting so much log. I put --debug in programs arguments. Is there anything else I can do to get some more information?
Here are some files as requested in comments:
pom file
main class file
Note that I have other applications as dependencies. So they will also be adding many other dependencies which are not getting captured in above pom. How can I share them here?
The main class is really a placeholder which triggers SpringBoot which in turn runs various stuff say load beans, run apache camel routes etc.
I'm using spring boot 1.5.4, i'm following a tutorial where it shows that just by adding h2-console to the localhost:8080/ url you can access the console. But when i do that i have a 404 Whitelabel error.
These are the dependencies
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
<!--WebJars-->
<dependency>
<groupId>org.webjars</groupId>
<artifactId>bootstrap</artifactId>
<version>3.3.5</version>
</dependency>
<dependency>
<groupId>org.webjars</groupId>
<artifactId>jquery</artifactId>
<version>3.2.1</version>
</dependency>
<!--jpa and database-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<scope>runtime</scope>
</dependency>
</dependencies>
And this is the spring boot console log
2017-07-19 01:35:25.222 INFO 8644 --- [ main] c.e.s.SpringBootTest00Application : Starting SpringBootTest00Application on DESKTOP-K8Q0B2R with PID 8644 (started by Talon in C:\Users\Talon\Desktop\java netbeans\01\springBootTest00)
2017-07-19 01:35:25.225 INFO 8644 --- [ main] c.e.s.SpringBootTest00Application : No active profile set, falling back to default profiles: default
2017-07-19 01:35:25.544 INFO 8644 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#37574691: startup date [Wed Jul 19 01:35:25 CEST 2017]; root of context hierarchy
2017-07-19 01:35:27.236 INFO 8644 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-07-19 01:35:27.248 INFO 8644 --- [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat]
2017-07-19 01:35:27.249 INFO 8644 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache Tomcat/8.5.15
2017-07-19 01:35:27.378 INFO 8644 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-07-19 01:35:27.378 INFO 8644 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 1838 ms
2017-07-19 01:35:27.578 INFO 8644 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-07-19 01:35:27.582 INFO 8644 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-07-19 01:35:27.584 INFO 8644 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-07-19 01:35:27.584 INFO 8644 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-07-19 01:35:27.584 INFO 8644 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-07-19 01:35:28.020 INFO 8644 --- [ main] j.LocalContainerEntityManagerFactoryBean : Building JPA container EntityManagerFactory for persistence unit 'default'
2017-07-19 01:35:28.037 INFO 8644 --- [ main] o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing PersistenceUnitInfo [
name: default
...]
2017-07-19 01:35:28.122 INFO 8644 --- [ main] org.hibernate.Version : HHH000412: Hibernate Core {5.0.12.Final}
2017-07-19 01:35:28.123 INFO 8644 --- [ main] org.hibernate.cfg.Environment : HHH000206: hibernate.properties not found
2017-07-19 01:35:28.180 INFO 8644 --- [ main] org.hibernate.cfg.Environment : HHH000021: Bytecode provider name : javassist
2017-07-19 01:35:28.219 INFO 8644 --- [ main] o.hibernate.annotations.common.Version : HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
2017-07-19 01:35:28.321 INFO 8644 --- [ main] org.hibernate.dialect.Dialect : HHH000400: Using dialect: org.hibernate.dialect.H2Dialect
2017-07-19 01:35:28.742 INFO 8644 --- [ main] org.hibernate.tool.hbm2ddl.SchemaExport : HHH000227: Running hbm2ddl schema export
2017-07-19 01:35:28.757 INFO 8644 --- [ main] org.hibernate.tool.hbm2ddl.SchemaExport : HHH000230: Schema export complete
2017-07-19 01:35:28.809 INFO 8644 --- [ main] j.LocalContainerEntityManagerFactoryBean : Initialized JPA EntityManagerFactory for persistence unit 'default'
2017-07-19 01:35:29.119 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for #ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#37574691: startup date [Wed Jul 19 01:35:25 CEST 2017]; root of context hierarchy
2017-07-19 01:35:29.203 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/]}" onto public java.lang.String com.example.springBootTest00.controllers.IndexController.index()
2017-07-19 01:35:29.205 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/product],methods=[POST]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.saveOrUpdateProduct(com.example.springBootTest00.domain.Product)
2017-07-19 01:35:29.206 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/product/edit/{id}]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.edit(java.lang.Integer,org.springframework.ui.Model)
2017-07-19 01:35:29.206 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/product/new]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.newProduct(org.springframework.ui.Model)
2017-07-19 01:35:29.206 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/product/delete/{id}]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.deleteProduct(java.lang.Integer,org.springframework.ui.Model)
2017-07-19 01:35:29.206 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/products]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.listProducts(org.springframework.ui.Model)
2017-07-19 01:35:29.206 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/product/{id}]}" onto public java.lang.String com.example.springBootTest00.controllers.ProductController.getProduct(java.lang.Integer,org.springframework.ui.Model)
2017-07-19 01:35:29.209 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-07-19 01:35:29.209 INFO 8644 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-07-19 01:35:29.243 INFO 8644 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-19 01:35:29.244 INFO 8644 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-19 01:35:29.284 INFO 8644 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-19 01:35:29.920 INFO 8644 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-07-19 01:35:29.983 INFO 8644 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 8080 (http)
2017-07-19 01:35:29.987 INFO 8644 --- [ main] c.e.s.SpringBootTest00Application : Started SpringBootTest00Application in 5.052 seconds (JVM running for 5.401)
I have some classes with #Service / #Controller working properly and all the requests are mapped to url strings other than h2-console. Should i import something else in the pom or configure something in application.properties ?
Writing in simple Steps:
In Application.properties file include
spring.h2.console.path=/h2
spring.h2.console.enabled=true
And in pom.xml Include devtools dependency
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
</dependency>
re-package and open http://localhost:[port]/h2 you are all set
other properties you have to include is
spring.datasource.url=jdbc:h2:file:~/h2db
spring.datasource.username=sa
spring.datasource.password=
spring.datasource.driver-class-name=org.h2.Driver
the file h2db will store in userprofile folder of windows
for example : C:\Users\[profile]
I am using latest release version of spring boot with camel-cxf to expose rest/soap web services. However since I have many services and some of them are not well defined, I want to register each of them one by one, catch if any exception occurs and continue with remaining valid services. But when I set camel.springboot.auto-startup=false I can not manage to open cxf service again. (Please note that timer route can be started this way). Any solution or suggestion ?
#Component
public class TestRoutes {
#Autowired CamelContext camelContext;
#Autowired Swagger2Feature swagger2Feature;
#PostConstruct
public void init(){
try {
camelContext.start();
} catch (Exception e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
HelloResponse response = new HelloResponse();
response.setCevap("response");
List<Object> providers = new ArrayList<>();
CxfRsComponent cxfComponent = new CxfRsComponent(camelContext);
CxfRsEndpoint serviceEndpoint = new CxfRsEndpoint("/rest2", cxfComponent);
serviceEndpoint.addResourceClass(Service1.class);
serviceEndpoint.setProviders(providers);
serviceEndpoint.setSynchronous(true);
serviceEndpoint.setAddress("/rest2");
serviceEndpoint.getFeatures().add(swagger2Feature);
RouteBuilder builder = new RouteBuilder(camelContext) {
#Override
public void configure() throws Exception {
from(serviceEndpoint)
.id(Service1.class.getCanonicalName()+"rest")
.log("${header.operationName} message here")
.setBody(constant(response));
from("timer:mytimer?period=5000")
.id("timer")
.log("hi");
}
};
try {
camelContext.startRoute(Service1.class.getCanonicalName()+"rest");
camelContext.startRoute("timer");
} catch (Exception e) {
e.printStackTrace();
}
}
}
2017-07-18 10:50:49.076 INFO 12052 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#5149d738: startup date [Tue Jul 18 10:50:49 EEST 2017]; root of context hierarchy
2017-07-18 10:50:52.413 INFO 12052 --- [ main] trationDelegate$BeanPostProcessorChecker : Bean 'org.apache.camel.spring.boot.CamelAutoConfiguration' of type [org.apache.camel.spring.boot.CamelAutoConfiguration$$EnhancerBySpringCGLIB$$5d14135] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-18 10:50:53.063 INFO 12052 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-07-18 10:50:53.085 INFO 12052 --- [ main] o.apache.catalina.core.StandardService : Starting service Tomcat
2017-07-18 10:50:53.086 INFO 12052 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache
Tomcat/8.5.11
2017-07-18 10:50:53.341 INFO 12052 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-07-18 10:50:53.342 INFO 12052 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 4269 ms
2017-07-18 10:50:53.974 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-07-18 10:50:53.976 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'CXFServlet' to [/services/*]
2017-07-18 10:50:53.981 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-07-18 10:50:53.982 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-07-18 10:50:53.982 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-07-18 10:50:53.982 INFO 12052 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-07-18 10:50:54.682 INFO 12052 --- [ main] o.a.camel.spring.SpringCamelContext : Apache Camel 2.19.1 (CamelContext: camel-1) is starting
2017-07-18 10:50:54.685 INFO 12052 --- [ main] o.a.c.m.ManagedManagementStrategy : JMX is enabled
2017-07-18 10:50:54.999 INFO 12052 --- [ main] o.a.c.i.converter.DefaultTypeConverter : Loaded 214 type converters
2017-07-18 10:50:55.064 INFO 12052 --- [ main] o.a.c.i.DefaultRuntimeEndpointRegistry : Runtime endpoint registry is in extended mode gathering usage statistics of all incoming and outgoing endpoints (cache limit: 1000)
2017-07-18 10:50:55.094 INFO 12052 --- [ main] o.a.camel.spring.SpringCamelContext : StreamCaching is not in use. If using streams then its recommended to enable stream caching. See more details at http://camel.apache.org/stream-caching.html
2017-07-18 10:50:55.095 INFO 12052 --- [ main] o.a.camel.spring.SpringCamelContext : Total 0 routes, of which 0 are started.
2017-07-18 10:50:55.097 INFO 12052 --- [ main] o.a.camel.spring.SpringCamelContext : Apache Camel 2.19.1 (CamelContext: camel-1) started in 0.415 seconds
2017-07-18 10:50:55.301 WARN 12052 --- [ main] o.apache.cxf.jaxrs.utils.ResourceUtils : No resource methods have been found for resource class java.lang.Class
2017-07-18 10:50:55.433 INFO 12052 --- [ main] org.apache.cxf.endpoint.ServerImpl : Setting the server's publish address to be /rest1
2017-07-18 10:50:55.636 INFO 12052 --- [ main] org.reflections.Reflections : Reflections took 60 ms to scan 1 urls, producing 21 keys and 25 values
2017-07-18 10:50:56.106 INFO 12052 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for #ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#5149d738: startup date [Tue Jul 18 10:50:49 EEST 2017]; root of context hierarchy
2017-07-18 10:50:56.206 INFO 12052 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-07-18 10:50:56.208 INFO 12052 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-07-18 10:50:56.267 INFO 12052 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-18 10:50:56.267 INFO 12052 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-18 10:50:56.330 INFO 12052 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-18 10:50:57.591 INFO 12052 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-07-18 10:50:57.686 INFO 12052 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 8080 (http)
2017-07-18 10:50:57.694 INFO 12052 --- [ main] c.e.demo.AutoStartupFalseApplication : Started AutoStartupFalseApplication in 9.057 seconds (JVM running for 9.764)
The problem was if bus not set explicitly CamelCXF generates a default one which is not spring aware. So solution was generatin a SpringBus bean and wiring it to explicitly to the CxfRsEndpoint object.
In the configuration class
#Bean(destroyMethod = "shutdown")
public SpringBus cxf() {
return new SpringBus();
}
In the endpoint definition :
#Autowired Bus bus;
.
.
CxfRsEndpoint serviceEndpoint = new CxfRsEndpoint("/rest2", cxfComponent);
.
.
serviceEndpoint.setBus(bus);
Then it starts working as expected.
i have a strange problem when i launch my spring application it used to print a default password to login in the browser but now ther isn't :
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v1.5.3.RELEASE)
2017-06-26 17:04:32.024 INFO 28712 --- [ main] com.o2xp.ats.accountManager.App : Starting App on frozzen-PC with PID 28712 (/home/frozzen/workspace/ATS/ats-parent/ats-impl/ats-accountManager/target/classes started by frozzen in /home/frozzen/workspace/ATS/ats-parent/ats-impl/ats-accountManager)
2017-06-26 17:04:32.030 INFO 28712 --- [ main] com.o2xp.ats.accountManager.App : No active profile set, falling back to default profiles: default
2017-06-26 17:04:32.282 INFO 28712 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#45f45fa1: startup date [Mon Jun 26 17:04:32 CEST 2017]; root of context hierarchy
2017-06-26 17:04:35.685 INFO 28712 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-06-26 17:04:35.723 INFO 28712 --- [ main] o.apache.catalina.core.StandardService : Starting service Tomcat
2017-06-26 17:04:35.724 INFO 28712 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache Tomcat/8.5.14
2017-06-26 17:04:35.962 INFO 28712 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-06-26 17:04:35.962 INFO 28712 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 3688 ms
2017-06-26 17:04:36.361 INFO 28712 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-06-26 17:04:36.362 INFO 28712 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-06-26 17:04:36.362 INFO 28712 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-06-26 17:04:36.362 INFO 28712 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-06-26 17:04:36.364 INFO 28712 --- [ost-startStop-1] .s.DelegatingFilterProxyRegistrationBean : Mapping filter: 'springSecurityFilterChain' to: [/*]
2017-06-26 17:04:36.365 INFO 28712 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-06-26 17:04:37.170 INFO 28712 --- [ main] j.LocalContainerEntityManagerFactoryBean : Building JPA container EntityManagerFactory for persistence unit 'default'
2017-06-26 17:04:37.195 INFO 28712 --- [ main] o.hibernate.jpa.internal.util.LogHelper : HHH000204: Processing PersistenceUnitInfo [
name: default
...]
2017-06-26 17:04:37.300 INFO 28712 --- [ main] org.hibernate.Version : HHH000412: Hibernate Core {5.0.12.Final}
2017-06-26 17:04:37.302 INFO 28712 --- [ main] org.hibernate.cfg.Environment : HHH000206: hibernate.properties not found
2017-06-26 17:04:37.305 INFO 28712 --- [ main] org.hibernate.cfg.Environment : HHH000021: Bytecode provider name : javassist
2017-06-26 17:04:37.373 INFO 28712 --- [ main] o.hibernate.annotations.common.Version : HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
2017-06-26 17:04:37.741 INFO 28712 --- [ main] org.hibernate.dialect.Dialect : HHH000400: Using dialect: org.hibernate.dialect.H2Dialect
2017-06-26 17:04:38.642 INFO 28712 --- [ main] org.hibernate.tool.hbm2ddl.SchemaExport : HHH000227: Running hbm2ddl schema export
2017-06-26 17:04:38.721 INFO 28712 --- [ main] org.hibernate.tool.hbm2ddl.SchemaExport : HHH000230: Schema export complete
2017-06-26 17:04:38.767 INFO 28712 --- [ main] j.LocalContainerEntityManagerFactoryBean : Initialized JPA EntityManagerFactory for persistence unit 'default'
2017-06-26 17:04:39.857 INFO 28712 --- [ main] o.s.s.web.DefaultSecurityFilterChain : Creating filter chain: org.springframework.security.web.util.matcher.AnyRequestMatcher#1, [org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter#ff0e6d4, org.springframework.security.web.context.SecurityContextPersistenceFilter#1a785fd5, org.springframework.security.web.header.HeaderWriterFilter#1d1bf7bf, org.springframework.security.web.csrf.CsrfFilter#748904e8, org.springframework.security.web.authentication.logout.LogoutFilter#650a1aff, org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter#10bf1ec9, org.springframework.security.web.authentication.ui.DefaultLoginPageGeneratingFilter#8f39224, org.springframework.security.web.authentication.www.BasicAuthenticationFilter#7606bd03, org.springframework.security.web.savedrequest.RequestCacheAwareFilter#362a561e, org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter#ad0bb4e, org.springframework.security.web.authentication.AnonymousAuthenticationFilter#70d3cdbf, org.springframework.security.web.session.SessionManagementFilter#4d43a1b7, org.springframework.security.web.access.ExceptionTranslationFilter#919086, org.springframework.security.web.access.intercept.FilterSecurityInterceptor#6b3f4bd8]
2017-06-26 17:04:40.221 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for #ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext#45f45fa1: startup date [Mon Jun 26 17:04:32 CEST 2017]; root of context hierarchy
2017-06-26 17:04:40.323 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/registration],methods=[POST]}" onto public java.lang.String com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.registration(com.o2xp.ats.accountManager.to.ApplicantTO,org.springframework.validation.BindingResult,org.springframework.ui.Model)
2017-06-26 17:04:40.324 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/registration],methods=[GET]}" onto public java.lang.String com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.registration(org.springframework.ui.Model)
2017-06-26 17:04:40.325 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/categories],methods=[GET]}" onto public java.util.List<com.o2xp.ats.accountManager.to.ApplicantTO> com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.getAllApplicants()
2017-06-26 17:04:40.326 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/categories/{id}],methods=[GET]}" onto public org.springframework.http.ResponseEntity<com.o2xp.ats.accountManager.ti.ApplicantTI> com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.getApplicantById(java.lang.Long)
2017-06-26 17:04:40.326 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/login],methods=[GET]}" onto public java.lang.String com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.login(org.springframework.ui.Model,java.lang.String,java.lang.String)
2017-06-26 17:04:40.327 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/ || /welcome],methods=[GET]}" onto public java.lang.String com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.welcome(org.springframework.ui.Model)
2017-06-26 17:04:40.327 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/categories/{id}],methods=[DELETE]}" onto public org.springframework.http.ResponseEntity<java.lang.Void> com.o2xp.ats.accountManager.rest.controllers.ApplicantResource.deleteApplicant(java.lang.Long)
2017-06-26 17:04:40.333 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-06-26 17:04:40.334 INFO 28712 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-06-26 17:04:40.380 INFO 28712 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-06-26 17:04:40.380 INFO 28712 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-06-26 17:04:40.445 INFO 28712 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-06-26 17:04:40.821 INFO 28712 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-06-26 17:04:40.894 INFO 28712 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 8080 (http)
2017-06-26 17:04:40.901 INFO 28712 --- [ main] com.o2xp.ats.accountManager.App : Started App in 9.52 seconds (JVM running for 10.076)
and here is my App :
package com.o2xp.ats.accountManager;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
/**
* Hello world!
*
*/
#SpringBootApplication
#ComponentScan({ "com.o2xp.ats.common.domain", "com.o2xp.ats.common.services", "com.o2xp.ats.common.mapper",
"com.o2xp.ats.accountManager.services", "com.o2xp.ats.accountManager.mapper",
"com.o2xp.ats.accountManager.domain", "com.o2xp.ats.accountManager.rest.controllers",
"com.o2xp.ats.accountManager.validator" })
#EnableJpaRepositories({ "com.o2xp.ats.common.repository", "com.o2xp.ats.accountManager.repository" })
#EntityScan({ "com.o2xp.ats.common.domain", "com.o2xp.ats.accountManager.domain" })
#EnableWebSecurity
public class App extends org.springframework.boot.web.support.SpringBootServletInitializer {
private static final Logger log = LoggerFactory.getLogger(App.class);
public static void main(String[] args) {
SpringApplication.run(App.class);
}
i've seen
If you fine-tune your logging configuration, ensure that the
org.springframework.boot.autoconfigure.security category is set to log
INFO messages, otherwise the default password will not be printed.
into the spring doc but don't know where is the file to modify.
Set logging level at application.properties. Take a look 26.4 Log Levels
logging.level.org.springframework.boot.autoconfigure.security=INFO
You need to add the key and logging level to application.properties.
Have a look here