cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Spriegel (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CASSANDRA-13086) CAS resultset sometimes does not contain value column even though wasApplied is false
Date Fri, 30 Dec 2016 09:45:59 GMT

     [ https://issues.apache.org/jira/browse/CASSANDRA-13086?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Christian Spriegel updated CASSANDRA-13086:
-------------------------------------------
    Description: 
Every now and then I see a ResultSet for one of my CAS queries that contain wasApplied=false,
but does not contain my value column.

I just now found another occurrence, which causes the following exception in the driver:
{code}
...
Caused by: com.mycompany.MyDataaccessException: checkLock(ResultSet[ exhausted: true, Columns[[applied](boolean)]])
    at com.mycompany.MyDAO._checkLock(MyDAO.java:408)
    at com.mycompany.MyDAO._releaseLock(MyDAO.java:314)
    ... 16 more
Caused by: java.lang.IllegalArgumentException: value is not a column defined in this metadata
    at com.datastax.driver.core.ColumnDefinitions.getAllIdx(ColumnDefinitions.java:266)
    at com.datastax.driver.core.ColumnDefinitions.getFirstIdx(ColumnDefinitions.java:272)
    at com.datastax.driver.core.ArrayBackedRow.getIndexOf(ArrayBackedRow.java:81)
    at com.datastax.driver.core.AbstractGettableData.getBytes(AbstractGettableData.java:151)
    at com.mycompany.MyDAO._checkLock(MyDAO.java:383)
    ... 17 more
{code}

The query the application was doing:
delete from "Lock" where lockname=:lockname and id=:id if value=:value;


I did some debugging recently and was able to track these ResultSets to StorageProxy.cas()
to the "CAS precondition does not match current values {}" return statement.

I saw this happening with Cassandra 3.0.10.

  was:
Every now and then I see a ResultSet for one of my CAS queries that contain wasApplied=false,
but does not contain my value column.

I just now found another occurrence, which causes the following exception in the driver:
{code}
...
Caused by: com.mycompany.MyDataaccessException: checkLock(ResultSet[ exhausted: true, Columns[[applied](boolean)]])
    at com.mycompany.MyDAO._checkLock(MyDAO.java:408)
    at com.mycompany.MyDAO._releaseLock(MyDAO.java:314)
    ... 16 more
Caused by: java.lang.IllegalArgumentException: value is not a column defined in this metadata
    at com.datastax.driver.core.ColumnDefinitions.getAllIdx(ColumnDefinitions.java:266)
    at com.datastax.driver.core.ColumnDefinitions.getFirstIdx(ColumnDefinitions.java:272)
    at com.datastax.driver.core.ArrayBackedRow.getIndexOf(ArrayBackedRow.java:81)
    at com.datastax.driver.core.AbstractGettableData.getBytes(AbstractGettableData.java:151)
    at com.mycompany.MyDAO._checkLock(MyDAO.java:383)
    ... 17 more
{code}

The query the application was doing:
delete from "Lock" where lockname=:lockname and id=:id if value=:value;


I did some debugging recently and was able to track these ResultSets to StorageProxy.cas()
to the "CAS precondition does not match current values {}" return statement. 


> CAS resultset sometimes does not contain value column even though wasApplied is false
> -------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-13086
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-13086
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Christian Spriegel
>            Priority: Minor
>
> Every now and then I see a ResultSet for one of my CAS queries that contain wasApplied=false,
but does not contain my value column.
> I just now found another occurrence, which causes the following exception in the driver:
> {code}
> ...
> Caused by: com.mycompany.MyDataaccessException: checkLock(ResultSet[ exhausted: true,
Columns[[applied](boolean)]])
>     at com.mycompany.MyDAO._checkLock(MyDAO.java:408)
>     at com.mycompany.MyDAO._releaseLock(MyDAO.java:314)
>     ... 16 more
> Caused by: java.lang.IllegalArgumentException: value is not a column defined in this
metadata
>     at com.datastax.driver.core.ColumnDefinitions.getAllIdx(ColumnDefinitions.java:266)
>     at com.datastax.driver.core.ColumnDefinitions.getFirstIdx(ColumnDefinitions.java:272)
>     at com.datastax.driver.core.ArrayBackedRow.getIndexOf(ArrayBackedRow.java:81)
>     at com.datastax.driver.core.AbstractGettableData.getBytes(AbstractGettableData.java:151)
>     at com.mycompany.MyDAO._checkLock(MyDAO.java:383)
>     ... 17 more
> {code}
> The query the application was doing:
> delete from "Lock" where lockname=:lockname and id=:id if value=:value;
> I did some debugging recently and was able to track these ResultSets to StorageProxy.cas()
to the "CAS precondition does not match current values {}" return statement.
> I saw this happening with Cassandra 3.0.10.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message