In the Heroku docs, they have listed some example code for constructing a JedisPool instance from Java.
https://devcenter.heroku.com/articles/heroku-redis#connecting-