Below are the errors from CR service and also a detailed description of the setup.
Note:- Cloud Run and REDIS instance are co-located in the same region
Cloud Run Configuration
REDIS Configuration
REDIS Client / App Code
1. Using NEST JS REDIS library
Hello @dheerajpanyam ,
Welcome to Google Cloud Community!
The error message you're encountering, "Unhandled error event: Error: getaddrinfo ENOTFOUND redis," suggests that the DNS name "redis" cannot be resolved. This indicates a possible misconfiguration.
Here are some troubleshooting steps to consider:
1. Ensure your NestJS Redis library's host configuration matches either the private IP address or the hostname of your Redis instance in Cloud Memory Store. Using a generic hostname like "redis" may lead to DNS resolution issues if it isn't correctly mapped to your Redis instance's IP address, or if there isn't a corresponding DNS entry within your VPC network.
2. Considering you're using Direct VPC Egress rather than a Serverless VPC Connector, make sure your Cloud Run service's VPC egress is configured correctly to communicate with Google Cloud services, such as Cloud Memory Store. Note that Direct VPC Egress is currently in Preview, so there might be limitations or issues that are not fully documented yet.
3. Check that your Cloud Run service and Redis instance have compatible network security configurations to allow traffic between them. This includes checking for any firewall rules that might block traffic between your Cloud Run instances and the Redis instance.
Should these steps not resolve the issue, consider contacting Google Cloud support for further assistance.
Thanks @juliadeanne Let me troubleshoot by following your steps.