Garnish is an example of a simple varnish implementation which should demonstrate.
It supports only Cache-Control
header and keeps all the data in memory. It means that after restart of the application all data will disappear.
The project was described in more details in the article.