- ABP Framework version: v3.3.2
- UI type: Angular
- DB provider: EF Core
- Tiered (MVC) or Identity Server Seperated (Angular): yes
- Exception message and stack trace:
- Steps to reproduce the issue:
Hi, I have set the redis cache to false in appsettings.json. However, I still got this error when deploying the API into UAT server, this issue does not happen in localhost.
appsettings.json:
"Redis": {
"Configuration": "127.0.0.1",
"IsEnabled": "false"
},
Error:
Volo.Abp.AbpInitializationException: An error occurred during ConfigureServices phase of the module SingHealth.DigitalPlatform.DigitalPlatformHttpApiHostModule, SingHealth.DigitalPlatform.HttpApi.Host, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null. See the inner exception for details.
---> StackExchange.Redis.RedisConnectionException: It was not possible to connect to the redis server(s). UnableToConnect on 127.0.0.1:6379/Interactive, Initializing/NotStarted, last: NONE, origin: BeginConnectAsync, outstanding: 0, last-read: 1s ago, last-write: 1s ago, keep-alive: 60s, state: Connecting, mgr: 10 of 10 available, last-heartbeat: never, global: 6s ago, v: 2.0.593.37019
at StackExchange.Redis.ConnectionMultiplexer.ConnectImpl(Object configuration, TextWriter log) in C:\projects\stackexchange-redis\src\StackExchange.Redis\ConnectionMultiplexer.cs:line 942
20 Answer(s)
-
0
Abp: 4.2.1
Hi there,
The problem is that abp platform forces to use Redis in production mode. I belive this is a bug, or there is something else on that. Commenting lines are solved this issue for me (see the code below).
private void ConfigureRedis( ServiceConfigurationContext context, IConfiguration configuration, IWebHostEnvironment hostingEnvironment) { if (!hostingEnvironment.IsDevelopment()) { /*var redis = ConnectionMultiplexer.Connect(configuration["Redis:Configuration"]); context.Services .AddDataProtection() .PersistKeysToStackExchangeRedis(redis, "edelivery2-Protection-Keys");*/ } }
-
0
Hi @maliming, why redis is mandatory for tiered project? this is not mentioned in the documentation:
https://docs.abp.io/en/abp/latest/Redis-Cache
if it is because of key storage provider, we can replace it by entity framework core, right?
https://docs.microsoft.com/en-us/aspnet/core/security/data-protection/implementation/key-storage-providers?view=aspnetcore-5.0&tabs=visual-studio
please help check and confirm.
-
0
Please help me to resolve this issue asap .
Appsetting configuration.
Error:-
StackExchange.Redis.RedisConnectionException: 'It was not possible to connect to the redis server(s). UnableToConnect on localhost:6379/Interactive, Initializing/NotStarted, last: NONE, origin: BeginConnectAsync, outstanding: 0, last-read: 0s ago, last-write: 0s ago, keep-alive: 60s, state: Connecting, mgr: 10 of 10 available, last-heartbeat: never, global: 5s ago, v: 2.2.4.27433'
Thanks