feat(api): switch createDb to WebSocket Pool driver to enable applyTransition transactions
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 38/100
- Tipo de issue
- Funcionalidade
- Clareza
- Razoavelmente clara
- Status de atividade
- Pouca atividade
- Stack de tecnologia
- postgres, typescript
Direção de pesquisa
Start by reading packages/api/src/db/index.ts and packages/api/src/lib/lifecycle/applyTransition.ts, then verify the nodejs_compat setting in wrangler.jsonc. Compare the current neon-http latency with neon-serverless, check the Cloudflare Workers integration and HTTP-only feature constraints, and run the 216+ test integration suite against staging. Done means the driver choice is validated, applyTransition is transactional if switched, and the comment and measurements are updated.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Summary
packages/api/src/lib/lifecycle/applyTransition.ts documents itself as "sequential, not transactional" because @neondatabase/serverless HTTP driver (via drizzle-orm/neon-http) does not support db.transaction(). A crash between insertReview and updateArtifactStatus could leave a stranded review row that bumps the count toward a future publish without flipping the artifact.
Requirements
- Evaluate switching
createDb(packages/api/src/db/index.ts) fromneon-httptoneon-serverless(WebSocket Pool driver) - If switching, measure cold/warm latency impact (current is ~360ms cold / <200ms warm on neon-http)
- Wrap
applyTransitionbody indb.transaction(async tx => { ... })once Pool driver is in place - Update the comment in
applyTransition.tsto remove the TODO - Re-run the full integration test suite (216+ tests) against staging to confirm no regressions
Context
Flagged in the Plan 1 final review. At v1 admin write volumes the non-atomicity is acceptable; this issue gets more urgent as concurrent write volumes grow.
Implementation Notes
The Cloudflare Workers + neon-serverless integration requires nodejs_compat flag in wrangler.jsonc — verify before committing to the swap. Some HTTP-only Neon features may not be available via WebSocket.
- Linguagem predominante
- HTML
- Estrelas
- 33
- Forks
- 107
- Merge médio
- 14h 6min
- PRs com merge (30d)
- 19
Preparar o ambiente
- Inclui um Dockerfile ou arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de USRSE/usrse.github.io
-
update community awardsAberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
USRSE/usrse.github.io#2117 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 63/100
USRSE/usrse.github.io#2115 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Broken URLs on the websiteAbertabroken-links
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
USRSE/usrse.github.io#2099 · 2 comentários ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
USRSE/usrse.github.io#2085 · 2 comentários ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 85/100
USRSE/usrse.github.io#2001 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de USRSE/usrse.github.io
Issues semelhantes
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
genfeedai/genfeed.ai#11828 ·
Mantenedores costumam responder em até 1 dia
-
enhancement good first issue help wanted
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 83/100
NOAA-OWP/ngen#1110 · 2 comentários ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
ExpressionEngine/ExpressionEngine#5493 ·
Mantenedores costumam responder em até 5 dias
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 95/100
-
llama.cpp: streamed tool call arguments get cut off when a chunk has several tool call deltasAbertaintegration: llama_cpp
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
home-assistant/core#195670 · 2 comentários ·
Mantenedores costumam responder em até 1 dia