0

I want to use yii2-solr extension in one of my projects. How can I configure this extension. Nothing is mentioned on the extension page. Has anyone used this extension? Any help would be appreciable. Thank you.

I found the extension on github repo . In readme file it is mention to configure it as follows:

'solr' => [
        'class' => 'sammaye\solr\Client',
        'options' => [
            'endpoint' => [
                'solr1' => [
                    'host' => '10.208.225.66',
                    'port' => '8983',
                    'path' => '/solr'
                ]
            ]
        ]
    ],

But after doing all this I am getting the following error:

Class 'Solarium\Client' not found

In one of its Client.php file the line is:

use Solarium\Client as SolrClient;

I checked all the files but Solarium namespace is not there.

Chinmay Waghmare
  • 5,368
  • 2
  • 43
  • 68

1 Answers1

1

yii2-solr depends on the Solarium library. If you installed yii2-solr via composer, it should have automatically downloaded it as dependency. Check github composer.json. If not, you'll have to install it manually, see packagist.

Andrei
  • 42,814
  • 35
  • 154
  • 218
laszlovl
  • 491
  • 2
  • 6