@Override
    public void clear() {
        cache.clear();
    }
@Test
    public void testClear() throws Exception {
        EventLoopGroup group = new DefaultEventLoopGroup(1);

        try {
            EventLoop loop = group.next();
            final DefaultDnsCnameCache cache = new DefaultDnsCnameCache();
            cache.cache("x.netty.io", "mapping.netty.io", 100000, loop);
            cache.cache("y.netty.io", "mapping.netty.io", 100000, loop);

            assertEquals("mapping.netty.io", cache.get("x.netty.io"));
            assertEquals("mapping.netty.io", cache.get("y.netty.io"));

            assertTrue(cache.clear("x.netty.io"));
            assertNull(cache.get("x.netty.io"));
            assertEquals("mapping.netty.io", cache.get("y.netty.io"));
            cache.clear();
            assertNull(cache.get("y.netty.io"));
        } finally {
            group.shutdownGracefully();
        }
    }