The below link shows samples for NodeJS / Javascript which is wrong Syntax for PHP
https://docs.couchbase.com/php-sdk/3.0/concept-docs/health-check.html
The below link shows samples for NodeJS / Javascript which is wrong Syntax for PHP
https://docs.couchbase.com/php-sdk/3.0/concept-docs/health-check.html
Sorry about that, we have a few docs items we’re still working on with SDK 3.0. @Richard_Smedley, do we have this one tracked already?
On that note is there additional docs or info on how to access certain elements in the result ? That has also changed in 3.0 so i have to use the $doc = $getResult->content(); to get the actual result. But how do i access the keys like expiry or status etc to do some checks before i try to process the content. know i can get cas like $cas = $getResult->cas(); But that does not work for status etc.
Regarding status, one of the differences in “SDK3” is you’ll get an error/exception if there is no result. We had confusion at times with “SDK2” with people not checking results, so we decided to make it a lot more clear.
Expiry is technically not returned in a get()
in the protocol, but you’re in luck because in SDK3 we added a way to get the expiry in the options, and that will have the SDK automatically fetch it via the Sub-Document API. Maybe @avsej has a code sample?
Also, it’s still in development as of this writing, but have a look at some of the sdk-examples– some may still be SDK2, but the most recent updates are all examples of SDK3.