Remove Redis config on startup template
host folder in startup template assumes redis configuration which results in below error on launching HostAPI and Identity Server projects individually.

https://github.com/abpframework/abp/blob/9bfaede7a1e1d2ab2886e5c4cc278103480967d0/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.HttpApi.Host/appsettings.json#L9-L11
Error text:
2020-08-11 12:46:44.129 +03:00 [WRN] 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: 2s ago, last-write: 2s ago, keep-alive: 60s, state: Connecting, mgr: 10 of 10 available, last-heartbeat: never, global: 62s ago, v: 2.0.593.37019
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: 2s ago, last-write: 2s ago, keep-alive: 60s, state: Connecting, mgr: 10 of 10 available, last-heartbeat: never, global: 62s ago, v: 2.0.593.37019
at StackExchange.Redis.ConnectionMultiplexer.ConnectImplAsync(Object configuration, TextWriter log) in C:\projects\stackexchange-redis\src\StackExchange.Redis\ConnectionMultiplexer.cs:line 825
at Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.ConnectAsync(CancellationToken token)
at Volo.Abp.Caching.StackExchangeRedis.AbpRedisCache.SetManyAsync(IEnumerable`1 items, DistributedCacheEntryOptions options, CancellationToken token)
at Volo.Abp.Caching.DistributedCache`2.SetManyAsync(IEnumerable`1 items, DistributedCacheEntryOptions options, Nullable`1 hideErrors, CancellationToken token)
https://github.com/abpframework/abp/blob/9bfaede7a1e1d2ab2886e5c4cc278103480967d0/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.HttpApi.Host/MyProjectNameHttpApiHostModule.cs#L44
HttpApi.Host project used redis for distributed caching. Should not be removed.
so I guess it should be documented to install redis, and launching this project will load for 60 seconds until it times out.
Which document?
https://docs.abp.io/en/abp/latest/Startup-Templates/Module#separated-deployment-databases-scenario
https://docs.abp.io/en/abp/latest/Startup-Templates/Application#httpapi-host-project
OK. I will update the document. Thanks.
For others to know how to install redis on Windows.
To install Redis on your local machine:
-
Install the Chocolatey Redis package.
-
Run redis-server from a command prompt.
I don't think it is necessary. Developers should know how to configure the development environment(like install redis.)
Maybe in addition to documenting Redis as a pre requirement, also add redis to the module template docker files? So by default this (all?) requirements are met when starting the docker containers for development.
Why do we have to have Redis on development environment? tempkey.rsa works well and offers the least resistance to get started. Redis isn't native on Windows so you have to use it through Windows Subsystem for Linux or use old versions or Redis etc. which makes it very messy when it used to work out-of-the-box before.
Can we enable it for production only instead?
Edit:
Okay, @realLiangshiwei would you be able to update the docs to include a link to memurai for Windows users? Maybe this is an alternative to switching it off on dev.
Also, how long has the startup template had redis included? My project was created back in abp v0.21 and this seems to have slipped through until now! 🤦
Can not be used for production only, there will be inconsistent cache problems.
And I don't think installing Redis is a problem, developers should know this knowledge
use this
https://www.memurai.com/get-memurai
so crazy that without a redis, you can even not make a bookstore. - -!
so crazy that without a redis, you can even not make a bookstore. - -!
No, you can do. Just don't use a tiered solution for MVC (or don't use separate IDS for angular). In this way you will have a single server side application and you don't need to a distributed cache in development.
If you want to separate them, there will be two server applications and somehow they should use a shared cache. This is why the such a tiered startup template requires redis. Otherwise, you will have inconsistent caches between applications. It is just that simple. What's the problem here?
so crazy that without a redis, you can even not make a bookstore. - -!
No, you can do. Just don't use a tiered solution for MVC (or don't use separate IDS for angular). In this way you will have a single server side application and you don't need to a distributed cache in development.
If you want to separate them, there will be two server applications and somehow they should use a shared cache. This is why the such a tiered startup template requires redis. Otherwise, you will have inconsistent caches between applications. It is just that simple. What's the problem here?
haha, i just say redis now is more than why it is created.
For the "windows fan" looking for the redis.msi installer: https://github.com/microsoftarchive/redis/releases
Everything works 100% after installing Redis. Thank you @buaziz / @hikalkan