guava/laravel-sequence
A Laravel package for generating sequential numbers for models, invoices, orders, and other records, with configurable prefixes, formatting, and database-backed, concurrency-safe increments through a simple API.
laravel-sequence targets the common "human-readable, gap-free-ish sequential number per model/scope" need so engineering doesn't reinvent locking and race-condition logic.Consider adoption when:
Look elsewhere when:
For executives: This is a small, focused open-source dependency for generating sequential numbers like invoice and order IDs. The new 1.2.0 release adds Laravel 12 support, which keeps our upgrade path open and removes a potential blocker for our next framework upgrade. It's low-cost to adopt, actively maintained, and reduces the risk of bugs in customer-facing numbering — a good trade of build effort for a stable building block.
For engineering: laravel-sequence (GuavaCZ) handles concurrency-safe sequential generation scoped per model/tenant, so we don't hand-roll locking for invoice/order numbering. 1.2.0 is a minor, additive release: Laravel 12 compatibility plus cosmetic style fixes — no breaking changes or deprecations. Recommendation: adopt behind an internal wrapper interface to keep it swappable, validate gap/locking behavior against our DB and workload, and pin the version. Reassess if requirements grow to globally distributed IDs or strict gap-free regulatory serials.
How can I help you explore Laravel packages today?