|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58874 SolrClient::__construct internal error
Submitted: 2009-10-03 18:09 UTC Modified: 2009-10-03 22:58 UTC
From: Assigned: iekpo (profile)
Status: Closed Package: solr (PECL)
PHP Version: 5_3 CVS-2009-10-03 (dev) OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
New email:
PHP Version: OS:


 [2009-10-03 18:09 UTC]
See below the last warning.

Reproduce code:
$ sapi/cli/php -r 'try { $x = serialize(new solrclient); } catch (exception $e) { }'

Warning: SolrClient::__construct() expects exactly 1 parameter, 0 given in Command line code on line 1

Warning: SolrClient::__construct(): Invalid parameter. The client options array is required for a SolrClient instance. It must also be passed as the only parameter in Command line code on line 1

Warning: Unknown: Invalid SolrClient Index 0. HashTable index does not exist. in Unknown on line 0


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2009-10-03 19:30 UTC] israelekpo at gmail dot com
I am currently working on this.
 [2009-10-03 22:58 UTC] israelekpo at gmail dot com
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on

In case this was a website problem, the change will show
up on the website in short time.
Thank you for the report, and for helping us make PECL better.

Serialization and cloning of SolrClient instances is not supported.

The error warnings is now more descriptive. I have also added in the documentation that such operations (cloning and serialization) are currently not supported for SolrClient instances.

Attempting of illegal or unsupported operations like these is what is causing such warnings.

This was noted in revision number 289160
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Thu Dec 02 05:03:34 2021 UTC