Open exalate-issue-sync[bot] opened 2 years ago
Eric Harmeling (ericharmeling) commented: Paul Kernfeld I opened this issue as a follow-up to our conversation on 1/12/22. Let me know if I left anything out.
Paul Kernfeld (kernfeld-cockroach) commented: Paul Kernfeld I should take some time to figure out a good way to do this. What examples need it? Where should the retry logic go?
Eric Harmeling (ericharmeling) commented:
Our simple CRUD and hello world apps are intended for users just getting started with CockroachDB. Most users trying CockroachDB for the first (or second) time don’t need to think about retrying transactions.
We should consider removing the explicit transaction retry logic from our simple CRUD sample apps (e.g., https://github.com/cockroachlabs/example-app-node-postgres/blob/main/app.js#L11). Instead, we could provide language-specific, driver-agnostic snippets for JavaScript, Python, Go, and Java in a dedicated section on retries (probably on this page). We can add a note to each tutorial page about our recommendation to implement retries in production. We can also reference these examples in the production checklist (which already lists transaction retries).
Jira Issue: DOC-2301