Package org.springframework.data.redis.connection.jredis

Examples of org.springframework.data.redis.connection.jredis.JredisConnectionFactory.afterPropertiesSet()


    // JRedis
    JredisConnectionFactory jredisConnFactory = new JredisConnectionFactory();
    jredisConnFactory.setPort(SettingsUtils.getPort());
    jredisConnFactory.setHostName(SettingsUtils.getHost());
    jredisConnFactory.afterPropertiesSet();

    StringRedisTemplate templateJR = new StringRedisTemplate(jredisConnFactory);
    DefaultRedisMap mapJR = new DefaultRedisMap("bound:key:mapJR", templateJR);
    // Skip list and set. Rename in Collections uses Redis tx, not supported by JRedis
View Full Code Here


    jedisConnFactory.afterPropertiesSet();

    // JRedis
    JredisConnectionFactory jredisConnFactory = new JredisConnectionFactory(new JredisPool(SettingsUtils.getHost(),
        SettingsUtils.getPort()));
    jredisConnFactory.afterPropertiesSet();

    // Lettuce
    LettuceConnectionFactory lettuceConnFactory = new LettuceConnectionFactory();
    lettuceConnFactory.setPort(SettingsUtils.getPort());
    lettuceConnFactory.setHostName(SettingsUtils.getHost());
View Full Code Here

    jackson2JsonPersonTemplate.afterPropertiesSet();

    // JRedis
    JredisConnectionFactory jredisConnFactory = new JredisConnectionFactory(new JredisPool(SettingsUtils.getHost(),
        SettingsUtils.getPort()));
    jredisConnFactory.afterPropertiesSet();

    RedisTemplate<String, String> genericTemplateJR = new StringRedisTemplate(jredisConnFactory);
    RedisTemplate<String, Person> xGenericTemplateJR = new RedisTemplate<String, Person>();
    xGenericTemplateJR.setConnectionFactory(jredisConnFactory);
    xGenericTemplateJR.setDefaultSerializer(serializer);
View Full Code Here

    rawTemplate.afterPropertiesSet();

    // jredis
    JredisConnectionFactory jredisConnFactory = new JredisConnectionFactory(new JredisPool(SettingsUtils.getHost(),
        SettingsUtils.getPort()));
    jredisConnFactory.afterPropertiesSet();

    RedisTemplate<String, String> stringTemplateJR = new StringRedisTemplate(jredisConnFactory);
    RedisTemplate<String, Person> personTemplateJR = new RedisTemplate<String, Person>();
    personTemplateJR.setConnectionFactory(jredisConnFactory);
    personTemplateJR.afterPropertiesSet();
View Full Code Here

    rawTemplate.afterPropertiesSet();

    // JRedis
    JredisConnectionFactory jredisConnFactory = new JredisConnectionFactory(new JredisPool(SettingsUtils.getHost(),
        SettingsUtils.getPort(), defaultPoolConfig));
    jredisConnFactory.afterPropertiesSet();

    RedisTemplate genericTemplateJR = new RedisTemplate();
    genericTemplateJR.setConnectionFactory(jredisConnFactory);
    genericTemplateJR.afterPropertiesSet();
View Full Code Here

    assumeTrue(key1 instanceof String && value1 instanceof String);
    // JRedis does not support pExpire
    JredisConnectionFactory factory = new JredisConnectionFactory();
    factory.setHostName(SettingsUtils.getHost());
    factory.setPort(SettingsUtils.getPort());
    factory.afterPropertiesSet();
    final StringRedisTemplate template2 = new StringRedisTemplate(factory);
    template2.boundValueOps((String) key1).set((String) value1);
    template2.expire((String) key1, 10, TimeUnit.MILLISECONDS);
    Thread.sleep(15);
    // 10 millis should get rounded up to 1 sec if pExpire not supported
View Full Code Here

    // JRedis
    JredisConnectionFactory jRedisConnectionFactory = new JredisConnectionFactory();
    jRedisConnectionFactory.setPort(port);
    jRedisConnectionFactory.setHostName(host);
    jRedisConnectionFactory.setDatabase(2);
    jRedisConnectionFactory.afterPropertiesSet();

    return Arrays.asList(new Object[][] { { jedisConnFactory }, { lettuceConnFactory }, { srpConnFactory },
        { jRedisConnectionFactory } });
  }
View Full Code Here

    // JRedis
    JredisConnectionFactory jRedisConnectionFactory = new JredisConnectionFactory();
    jRedisConnectionFactory.setPort(port);
    jRedisConnectionFactory.setHostName(host);
    jRedisConnectionFactory.setDatabase(2);
    jRedisConnectionFactory.afterPropertiesSet();

    return Arrays.asList(new Object[][] { { jedisConnFactory }, { lettuceConnFactory }, { srpConnFactory },
        { jRedisConnectionFactory } });
  }
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.