[PCBC-72] getDelayed seems to return a Boolean not a "string (Binary object)" as the docs state Created: 13/Jun/12  Updated: 26/Aug/13  Resolved: 27/Nov/12

Status: Closed
Project: Couchbase PHP client library
Component/s: docs, library
Affects Version/s: 1.0.3
Fix Version/s: 1.1.0
Security Level: Public

Type: Bug Priority: Critical
Reporter: Benjamin Young Assignee: kzeller
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   
I'm not sure if this is a doc error or a code error, but the documentation for getDelayed [1] states it returns a "string (Binary object)" when in fact it returns a Boolean.

The return of a Boolean is likely the intended response as getDelayed implies the use of a callback.

I've marked this issue as being related to both docs & library, though, in case I've missed something.

[1] http://www.couchbase.com/docs/couchbase-sdk-php-1.0/api-reference-retrieve.html#table-couchbase-sdk_php_get-delayed

 Comments   
Comment by Matt Ingenthron [ 07/Nov/12 ]
Mark: Please determine if this issue is still valid and help me triage it into the appropriate release. I've assigned it to you for triage, not necessarily to fix it.
Comment by Matt Ingenthron [ 12/Nov/12 ]
Trond: Since this may be just a matter of getting correct documentation, I've bumped the priority so we try to triage it and decide where it belongs. Please allocate just a few minutes to it when you can.

If it's a documentation fix that's needed, let's pass it along to Karen.

If you're unsure what was originally intended, it may make sense to look at pecl-memcached.
Comment by Trond Norbye [ 27/Nov/12 ]
According to the code (and the documentation for pecl::memcached:getDelayed) it should return a boolean value.
Comment by kzeller [ 27/Nov/12 ]
I think this fixes it:

      <dcall id="get-delayed" call="getDelayed" inherit="none">

        <m_title>
          Get a key to be fetched later
        </m_title>

        <args>

          <argument inherit="keyn"/>

          <argument inherit="with_cas" optional="yes"/>

          <argument inherit="callback" optional="yes"/>

        </args>
       <return inherit="boolean"/>
      </dcall>
Comment by kzeller [ 27/Nov/12 ]
    <dcall id="get-delayed" call="getDelayed" inherit="none">

        <m_title>
          Get a key to be fetched later
        </m_title>

        <args>

          <argument inherit="keyn"/>

          <argument inherit="with_cas" optional="yes"/>

          <argument inherit="callback" optional="yes"/>

        </args>
       <return inherit="boolean"/>
      </dcall>
Generated at Fri Nov 21 10:52:45 CST 2014 using JIRA 5.2.4#845-sha1:c9f4cc41abe72fb236945343a1f485c2c844dac9.