REMI php-pecl-couchbase4 HP Fatal error: Uncaught Error: Class "Couchbase\ClusterOptions" not found

Hello,

I use the REMI Couchbase PECL module, and am getting an error indicating the Couchbase Class is not available.

I have tried both 4.1.6 and 4.2.0 and receive the same error. This previously worked without issue on the 3.x version.

phpinfo cli output showing couchbase info:
/etc/php.d/50-couchbase.ini
couchbase
couchbase => enabled
couchbase_extension_version => 4.2.0
couchbase_extension_revision => 4807e92e003f4eb1fbb32be7b30cb15ba5a15c56
couchbase_client_revision => 933e87eeab58b0a3f063fc12d93b443eea39cca7
couchbase.log_level => no value => no value
couchbase.log_path => no value => no value
couchbase.log_php_log_err => 1 => 1
couchbase.log_stderr => 0 => 0
couchbase.max_persistent => -1 => -1
couchbase.persistent_timeout => -1 => -1

Did something change? Do I need to use the composer module now instead or in addition to the php module?

Thank you,
Matt

It would be helpful to see your code. Are you referencing tha autoload as described in the Couchbase Start Using the PHP SDK example? Start Using the PHP SDK | Couchbase Docs

You need both the PECL module and composer library for this to work with 4.x. 3.x you only needed the PECL module. So this is resolved.

2 Likes

Thank you for your reply :slight_smile:

This topic was automatically closed after 90 days. New replies are no longer allowed.