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 Submitted
Created by Guest
Created on Jan 26, 2024

Support for MongoDB Package in Edge Computing Environments

The increasing adoption of edge computing and serverless architectures necessitates compatible database solutions. The MongoDB Node.js package currently faces compatibility challenges in edge environments, such as Vercel Edge Functions, due to its reliance on certain Node.js APIs and JavaScript features unsupported in edge runtimes. Discussions on platforms like Stack Overflow and GitHub highlight the need for a MongoDB solution tailored for edge computing. Although the MongoDB Data API offers a potential workaround, it lacks the full functionality and efficiency of the native MongoDB driver when used in edge contexts. I propose the development of an edge-optimized MongoDB package or library that aligns with the constraints of edge runtimes, minimizing dependency on unsupported APIs and leveraging web-friendly APIs like fetch. This would significantly benefit developers by providing a seamless, efficient way to integrate MongoDB into serverless and edge applications, enhancing performance and user experience. This request is supported by community feedback and underscores the importance of evolving MongoDB’s offerings to meet the demands of modern web architectures and serverless computing. References: * https://github.com/arashsheyda/nuxt-mongoose/issues/32 * https://stackoverflow.com/questions/75423777/is-there-anyway-to-get-mongodb-to-work-on-vercel-edge-serverless-functions * https://github.com/drivly/mongo-fetch