Commit Graph

18 Commits

Author SHA1 Message Date
Amnon Heiman
a707b487f0 StorageService: remove node should use hostid and not token
There is a confusion in origin, the MBean declare token as the parameter
to remove, but the implementation actually uses host id.

This patch modify scylla implementation to pass a host id as the
parameter to remove.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-10-26 10:31:43 +02:00
Amnon Heiman
ae26226339 ClientRequestMetrics: pass the url similiar to LatencyMetrics
In LatencyMetrics the URL is passed without the ending slash, this
patch use the same notation in ClientRequestMetrics.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-10-25 13:36:10 +02:00
Amnon Heiman
392765fa2e StorageProxy: Add depricated method implementation based on metrics
This follow origin by adding the implementation for the depricated
metrics methods.

Similiar to origin, the implementation calls the implementation in the
metrics.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-10-22 10:43:29 +03:00
Amnon Heiman
3bf092c83b StorageService: handle loadNewSStable and forceKeyspaceCleanup
keyspace cleanup was changed from GET to POST and load sstable was
missing the keyspace name.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-10-21 12:27:59 +03:00
Nadav Har'El
f05c6709dd Fix "nodetool repair" error
The existing scylla-jmx code had reversed logic for the success of the repair:
it reported to "nodetool repair" a failure when the repair was successful :-)

Note that "nodetool repair" waits until a FINISHED notification, and then reports
a failure if it previously got any SESSION_FAILED notification; So if repair was
successful, all we need to do is to avoid sending a "SESSION_FAILED" message.
But we don't need to send any additional "SESSION_SUCCESS" message to signal
success. That message type is only used to report progress to the user (a
"session" is part of the repair work, so seeing sessions completing shows
progress), but because Scylla doesn't support this progress report yet, we
can't send these notifications yet, and there's no point in sending one such
message at the end - it's only confusing (especially when the text is the same
as that of the FINISHED message).

Signed-off-by: Nadav Har'El <nyh@cloudius-systems.com>
2015-10-15 09:50:35 +03:00
Pekka Enberg
db6d48a695 Merge "Adding notification for the repair command" from Amnon
"The API is currently not supporting notification, but the repair
 command that perform via the nodetool relays on the notification to know
 when the command terminate.

 This series adds support for the repair notification, based on a timer
 and periodically check if a current repair command was terminated."
2015-08-31 09:41:01 +03:00
Amnon Heiman
67dca4da9d StorageService: Add notification suport for the repair command
This patch adds a notification support for the repair in StorageService.

When a repair command starts a timer is set to check the status of the
repair, when the repair complets it sends notification for the
successful or fail of the repair.

Because jconsole doesn't run method with variable number of parameters
an additional MBean method was added for async repair with only a
keyspace as its parameter.

All the forceAsycRepair methods are mapped to the asyncRepair metod that
replaces them in 2.2, when options will be supported in the repair, it
will be added to the jmx.

After this patch it is possible to register in the jconsole for
notification, perform a forceAsyncRepair and get the notification that
the repair complets
2015-08-27 21:02:28 +03:00
Amnon Heiman
b53be3a4ec StorageService: Add the effectiveOwnership and getOwnership implementation
This adds the implementation of the effectiveOwnership and getOwnership
in StorageService. It uses the API that defined in storage_service.json.

After this patch the effectiveOwnership and getOwnership will be
available via jconsole.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-08-24 13:12:33 +03:00
Amnon Heiman
631a6537d9 Add depricated implemention to the StorageProxy
Some of the depricated function in StorgeProxy uses the Metrics object
to get the information.

This adds an implementation for the following:
getReadOperations
getTotalReadLatencyMicros
getRecentReadLatencyMicros
getTotalReadLatencyHistogramMicros
getRangeOperations
getTotalRangeLatencyMicros
getRecentRangeLatencyMicros
getWriteOperations
getTotalWriteLatencyMicros
getRecentWriteLatencyMicros

It uses the implementation in ClientRequestMetrics without adding new
functionality.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-08-10 09:00:47 +03:00
Amnon Heiman
d1e16178df Moving the MBean to 2.1 (8)
This patch changes the MBeans to 2.1 version, with the changes an empty
stub implementation was added to the implementation so the code can
compile.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-30 12:01:05 +03:00
Amnon Heiman
057a3e27fd Cleaning file formatting
This patch cleans the file formatting of ColumnFamilyStore, CommitLog,
StorageProxy and StorageService.

Those files will be modified when moving to 2.1

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-30 11:37:03 +03:00
Amnon Heiman
7c8b1a86ca Adding the StorageMetrics
This adds the StorageMetrics, the implementation is based on the API.
The API definition are in storage_service under the metrics part.

After this patch, it will be possible to connect with jconsole and see
the StorageMetrics mbean.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-07 10:28:22 +03:00
Amnon Heiman
366b744d7b Instantiate the CacheMetrics
CacheService holds an instance of cache metrics per: key, row and counter.

This instantiate the different metrics. After this petch it will be
possible to connect with jsconsole and see those metrics

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-01 10:11:21 +03:00
Amnon Heiman
769b222173 Adding the CacheServiceMBean and CacheService
This adds the CacheServiceMBean and its implementation the CacheService
class.

The implementation is based on calls to the API that define in
cache_service.json

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-24 16:48:56 +03:00
Amnon Heiman
a34df20a74 Adding the StorageProxyMBean
This adds the StorageProxyMBean and implementation.
To keep the same API the relevant matrics where added.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-18 12:08:16 +03:00
Amnon Heiman
afac410a0d Adding StorageService MBean implementation
This adds the following method implementation that are supported:
getLiveNodes()
getUnreachableNodes()
getTokens()
getTokens(String endpoint)
getCommitLogLocation()
getTokenToEndpointMap()

After applying this series, those functionality will be available via
jconsole

The series also complete the API by adding an implementation based on
the swagger storage_service.json definition.  An implementation that
will be added to the API should be reflected in the MBean.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-15 16:36:22 +03:00
Amnon Heiman
55b80fe541 JMX API rename the cloudius package to cloudius.urchin
The urchin files (Client and Main) where moved to:
com.cloudius.urchin.api and com.cloudius.urchin.main respectively.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
2015-05-18 10:27:27 +03:00
Amnon Heiman
c64b4b6e56 Adding the StorageServiceMBean stub
This adds a stub of the StorageService.
After applying it, it will be possible to use JConsole to connect to the
process and run any of the command and inquire all the properties.

Some deprecated methods uses RepairParallelism class, an empty
implementation for it is added. It would be removed with future version
of the MBean, when those methods will be removed from the MBean

As this is a stub, the only effect is a printout on the screen.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-05-17 17:48:09 +03:00