DEV Community

Shubhangi
Shubhangi

Posted on

The Server You Never Installed πŸ–₯️

You clicked Run.

Console said

Tomcat started on port 8080
Enter fullscreen mode Exit fullscreen mode

Interesting.

Because...

We never downloaded Tomcat.

We never started Tomcat.

We never configured Tomcat.

So, who invited Tomcat?

Spring Boot did.

When you included the web dependency.

But who's Tomcat ?

Its the unpaid intern on the team doing all the work.

Just kidding.

Tomcat is the server actually listening on port 8080. Spring Boot automatically configured an embedded Tomcat server.

Behind one innocent URL...
localhost:8080/hello

This entire chain happens πŸ‘‡


One URL hides an entire request-processing pipeline.

We wrote just 5 lines of code ❌

We just saw 5 lines of code βœ…

Behind the scenes Spring Boot already:

-started Tomcat
-configured Spring MVC
-detected your controller
-registered /hello
-handled the HTTP request
-sent the response

We focused on the business logic.

Spring Boot handled the rest.

But why learn the internals when Spring Boot handles everything ?

Because real engineering starts the day something doesn't work.

404:

Application won't start.

Wrong port.

Controller not detected.

Slow startup.

Those problems can't be solved by memorising annotations.

They require understanding what happens behind them.

So here's one Takeaway for you :

To be more grateful πŸ’

To springboot

And to me.

You're welcome.

Top comments (0)