Skip to content

fix: restore bfj v8 buffer params to prevent export hang [DX-1002]#2344

Merged
Tyler Pina (tylerpina) merged 2 commits into
mainfrom
fix/dx-1002-bfj-buffer-params
Jul 21, 2026
Merged

fix: restore bfj v8 buffer params to prevent export hang [DX-1002]#2344
Tyler Pina (tylerpina) merged 2 commits into
mainfrom
fix/dx-1002-bfj-buffer-params

Conversation

@tylerpina

@tylerpina Tyler Pina (tylerpina) commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

DX-1002

Summary

  • contentful space export hangs indefinitely at "Writing data to file" on large exports when using bfj 9.x
  • bfj 9.x reduced DEFAULT_BUFFER_LENGTH from 1024 → 256 and yieldRate from 16384 → 1024; on data-heavy exports the buffer fills before the stream can drain, causing bfj's tryer loop to spin forever with no timeout
  • Explicitly passing the bfj v8 values (bufferLength: 1024, yieldRate: 16384) restores pre-regression behavior while keeping the CVE-2026-1615 security fix in place

Test plan

  • All 49 existing unit tests pass (npm run test:unit)
  • Manually run contentful space export against a space with 3,000+ entries and confirm the export completes without hanging
  • Verify exported JSON file is valid and complete
  • Confirm no regression for small exports (the params are safe across all export sizes)

Generated with Claude Code

@tylerpina
Tyler Pina (tylerpina) requested a review from a team as a code owner July 21, 2026 19:24
bfj 9.x reduced DEFAULT_BUFFER_LENGTH from 1024 to 256 and yieldRate
from 16384 to 1024. On large exports these smaller values fill the
buffer before the stream can drain, causing bfj's tryer loop to spin
indefinitely with no timeout.

Explicitly passing the v8 values restores the pre-regression behavior
without reverting the CVE-2026-1615 security fix.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@tylerpina
Tyler Pina (tylerpina) force-pushed the fix/dx-1002-bfj-buffer-params branch from fcb2108 to 92ad8e5 Compare July 21, 2026 19:33
@tylerpina
Tyler Pina (tylerpina) enabled auto-merge (squash) July 21, 2026 21:02
@tylerpina
Tyler Pina (tylerpina) merged commit 402152b into main Jul 21, 2026
11 checks passed
@tylerpina
Tyler Pina (tylerpina) deleted the fix/dx-1002-bfj-buffer-params branch July 21, 2026 21:03
@contentful-automation

Copy link
Copy Markdown

🎉 This PR is included in version 8.1.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants