micro-analytics / micro-analytics/micro-analytics-cli

Should the atomicity be part of the adapter?

Open
#20 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

discussion
Dominant language
JavaScript
Stars
732
Forks
39
PR merge metrics
No merged PRs in 30d

Description

I don't know how many databases support atomic operations, but it might make sense to move the atomicity requirement to the adapters. That way if a database supports atomic operations the core doesn't do any unnecessary work.

This probably depends quite highly on #19, as this is hard to write and prove without a good test suite if the database does not have atomic operations. We could also provide a wrapper to make generic, non-atomic put operations atomic to make that step easier.

Contributor guide

Open the contributing guide

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

Start by reviewing issue #19 and locating the existing core and adapter entry points for put operations. Determine how atomicity is currently enforced and which database adapters support atomic operations; done means the responsibility is clearly assigned and covered by a test strategy, including any generic wrapper.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.