How to check if is anonymous user's first visit to site when using varnish
The varnish caching will not work if you use cookies : http://systemsarchitect.net/2013/07/08/reading-php-session-from-varnish-cache/