I have an API using the same Redis server serving requests at 100ms. I am aware that in a production environment the cache should be hosted closer.
I am absolutely certain this is not the cause of the 35s return time for 12 objects. I am returning a list of countries with 4 properties. I only have 12 countries in the list. It is not a process heavy call, It returns 12 countries in 35 seconds. This happens on first load after which it comes down to 10s. Leaving it a while and returning to the page, the request is back up to 30+ seconds.
I am not sure if there are additional connection checks that could be the cause or whether it may be the storing of data from the database into the cache.
My application runs very slowly when using Redis Cloud database. When I use my local Redis, everything is fine, but as soon as I use Redis cloud, it can take up to 30 seconds for a call returning 12 basic objects.
I have not changes anything on my default Redis settings. My only change is updating the connection string in appsettings.json I am using the following mask [server].east-us-mz.azure.cloud.redislabs.com:[port],user=[userName],password=[password]
My site is running locally on a PC in the UK and the Redis database is on US-East Azure server, so I expect some latency, but 30 seconds is high.