The storage service API will hold the equivelent information of the StorageServiceMBean. This adds the API with one stubed method the get local hostid. After the patch the storage_service doc will be available at: http://localhost:10000/api-doc/storage_service/ And the stubed local host id will be under: http://localhost:10000/storage_service/local_hostid and will return an empty string Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
19 lines
368 B
C++
19 lines
368 B
C++
/*
|
|
* Copyright 2015 Cloudius Systems
|
|
*/
|
|
|
|
#include "storage_service.hh"
|
|
#include "api/api-doc/storage_service.json.hh"
|
|
|
|
namespace api {
|
|
|
|
future<> set_storage_service(http_context& ctx) {
|
|
return ctx.http_server.set_routes([] (routes& r) {
|
|
httpd::storage_service_json::local_hostid.set(r, [](const_req req) {
|
|
return "";
|
|
});
|
|
});
|
|
}
|
|
|
|
}
|