Skip to Main Content

MongoByte MongoDB Logo

Welcome to the new MongoDB Feedback Portal!

{Improvement: "Your idea"}
We’ve upgraded our system to better capture and act on your feedback.
Your feedback is meaningful and helps us build better products.

Status Completed
Categories Documentation
Created by Guest
Created on Jul 27, 2023

Missing piece of code in "Connect to Cluster"-Example

I think there is a missing piece of code in the generated code-example to connect to the atlas-cluster via Node.js driver and X.509: The definition for "const credentials" should be "const credentials = fs.readFileSync('')" instead of "const credentials = ''"
  • Guest
    Aug 3, 2023
    Hi Alexander, this code sample will work for Node.js versions 4.0+. Are you using a version older than this? If so, the code sample will change when your version is selected.
  • Guest
    Jul 28, 2023
    Hi Alexander, thank you for bringing this to our attention. We're working on a fix to this code sample now.