Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not able to connect redis production server #514

Open
jignesh-mpc91 opened this issue Nov 4, 2022 · 1 comment
Open

Not able to connect redis production server #514

jignesh-mpc91 opened this issue Nov 4, 2022 · 1 comment

Comments

@jignesh-mpc91
Copy link

jignesh-mpc91 commented Nov 4, 2022

I am using latest version of StackExchange.Redis.Extensions. I am able to connect with local redis, but not able to connect with production redis. Our production server is hosted in Singapore.

I am sharing my code with you. Please correct me.

  • Local connection working properly for me, same code I am using for production but not working.
var redisConfigurationsProduction = new RedisConfiguration[]
        {
        new RedisConfiguration
            {
                AbortOnConnectFail = false,
                Hosts = new[] { new RedisHost { Host = "singapore-redis.render.com", Port = 6379 } },
                AllowAdmin = false,
                ConnectTimeout = 5000,
                Database = 0,
                PoolSize = 10,
                IsDefault = true,
                Password= "*******"
            }
        };

services.AddStackExchangeRedisExtensions<NewtonsoftSerializer>((options) =>
{
    return redisConfigurationsProduction;
});

var app = builder.Build();

var redisDatabase = app.Services.GetRequiredService<IRedisDatabase>();
  • When I am trying to connect Production server and check IsConnected property from Multiplexer, it always shows me false. But it shows true for local redis connection.

Screenshot 2022-11-04 at 2 36 57 PM

@imperugo Please suggest me.

@jignesh-mpc91
Copy link
Author

@imperugo any update??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant