PHPackages                             optimistdigital/laravel-scout-batch-searchable - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. optimistdigital/laravel-scout-batch-searchable

ActiveLibrary[Search &amp; Filtering](/categories/search)

optimistdigital/laravel-scout-batch-searchable
==============================================

This Laravel package adds a BatchSearchable trait to allow batching Scout updates.

2.2.4(1y ago)3112.5k↓54.9%7[1 issues](https://github.com/outl1ne/laravel-scout-batch-searchable/issues)MITPHPPHP &gt;=7.3.0

Since Sep 13Pushed 1y ago1 watchersCompare

[ Source](https://github.com/outl1ne/laravel-scout-batch-searchable)[ Packagist](https://packagist.org/packages/optimistdigital/laravel-scout-batch-searchable)[ RSS](/packages/optimistdigital-laravel-scout-batch-searchable/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (10)Dependencies (2)Versions (15)Used By (0)

Laravel Scout Batch Searchable
==============================

[](#laravel-scout-batch-searchable)

[![Latest Version on Packagist](https://camo.githubusercontent.com/6ea681a1674016b9c54c9c6da8a1a0e957d7e97e40441314f81b807311677768/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6f75746c316e652f6c61726176656c2d73636f75742d62617463682d73656172636861626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/outl1ne/laravel-scout-batch-searchable)[![Total Downloads](https://camo.githubusercontent.com/679fcf6deff814cd1c56537c959017292fb2fbdc049eea0753d08473dfb1ca1a/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6f75746c316e652f6c61726176656c2d73636f75742d62617463682d73656172636861626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/outl1ne/laravel-scout-batch-searchable)

This [Laravel](https://laravel.com) package allows for batching of Scout updates.

Requirements
------------

[](#requirements)

- Laravel Scout 9+
- Scheduler with cron

Description
-----------

[](#description)

This package provides a new trait `BatchSearchable` that should be used instead of the regular `Searchable` trait provided by Laravel Scout.

Using that trait, all updates pushed through Scout to the search server (whether it be MeiliSearch, Algolia or whatever else), are batched together instead of being sent one-by-one.

The updates are sent on two possible conditions:

> Either `scout.batch_searchable_max_batch_size` (default 250) is exeeded

or

> `scout.batch_searchable_debounce_time_in_min` (default 1) minutes have passed from the last update to the pending queue

The IDs of models that require updating are stored in the default cache layer using the `Cache` helper.

The debounce check uses Laravel's Scheduler to schedule a job that checks through all the pending update queues and sees if the required time has passed. This requires that the system has a working cron setup that calls `schedule:run` every minute.

Installation
------------

[](#installation)

Install the package in a Laravel Nova project via Composer and run migrations:

```
composer require outl1ne/laravel-scout-batch-searchable
```

Usage
-----

[](#usage)

Where you previously used the Searchable trait, just use BatchSearchable instead:

```
use Outl1ne\ScoutBatchSearchable\BatchSearchable;

class SomeModel extends Model {
    use BatchSearchable;
}
```

Credits
-------

[](#credits)

- [Tarvo Reinpalu](https://github.com/tarpsvo)

License
-------

[](#license)

Laravel Scout Batch Searchable is open-sourced software licensed under the [MIT license](LICENSE.md).

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance46

Moderate activity, may be stable

Popularity37

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 85.7% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~112 days

Recently: every ~120 days

Total

13

Last Release

408d ago

Major Versions

1.1.2 → 2.0.02022-06-09

### Community

Maintainers

![](https://www.gravatar.com/avatar/f1c2970763f51ca6ffcc1f1b6971a472b6b36a74d5eeb5446fb9d1caab44d016?d=identicon)[Tarpsvo](/maintainers/Tarpsvo)

---

Top Contributors

[![Tarpsvo](https://avatars.githubusercontent.com/u/2018660?v=4)](https://github.com/Tarpsvo "Tarpsvo (36 commits)")[![keithbrink](https://avatars.githubusercontent.com/u/15267205?v=4)](https://github.com/keithbrink "keithbrink (4 commits)")[![jonhassall](https://avatars.githubusercontent.com/u/9570507?v=4)](https://github.com/jonhassall "jonhassall (1 commits)")[![lukapeharda](https://avatars.githubusercontent.com/u/2076692?v=4)](https://github.com/lukapeharda "lukapeharda (1 commits)")

---

Tags

laravelbatchscout

### Embed Badge

![Health badge](/badges/optimistdigital-laravel-scout-batch-searchable/health.svg)

```
[![Health](https://phpackages.com/badges/optimistdigital-laravel-scout-batch-searchable/health.svg)](https://phpackages.com/packages/optimistdigital-laravel-scout-batch-searchable)
```

###  Alternatives

[jeroen-g/explorer

Next-gen Elasticsearch driver for Laravel Scout.

399672.8k](/packages/jeroen-g-explorer)[algolia/scout-extended

Scout Extended extends Laravel Scout adding algolia-specific features

4196.7M6](/packages/algolia-scout-extended)[romanstruk/manticore-scout-engine

Laravel Manticore Scout Engine

4921.2k](/packages/romanstruk-manticore-scout-engine)[outl1ne/laravel-scout-batch-searchable

This Laravel package adds a BatchSearchable trait to allow batching Scout updates.

3142.6k](/packages/outl1ne-laravel-scout-batch-searchable)[namoshek/laravel-scout-database

A generic Laravel Scout driver which performs full-text search on indexed model data using an SQL database as storage backend. Indexed data is stored in normalized form, allowing efficient search.

1970.8k](/packages/namoshek-laravel-scout-database)[baijunyao/laravel-scout-elasticsearch

Elasticsearch Driver for Laravel Scout

8023.7k1](/packages/baijunyao-laravel-scout-elasticsearch)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
