[
https://issues.apache.org/jira/browse/CASSANDRA-19448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17878865#comment-17878865
]
Maxwell Guo edited comment on CASSANDRA-19448 at 9/3/24 1:59 PM:
-----------------------------------------------------------------
I am not opposed to retaining this precision configuration, and the first
version of the code has this feature.
UPDATE:
I recalled the entire review process, the reason we finally remove the
precision is that , first time I saw [replay here use
Milliseconds|https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/db/commitlog/CommitLogReplayer.java#L498]
no matter what kind of precision is setted. So I left a comment [here
|https://github.com/apache/cassandra/pull/3215] said " //todo remove this as
this is not used", And I think nobody set this precision before as this is a
obvious bug and nobody has created a bug for the restore precision. we all
agree with the action of remove the precision, so here we are .
I can modify the code to support different kind of precision based on
microseconds level, but what about create a new ticket as this seems have a
slight relationship to this ticket (the description is :"* if a user specifies
to restore at something at a lower granularity like milliseconds or
microseconds, that means that the it will truncate everything after the second
and restore to that second*")
and the essential reason for the precision deletion(my code did) you described
is that the precision configuration is invalid.
:)
was (Author: maxwellguo):
I am not opposed to retaining this precision configuration, and the first
version of the code has this feature.
> CommitlogArchiver only has granularity to seconds for restore_point_in_time
> ---------------------------------------------------------------------------
>
> Key: CASSANDRA-19448
> URL: https://issues.apache.org/jira/browse/CASSANDRA-19448
> Project: Cassandra
> Issue Type: Bug
> Components: Local/Commit Log
> Reporter: Jeremy Hanna
> Assignee: Maxwell Guo
> Priority: Normal
> Fix For: 4.0.x, 4.1.x, 5.0.x, 5.x
>
> Time Spent: 1h
> Remaining Estimate: 0h
>
> Commitlog archiver allows users to backup commitlog files for the purpose of
> doing point in time restores. The [configuration
> file|https://github.com/apache/cassandra/blob/trunk/conf/commitlog_archiving.properties]
> gives an example of down to the seconds granularity but then asks what
> whether the timestamps are microseconds or milliseconds - defaulting to
> microseconds. Because the [CommitLogArchiver uses a second based date
> format|https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/db/commitlog/CommitLogArchiver.java#L52],
> if a user specifies to restore at something at a lower granularity like
> milliseconds or microseconds, that means that the it will truncate everything
> after the second and restore to that second. So say you specify a
> restore_point_in_time like this:
> restore_point_in_time=2024:01:18 17:01:01.623392
> it will silently truncate everything after the 01 seconds. So effectively to
> the user, it is missing updates between 01 and 01.623392.
> This appears to be a bug in the intent. We should allow users to specify
> down to the millisecond or even microsecond level. If we allow them to
> specify down to microseconds for the restore point in time, then it may
> internally need to change from a long.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]