<!-- 
RSS generated by JIRA (5.2.4#845-sha1:c9f4cc41abe72fb236945343a1f485c2c844dac9) at Thu May 23 03:07:30 CDT 2013

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary add field=key&field=summary to the URL of your request.
For example:
http://www.couchbase.com/issues/si/jira.issueviews:issue-xml/SPY-69/SPY-69.xml?field=key&field=summary
-->
<rss version="0.92" >
<channel>
    <title>Couchbase</title>
    <link>http://www.couchbase.com/issues</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>5.2.4</version>
        <build-number>845</build-number>
        <build-date>26-12-2012</build-date>
    </build-info>

<item>
            <title>[SPY-69] CASMutator expiration doesn&apos;t work properly.</title>
                <link>http://www.couchbase.com/issues/browse/SPY-69</link>
                <project id="10047" key="SPY">Spymemcached Java Client</project>
                        <description>Team, got a customer saying that the CAS operation within spy 2.7.3 doesn&amp;#39;t seem to reset the expiration of a key properly.&lt;br/&gt;
&lt;br/&gt;
Here&amp;#39;s a snippet of code:&lt;br/&gt;
&lt;br/&gt;
public String updateVsSession(String key, final String session) throws Exception {&lt;br/&gt;
&lt;br/&gt;
MemcachedClient sessionClient = cachePool.getConnection(PersistableBeanType.VS_SESSION);&lt;br/&gt;
&lt;br/&gt;
&lt;br/&gt;
Transcoder tc = new SerializingTranscoder();&lt;br/&gt;
&lt;br/&gt;
CASMutator&amp;lt;String&amp;gt; mutator = new CASMutator&amp;lt;String&amp;gt;(sessionClient, tc);&lt;br/&gt;
&lt;br/&gt;
CASMutation&amp;lt;String&amp;gt; mutation = new CASMutation&amp;lt;String&amp;gt;() {&lt;br/&gt;
&lt;br/&gt;
public String getNewValue(String current) {&lt;br/&gt;
&lt;br/&gt;
return session;&lt;br/&gt;
&lt;br/&gt;
}&lt;br/&gt;
&lt;br/&gt;
};&lt;br/&gt;
&lt;br/&gt;
&lt;br/&gt;
return mutator.cas(key, session, 1900, mutation);&lt;br/&gt;
&lt;br/&gt;
}&lt;br/&gt;
&lt;br/&gt;
&lt;br/&gt;
&lt;br/&gt;
&lt;br/&gt;
It appears that when running the CAS operation only once, the key expires as expected.  However, if an update is made and the operation is run again, the key seems to last forever.  &lt;br/&gt;
&lt;br/&gt;
Can you confirm whether this is a bug or expected?  The customer expects that the CAS operation would constantly &amp;quot;extend&amp;quot; the expiration time.</description>
                <environment>All</environment>
            <key id="15803">SPY-69</key>
            <summary>CASMutator expiration doesn&apos;t work properly.</summary>
                <type id="1" iconUrl="http://www.couchbase.com/issues/images/icons/issuetypes/bug.png">Bug</type>
                                <priority id="3" iconUrl="http://www.couchbase.com/issues/images/icons/priorities/major.png">Major</priority>
                    <status id="5" iconUrl="http://www.couchbase.com/issues/images/icons/statuses/resolved.png">Resolved</status>
                    <resolution id="1">Fixed</resolution>
                    <security id="10011">Public</security>
                        <assignee username="mikew">Mike Wiederhold</assignee>
                                <reporter username="mikew">Mike Wiederhold</reporter>
                        <labels>
                    </labels>
                <created>Wed, 4 Jan 2012 15:53:20 -0600</created>
                <updated>Sun, 22 Jan 2012 15:27:01 -0600</updated>
                    <resolved>Sun, 22 Jan 2012 15:27:01 -0600</resolved>
                            <version>2.7.3</version>
                                <fixVersion>2.8.0</fixVersion>
                                <component>library</component>
                                <votes>0</votes>
                        <watches>0</watches>
                                                    <comments>
                    <comment id="23408" author="mikew" created="Wed, 4 Jan 2012 16:13:03 -0600"  >From bug fix commit message:&lt;br/&gt;
&lt;br/&gt;
The cas call in this class wasn&amp;#39;t using the function that allows&lt;br/&gt;
the expiration to be specified. As a result, if the CASMutator was&lt;br/&gt;
used and an item was already in memcached then the expiration would&lt;br/&gt;
be set to 0.</comment>
                    <comment id="23529" author="perry" created="Tue, 17 Jan 2012 13:01:09 -0600"  >If this is fixed, can we mark it as resolved?</comment>
                </comments>
                    <attachments>
                </attachments>
            <subtasks>
        </subtasks>
                <customfields>
                                                                                                                                                                                                                    <customfield id="customfield_10081" key="com.pyxis.greenhopper.jira:gh-global-rank">
                <customfieldname>Rank</customfieldname>
                <customfieldvalues>
                    <customfieldvalue>9527</customfieldvalue>
                </customfieldvalues>
            </customfield>
                                                                                    <customfield id="customfield_10181" key="com.atlassian.jira.ext.charting:timeinstatus">
                <customfieldname>Time In Status</customfieldname>
                <customfieldvalues>
                    
                </customfieldvalues>
            </customfield>
                                                </customfields>
    </item>
</channel>
</rss>