Skip to content

emreyildirim53/varnish-caching

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What is Varnish Caching? You can learn it in my medium post: Varnish nedir, nasıl çalışır?

Without Varnish

  • Create docker build
➜  varnish-demo git:(master)   cd application
➜  application git:(master)    docker build -t application .
  • Run the application you built.
➜  application git:(master)    docker run -e "SPRING_PROFILES_ACTIVE=dev" -p 8080:8080 -t application

Started Spring Boot

  • Page test OK

Started Spring Boot

With Varnish

  • Create docker build and run application
➜  varnish-demo git:(master) docker-compose up --build 

Started Spring Boot

  • Page test OK

Started Spring Boot

Load Test with Apache Benchmark

  • Let's put both apps into load test

Without Varnish: at port 8080, with Varnish: at port 8000

➜  application git:(master)    ab -n 5000 -c 100 http://localhost:8080/
➜  varnish-demo git:(master)   ab -n 5000 -c 100 http://localhost:8000/
Without Varnish With Varnish

About

What is varnish caching? How does it work? What's the difference with the alternatives?

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published