fix(api): use correct field lengths for file processors#459
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
📜 Recent review details🧰 Additional context used📓 Path-based instructions (1)booklore-api/src/**/*.java📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧠 Learnings (6)📓 Common learnings📚 Learning: 2026-04-02T09:25:37.417ZApplied to files:
📚 Learning: 2026-04-02T09:25:48.330ZApplied to files:
📚 Learning: 2026-03-24T18:46:47.249ZApplied to files:
📚 Learning: 2026-04-10T08:15:37.436ZApplied to files:
📚 Learning: 2026-04-02T09:25:48.330ZApplied to files:
🔇 Additional comments (6)
📝 WalkthroughWalkthroughThe PR corrects metadata truncation lengths across 6 file processors (Azw3, Cbx, Epub, Fb2, Mobi, PDF) to align with actual database field constraints. ISBN-13 truncates to 13 characters, ISBN-10 to 10, language to 10, ASIN to 10, and description to 5000 characters, addressing inconsistencies that caused validation failures. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Suggested labels
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Description
The various processors truncate extracted metadata fields so they properly fit in database metadata fields.
However, the ASIN, ISBN, and language fields were improperly truncated, and were too long which caused database errors.
This updates the truncation length to 10 for language, 10 for ASIN, 10 for ISBN10, and 13 for ISBN13.
Linked Issue: Fixes #458
Changes
Summary by CodeRabbit