import java.util.List;

import redis.clients.jedis.Jedis;
public class RedisListJava {
   public static void main(String[] args) {
      //Connecting to Redis server on localhost

      Jedis jedis = new Jedis("localhost", 6379);
      jedis.auth("foobared");
      jedis.select(2);
      jedis.set("foo", "bar");
      System.out.println("Connection to server sucessfully");
      //store data in redis list
      jedis.lpush("tutorial-list", "Redis");
      jedis.lpush("tutorial-list", "Mongodb");
      jedis.lpush("tutorial-list", "Mysql");
     // Get the stored data and print it
     List<String> list = jedis.lrange("tutorial-list", 0 ,5);
     for(int i=0; i<list.size(); i++) {
     System.out.println("Stored string in redis:: "+list.get(i));
     }
 }
}
@@ -178,16 +178,17 @@
 alhost%0D%0A
+ 
 %0D%0A      

prueba 1