cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aleksey Yeschenko (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-12960) Pending hinted hand-offs are replayed after TRUNCATE
Date Mon, 11 Sep 2017 14:55:00 GMT


Aleksey Yeschenko commented on CASSANDRA-12960:

See {{Hint.isLive()}}. We both keep truncation records, and look at them when replaying hints,
doing exactly what [~jasonstack] suggested here. {{BatchlogManager}} also has similar code
to avoid replaying truncated mutations.

The overall problem with truncate however is that it itself is not atomic, and can fail partially.
You should not use it in production, because it requires the whole cluster to be up, and well-behaving,
and for nothing to go wrong while truncate is being issued. If a node goes down after availability
was validated, but before getting truncate command, you are in all sorts of trouble.

> Pending hinted hand-offs are replayed after TRUNCATE
> ----------------------------------------------------
>                 Key: CASSANDRA-12960
>                 URL:
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Streaming and Messaging
>         Environment: Cassandra 2.2.8
> Amazon Linux AMI 2016.03
>            Reporter: Yuji Ito
>            Priority: Minor
>         Attachments:
> I could read stale data after truncating a table.
> The issue happens when the truncation is executed while a node is starting.
> According to logs, pending hinted hand-offs were replayed after the truncation.
> *cluster*:
> - C* 2.2.8
> - a cluster has 3 nodes
> - replication_factor: 3
> *steps to reproduce* (the attached script):
> # kill a node
> # insert/update some records
> # restart the killed node
> # truncate the table (not to wait for the killed node's startup)
> # kill another node (this step isn't essential)
> # read all data

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message