Examples of RedisBasedCache


Examples of org.dayatang.cache.redis.RedisBasedCache

    @Test
    @Ignore
    public void testRedisCache() throws IOException {
        String file = getClass().getResource("/aaa.jpg").getFile();
        Cache redisCache = new RedisBasedCache("127.0.0.1", 6379);
        ImageAccess imageAccess = new CacheImageAccess(redisCache);
        String uuid = imageAccess.saveImageFile(FileUtils.readFileToByteArray(new File(file)), "aaa.jpg");
        System.out.println(uuid);
        assertTrue(uuid != null);
        ImageFile imageFile = imageAccess.getImageFile(uuid);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.