- Is aternovtsii/search-bundle compatible with Laravel?
- It is not a native Laravel package. The bundle is Symfony-centric and relies on Symfony Dependency Injection, EventDispatcher, and Doctrine ORM-oriented components, so it is not a drop-in fit for a standard Laravel application. You can use it in Laravel only with adapters, a Doctrine bridge, or by isolating the search logic in a separate service.
- How do I install aternovtsii/search-bundle in a Laravel project?
- You can require the package with Composer, but the overview and release notes do not describe a Laravel service provider, configuration publish step, or Artisan command. A full install would also require wiring Symfony DI, event dispatcher, and Doctrine components into Laravel. For most Laravel apps, extracting the OpenSearch client and query builders is safer than adopting the full bundle.
- Does aternovtsii/search-bundle work with Eloquent models?
- No native Eloquent integration is described. The package is built around Doctrine ORM concepts such as entity mapping, field metadata, and lifecycle events, while Laravel uses Eloquent. Supporting Eloquent would require custom adapters or a Doctrine bridge, including translating Doctrine listeners to Laravel observers or service-provider hooks.
- What is the new EXIST operator in aternovtsii/search-bundle v1.4.0?
- Version 1.4.0 adds an EXIST operator to the package's filtering and query DSL for existence checks. It supports negation through expressions such as new LogicalNot(new FieldFilter('date', Operator::EXISTS)), and the release notes mention NULL-value semantics. It is an additive query capability, not a Laravel compatibility change.
- How should Operator::EXISTS map to Eloquent whereNull or whereNotNull?
- The bundle does not provide a documented Eloquent mapping for Operator::EXISTS. In Laravel you would need to translate existence checks into Eloquent whereNull or whereNotNull clauses, or into OpenSearch exists query clauses if you query the search engine directly. Validate negation and NULL semantics carefully because the package's Doctrine field metadata may not match Eloquent null handling.
- Can I use aternovtsii/search-bundle with Elasticsearch or OpenSearch in Laravel?
- The package's core search and filter construction aligns with Elasticsearch or OpenSearch needs, but the bundle also carries Symfony and Doctrine integration code. In Laravel, the practical route is to extract the OpenSearch client configuration and query/filter builders rather than adopt the full bundle. Running the Symfony bundle as a containerized microservice is another option if you need its complete behavior.
- What Symfony and Doctrine dependencies make Laravel integration difficult?
- The bundle uses Symfony Dependency Injection, EventDispatcher, and ORM/Doctrine-oriented components. Laravel has its own service container and event system, and Eloquent is not Doctrine ORM. That means container wiring, event listeners, entity metadata, and lifecycle behavior all need adapters or replacement code.
- Can I extract only the query builder and OpenSearch client from aternovtsii/search-bundle?
- Extraction is the medium-effort path described for Laravel use. The goal is to isolate OpenSearch client configuration, filter/query builders, and operators such as EXIST while ignoring Symfony-specific integration code. You must still confirm whether EXIST depends on Doctrine field metadata or is self-contained before relying on it.
- What are Laravel-friendly alternatives to aternovtsii/search-bundle?
- Common alternatives are Laravel Scout for model search, a custom OpenSearch or Elasticsearch PHP client integration, or a smaller extracted query layer. If you need the bundle's exact query DSL, a Symfony microservice may be cleaner than forcing the full bundle into Laravel. Evaluate maintenance, null semantics, and whether you need Eloquent-native search.
- Is aternovtsii/search-bundle actively maintained for Laravel compatibility?
- The v1.4.0 release shows ongoing work on the query DSL, specifically the EXIST operator, but the notes do not indicate Laravel compatibility work or Symfony decoupling. The package remains Symfony-centric, so Laravel support is not established by this release. Check maintainer responsiveness to Laravel-specific PRs before committing to it.