OpenFn / OpenFn/adaptors

mongo: expose connection options

Open
#360 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
24
Forks
41
Avg merge
3d 13h
Merged PRs (30d)
12

Description

Mongo supports a bunch of connection options.

At the moment, we hard code w (write concern "majority") and retryWrites (true)

These may or may not be appropriate - the point is they should be option driven.

Mongo supports loads of connection options and I don't think we want to expose them all on config. It may be sensible to have a setConnectionOptions operation or something to allow users to drive this. I feel like mapping them all to config us pointless and pollutes the options, making important things harder to find.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named in the issue. Start by locating the Mongo adaptor's connection setup and existing configuration handling, then inspect how w and retryWrites are hard-coded. Done should be demonstrated by tests showing callers can control these options through a focused API without requiring every Mongo option to be exposed.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, mongodb
Domain
databases
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.