- Newest
- Most votes
- Most comments
Neptune has two different interfaces - both a control plane and a data plane. The control plane is accessible via public endpoints, so you'll need access to the Internet from your Lambda function to access these endpoints.
The data plane requires direct access to the Neptune instances within your Neptune cluster. These can only be accessed from within the VPC where Neptune is hosted.
What you're attempting to access is the DescribeDbClusters API, which is a control plane API. Your Lambda function will either need Internet access for this, or you'll need an RDS VPC Endpoint to allow access to these APIs: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/vpc-interface-endpoints.html. (Note that RDS is referenced here as Neptune shares a control plane with the RDS service)
Relevant content
- Accepted Answerasked 2 years ago
- AWS OFFICIALUpdated 4 years ago
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 months ago
I don't understand why the same code executed in a Jupyter Notebook (deployed in the same VPC and subnet) works, but in the Lambda function it returns that error. I understand that if the Lambda function doesn't have internet access, the Jupyter Notebook shouldn't either. Am I wrong?
If you're using a Neptune Notebook instance (which is based on a SageMaker Notebook instance), the Internet egress is separate from VPC access. The underlying instance is hosted in a SageMaker service-team-owned VPC and Internet (by default) egresses through the service team VPC. Access to the user VPC goes through an ENI attached to the notebook instance and there's a separate network route configured at the OS level to direct traffic destined for the VPC CIDR through that ENI.