Skip to content

Update Next to use Mongo selector instead of Mongoose #130

Open
@eric-burel

Description

@eric-burel
  • Create a single Mongo Client instance and expose it somewhere
  • Pass this Mongo client whenever you create a connector
  • Improve "filterFunction" to support both Mongo and Mongoose via a generic type? A Mongo connector was created in Feature/mongo objectid #129 but types are not yet perfect
  • Duplicate tests created for mongooseConnector for mongoConnector

Contrary to Mongoose, Mongo node driver do not provide a global object. You have to create your own global client, that you can pass around to Vulcan, and connect it as usual in the "connectToAppDb" middleware everytime a serverless function is called (if its not yet connected of course).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions