Made minor modifications
1.) Retry if connection fails
2.) Removed unnecessary print commands
3.) socket connection redis code enhanced