Need variants of ExecuteInTx and ExecuteTx that take a `fn(context.Context, ...)` as arg

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

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
go
Domain
api, database

Research direction

Start by locating the ExecuteTx and ExecuteInTx definitions and their existing callback signatures. Review nearby tests or call sites to understand the current behavior, then add variants whose callbacks receive context.Context while keeping the requested transaction behavior consistent. Done means the new APIs accept context-aware callbacks and are covered by the relevant existing tests.

Written by the indexing model from the issue text.

Description

The ExecuteTx and ExecuteInTx APIs take a function callback that only takes either no argument or a tx object.

We want to pass a callback instead that takes the context as argument.

cc @rafiss

Dominant language
Go
Stars
170
Forks
78
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

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.

More from cockroachdb/cockroach-go

All issues in cockroachdb/cockroach-go

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.