[ 
https://issues.apache.org/jira/browse/CASSANDRA-16976?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17422688#comment-17422688
 ] 

Aleksei Zotov edited comment on CASSANDRA-16976 at 9/30/21, 10:57 AM:
----------------------------------------------------------------------

Thanks Brandon, that's what I wanted to hear!

I made the necessary changes and here are the current outputs from my local:
{code:java}
nodetool compactionstats

pending tasks: 1
- keyspace1.standard1: 1

keyspace  table     task id                              completion ratio kind  
     progress  sstables total     unit 
keyspace1 standard1 14e6c6c0-21d2-11ec-8ef7-bf6daa00e588 99.99%           
Compaction 144850779 2        144860627 bytes
Active compaction remaining time :   0h00m00s
{code}
{code:java}
nodetool compactionstats --human-readable

pending tasks: 1
 - keyspace1.standard1: 1

keyspace  table     task id                              completion ratio kind  
     progress  sstables total      unit 
keyspace1 standard1 1f9ca0d0-21d2-11ec-8ef7-bf6daa00e588 68.04%           
Compaction 94.04 MiB 1        138.22 MiB bytes
Active compaction remaining time : 0h00m00s
{code}
{code:java}
cqlsh:system_views> SELECT * FROM sstable_tasks; 

keyspace_name | table_name | task_id                              | 
completion_ratio | kind       | progress | sstables | total    | unit
--------------+------------+--------------------------------------+------------------+------------+----------+----------+----------+-------
     
    keyspace1 |  standard1 | 238f6290-1fd4-11ec-8c63-7d65848b040f |         
0.212345 | compaction | 16184734 |        2 | 76219177 | bytes
{code}
_Unfortunately, I could not get a horizontal scroll bar to the above output 
snippets, please, copy and paste them to a text editor to see nice and clear 
output._

I have not developed new tests because it seems to be hard to catch compaction 
in a certain moment and ensure the expected state. I did not want to fight with 
mocking everything either. Taking into account that my changes are pretty small 
and straightforward, I feel that's ok. Please, let me know if you think 
opposite. However, I'd be glad to get any suggestions on the best way to 
introduce tests for this stuff.

[~brandon.williams] [~stefan.miklosovic]

Could you please make a review to this ticket.

 


was (Author: azotcsit):
Thanks [~brandon.williams]!

I made all necessary changes and here are the current outputs from my local:
{code:java}
nodetool compactionstats

pending tasks: 1
- keyspace1.standard1: 1

keyspace  table     task id                              completion ratio kind  
     progress  sstables total     unit 
keyspace1 standard1 14e6c6c0-21d2-11ec-8ef7-bf6daa00e588 99.99%           
Compaction 144850779 2        144860627 bytes
Active compaction remaining time :   0h00m00s
{code}
{code:java}
nodetool compactionstats --human-readable
pending tasks: 1
 - keyspace1.standard1: 1
keyspace table task id completion ratio kind progress sstables total unit 
keyspace1 standard1 1f9ca0d0-21d2-11ec-8ef7-bf6daa00e588 68.04% Compaction 
94.04 MiB 1 138.22 MiB bytes Active compaction remaining time : 0h00m00s
{code}
 
{code:java}
cqlsh:system_views> SELECT * FROM sstable_tasks; 

keyspace_name | table_name | task_id                              | 
completion_ratio | kind       | progress | sstables | total    | unit
--------------+------------+--------------------------------------+------------------+------------+----------+----------+----------+-------
     
    keyspace1 |  standard1 | 238f6290-1fd4-11ec-8c63-7d65848b040f |         
0.212345 | compaction | 16184734 |        2 | 76219177 | bytes
{code}
 

 

 

> Make nodetool compactionstats and sstable_tasks consistent
> ----------------------------------------------------------
>
>                 Key: CASSANDRA-16976
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-16976
>             Project: Cassandra
>          Issue Type: Task
>          Components: Feature/Virtual Tables, Tool/nodetool
>            Reporter: Aleksei Zotov
>            Assignee: Aleksei Zotov
>            Priority: Normal
>             Fix For: 4.x
>
>
> Currently there is a difference in the output if {{nodetool compactionstats}} 
> command and {{sstable_tasks}} virtual table (originally introduced by 
> CASSANDRA-14457). They need to be aligned. The differences are:
>  
> ||nodetool||VT||Comment||
> |percentComplete|completion_ratio|column naming is different only|
> |completed|progress|column naming is different only|
> |compaction type|kind|column naming is different only|
> |sstables|NA| |
> Additionally, please, update necessary documentation.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to