thelastpickle / cassandra-reaper

Automated Repair Awesomeness for Apache Cassandra
http://cassandra-reaper.io/
Apache License 2.0
489 stars 217 forks source link

status-keyspace argument not working with spreaper #1283

Open kngatineau opened 1 year ago

kngatineau commented 1 year ago

Project board link

Hello,

When I attempt to run the status-keyspace command via spreaper, a 404 is returned.

kaitlyn@cassandracluster:~$ spreaper status-keyspace cassandracluster mykeyspace
# Cluster 'cassandracluster', keyspace 'mykeyspace':
{"code":404,"message":"HTTP 404 Not Found"}

# HTTP request failed with err: 404 Client Error: Not Found for url: http://localhost:8080/cluster/cassandracluster/mykeyspace

I noticed the REST API docs do not currently list a GET request for /cluster/CLUSTER_NAME/KEYSPACE. Only one to describe tables of a cluster /cluster/CLUSTER_NAME/tables.

When I run a curl request to /cluster/CLUSTER_NAME/tables, the request returns all tables as expected. Curl requests to other API endpoints (such as viewing registered clusters) also return expected results.

┆Issue is synchronized with this Jira Story by Unito ┆Issue Number: REAP-68

adejanovski commented 1 year ago

Hi @kngatineau, you're right, there's no REST endpoint supporting that operation. We don't have a data structure to support this either. I guess the cluster-status command could be used and then its result could be filtered to retain only the data that belongs to a keyspace. wdyt?