Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Seal Solr Adapter

Seal Solr Adapter Laravel Package

cmsig/seal-solr-adapter

Apache Solr adapter for the SEAL search engine. Index and write documents to a SolrCloud instance using collections, with direct client setup or DSN-based configuration for common frameworks.

View on GitHub
Deep Wiki
Context7

An adapter to support Apache Solr in CMS-IG SEAL search abstraction. Part of the https://github.com/php-cmsig/search project. READ-ONLY Repository

Frequently asked questions about Seal Solr Adapter
How do I integrate SEAL Solr Adapter into a Laravel application?
Register the Solr client and adapter via a Laravel service provider. Bind the `SolrEngine` as a singleton in the container, using a DSN from `.env` or direct client configuration. Example: `$this->app->singleton(SolrEngine::class, fn($app) => new Engine(new SolrAdapter($solrClient), $app['schema']));`.
Does this package support Laravel’s dependency injection?
Yes. The adapter is designed to work with Laravel’s container. Configure it via a service provider, bind the `SolrAdapter` and `Engine` classes, and inject them into controllers or services. Use facades or direct container resolution for cleaner code.
What Laravel versions are compatible with SEAL Solr Adapter?
The package itself has no Laravel-specific dependencies, but it requires PHP 8.1+. For Laravel integration, ensure compatibility with `cmsig/seal` (check its docs) and use Laravel 9+ for modern DI features. Test thoroughly with your Laravel version.
Can I use this adapter with standalone Solr (non-Cloud) instances?
No. The adapter is explicitly designed for **SolrCloud** and uses collections for indexing. Standalone Solr instances won’t work without modifications. If you need standalone support, consider alternatives like `apache/solr-client-php` directly.
How do I configure authentication for Solr in the DSN?
Use the DSN format `solr://username:password@host:port`. For TLS, append `?tls=true`. Example: `solr://solr:SolrRocks@127.0.0.1:8983?tls=true`. Ensure your Solr instance accepts basic auth or configure it via `solr.disableConfigSetsCreateAuthChecks`.
Is there a performance overhead compared to using Solarium directly?
Yes, SEAL adds an abstraction layer on top of Solarium (or `apache/solr-client-php`). Benchmark your use case, but expect slightly higher latency due to schema validation and event dispatching. For high-throughput apps, direct Solr client calls may be faster.
How do I handle Solr connection failures in production?
Implement retry logic in your Laravel app or use SEAL’s event system to catch `DocumentIndexed`/`DocumentQuery` failures. Consider caching results or falling back to a secondary search engine (e.g., Elasticsearch) if SEAL supports multi-engine setups.
What’s the difference between this adapter and using `apache/solr-client-php` directly?
This adapter provides **schema abstraction** (via SEAL) for multi-engine support and Laravel-friendly DSN config. Direct `apache/solr-client-php` gives lower-level control (e.g., custom analyzers) but lacks SEAL’s portability. Choose this if you need SEAL’s features; otherwise, use the native client.
Can I use this with Laravel Scout for model-based search?
Not natively. SEAL Solr Adapter is a standalone search engine integration. To use it with Scout, create a custom `ScoutEngine` that bridges SEAL’s `Engine` to Scout’s `search()` and `index()` methods, mapping Laravel models to SEAL documents.
How do I contribute or report issues for this package?
File issues or feedback in the **main `cmsig/search` repository** (not this adapter’s repo). The project is community-driven; check the [SEAL discussions](https://github.com/PHP-CMSIG/search/discussions) for active development threads. Pull requests should target the `search` project.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky