Guava CacheBuilder not working as expected
<p>Hi I am new to google guava collections so I need collection which will expire some time period.So I have write following code but it is not removing data after expire time.Can anyone tell me what is the issue of code.</p>

<pre><code>Cache&lt;String, Object&gt; cache = CacheBuilder.newBuilder()
                .expireAfterAccess(2, TimeUnit.MILLISECONDS)
                .build();
        Object object = new Object();            
        cache.put(object.getId(), object);
        System.out.println("size :" + cache.size());
        Thread.sleep(50000);
        System.out.println("After Size :" + cache.size());
</code></pre>

<p>I need to add objects to map and after expire time period it will remove from map.But above code after and before thread contains object in map.</p>