returning redis resource on exception