This adds a stub implementation for the storage_proxy.
To simplify future implementation, it takes the passed parameter and
return the correct types with fixed values.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds the swagger definition file for the storage_proxy, it is based
on the StorageProxyMBean definition.
The following command where define:
get_total_hints
get_hinted_handoff_enabled
set_hinted_handoff_enabled
get_hinted_handoff_enabled_by_dc
set_hinted_handoff_enabled_by_dc_list
get_max_hint_window
set_max_hint_window
get_max_hints_in_progress
set_max_hints_in_progress
get_rpc_timeout
set_rpc_timeout
get_read_rpc_timeout
set_read_rpc_timeout
get_write_rpc_timeout
set_write_rpc_timeout
get_counter_write_rpc_timeout
set_counter_write_rpc_timeout
get_cas_contention_timeout
set_cas_contention_timeout
get_range_rpc_timeout
set_range_rpc_timeout
get_truncate_rpc_timeout
set_truncate_rpc_timeout
reload_trigger_classes
get_read_repair_attempted
get_read_repair_repaired_blocking
get_read_repair_repaired_background
get_schema_versions
Matricses are not added yet, the basic integration and naming
get_cas_read_timeouts was added under the URL:
/storage_proxy/metrics/
That will holds the related matricses.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This API gother information about messages passing in the system, in
this patch the following API will be supported:
/messaging_service/messages/replied
/messaging_service/messages/sent
/messaging_service/messages/pending
/messaging_service/messages/exception
/messaging_service/messages/respond_pending
/messaging_service/messages/dropped
The swagger defintion can be retrieved from:
/api-doc/messaging_service
In a typical scenario the API collect values from multiple distributed
instances. Sometimes it is needed to reduce multiple maps by merging
their keys and accumulating their values.
This is a helper function that can be used in map_reduce to perform maps
sum.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds the API implementation to the column family API.
After this patch the following API will be supported:
/column_family/name
/column_family
/column_family/name/keyspace
This adds the Column familiy swagger definition file, the API is
equivelent to the ColumnFamilyStoreMBean definition.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This series adds the implementation for teh Failure detector API.
After this patch the following APIs will be supported:
/failure_detector/endpoints
/failure_detector/count/endpoint/up
/failure_detector/count/endpoint/down
/failure_detector/phi
POST:/failure_detector/phi
/failure_detector/simple_states
/failure_detector/endpoints/states
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
When using swagger definition file, returning a map, needs to be in a
key, value list. To handle this common case in the API, a helper
function was added that gets an unorder_map and return a vector of key,
value mapping.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
When the container_to_vec helper function has a string that contains
space, a boost exection is thrown.
This fixes it by using std::string for the conversion that the boost
recognize as a string type.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This patch clean up the gossiper implementation by using the new square
bracket operator for path param and by using the general function
container_to_vec.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
Reviewed-by: Pekka Enberg <penberg@cloudius-systems.com>
Empty parameter definition is not accepted by the swagger UI, instead,
the parameter list itself should be empty.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds implementation to the added storage service definitions.
After this patch, the following calls will be supported:
/storage_service/tokens
/storage_service/tokens/{endpoint}
/storage_service/commitlog
/storage_service/tokens_endpoint
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds the following definitions to the storage_service swagger
definition file:
/storage_service/tokens
/storage_service/tokens/{endpoint}
/storage_service/commitlog
/storage_service/tokens_endpoint
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
These adds a helper function to transfer a list of object to a list of
string. It will be used by the API implementation.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This implement the gossipier API. All actions perform on the local
gossiper.
The following functionality is supported:
/gossiper/downtime/{addr}
/gossiper/generation_number/{addr}
/gossiper/assassinate/{addr}
The following are extened API beyond the MBean definition:
/gossiper/endpoint/down
/gossiper/endpoint/live
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds the implementation of the commitlog API.
Current implementation contains:
/commitlog/segments/active
That returns a list of the active file names, and
/commitlog/segments/archiving
Which always return an empty list as we archiving is not supported at
the moment
The doc file is under:
/api-doc/commitlog
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
The API needs the database distribute object to get information from it.
This adds a database reference the API context so it would be
available in the API.
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
This adds the API to urchin, all API related files will be placed under
the api directory.
The API server uses a context object to access global parameters,
typically the different servers themselves.
After this patch the api-doc will be available, though empty under:
http://localhost:10000/api-doc
Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>