foneasfen.blogg.se

App startup time
App startup time










That can’t be right?!įiguring out what’s was going on wasn’t that hard. So in it takes about 10 seconds in total to connect to a locally running (almost empty) MongoDB instance. In that line, it is still trying to set up the proper MongoDB connection. I double checked my settings, but you can see it’s really trying to connect to a locally running instance by the log messages stating it tries to connect to localhost on 27017.Ī couple of lines down it makes another jump of about 4 seconds. After about five seconds, the application logs an entry when it tries to setup a connection to a locally running MongoDB instance. The first jump is after handling the bean integrationGlobalProperties. What’s interesting about the above log is that it makes a couple of multi-second jumps. 23:53:21,293 INFO - Checking unique service notification from repository: 23:53:15,829 INFO - Cluster created with settings ] to localhost:27017 Let’s take a look at a snippet of the log: 23:53:10,293 INFO - Bean 'integrationGlobalProperties' of type is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying) In the log file, there were a couple of strange jumps in time that I wanted to investigate further. Just leveraging the logging framework with the Spring Boot application gives you pretty good insight into what’s going on during the launch of the application.

app startup time

Most of us run the entire application and its dependencies (MongoDB and Elasticsearch) on our laptop and the application requires no remote connections, so I was always wondering what the application was doing during those 60+ seconds. My teammates always said they found it strange, as well, but nobody bothered to spend the time to investigate the cause.

app startup time

When I started the application with IntelliJ, it always took more than 60 seconds to start the deployed application, which I thought was pretty long given the size of the application. Spring Boot applications can run perfectly fine with an embedded container, but since we deploy the application within a Tomcat container in our acceptance and production environments, I always stick to the same deployment manner on my local machine.Īfter joining the project in March, one thing always kept bugging me. During my normal development cycle, I always start the application from within IntelliJ by means of a run configuration that deploys the application to a local Tomcat container. At my current project, we’re developing an application based on Spring Boot.












App startup time