SHARE
TWEET

Untitled

a guest Jul 22nd, 2019 74 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @Getter
  2. public class JedisSettings {
  3.  
  4.     private final String address;
  5.     private final int port;
  6.     private final String password;
  7.     private final boolean auth;
  8.  
  9.     private final JedisPool jedisPool;
  10.  
  11.     public JedisSettings(String address, int port, boolean auth, String password) {
  12.         this.address = address;
  13.         this.port = port;
  14.         this.password = password;
  15.         this.auth = auth;
  16.  
  17.         this.jedisPool = new JedisPool(this.address, this.port);
  18.         if(auth) {
  19.             this.jedisPool.getResource().auth(this.password);
  20.         }
  21.     }
  22. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top