fix is auto compaction disabled
align API to the recent changes at https://github.com/scylladb/scylla/pull/6176 don't wrap API exceptions into IOException for enableAutoCompaction
This commit is contained in:
parent
fc43c56369
commit
c7dcbd7f42
@ -320,7 +320,7 @@ public class ColumnFamilyStore extends MetricsMBean implements ColumnFamilyStore
|
||||
@Override
|
||||
public boolean isAutoCompactionDisabled() {
|
||||
log(" isAutoCompactionDisabled()");
|
||||
return client.getBooleanValue("column_family/autocompaction/" + getCFName());
|
||||
return !client.getBooleanValue("column_family/autocompaction/" + getCFName());
|
||||
}
|
||||
|
||||
/** Number of tombstoned cells retreived during the last slicequery */
|
||||
|
@ -1444,13 +1444,7 @@ public class StorageService extends MetricsMBean implements StorageServiceMBean,
|
||||
log("enableAutoCompaction(String ks, String... columnFamilies)");
|
||||
MultivaluedMap<String, String> queryParams = new MultivaluedHashMap<String, String>();
|
||||
APIClient.set_query_param(queryParams, "cf", APIClient.join(columnFamilies));
|
||||
try {
|
||||
client.post("/storage_service/auto_compaction/" + ks, queryParams);
|
||||
} catch (RuntimeException e) {
|
||||
// FIXME should throw the right exception
|
||||
throw new IOException(e.getMessage());
|
||||
}
|
||||
|
||||
client.post("/storage_service/auto_compaction/" + ks, queryParams);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user