Commit Graph

10 Commits

Author SHA1 Message Date
Glauber Costa
04c0fbcb8c remove calls to seal_active_memtable
It should not be called directly: externall callers should be calling flush()
instead.

To be sure it doesn't happen again, make seal_active_memtable private.

Signed-off-by: Glauber Costa <glommer@cloudius-systems.com>
2015-07-15 10:24:20 -04:00
Glauber Costa
9c464aff9b database: clean up various APIs
In much of our column_families APIs, we need to pass a pointer to the database.
The only reason we do that, is so we can properly handle the commit log entries
after we seal the current memtables into sstables.

Now that we store a pointer to the commit log in the CF itself at the time it
is created, we no longer have to do it. As a result, the APIs are a lot
cleaner, with no gratuitous parameters.

My motivation for this was the flush method, but as a result, apply() also gets
cleaner.

Signed-off-by: Glauber Costa <glommer@cloudius-systems.com>
2015-07-15 10:24:20 -04:00
Amnon Heiman
14aafc83b6 API: Adding the get_host_id implementation to the API
This adds the implementation for the get host id API.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-15 14:19:16 +03:00
Amnon Heiman
40d0d58a50 Cleaning the storage_service API
This changes the return type of void API to json_void, for a cleaner
API.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-07-15 14:18:37 +03:00
Amnon Heiman
a6dac55f8b Adding implementation to the storage_service API
This adds the following implementation to the storage_service API:
get_leaving_nodes
get_moving_nodes
get_joining_nodes
get_all_data_file_locations
get_saved_caches_location
get_host_id_map
get_current_generation_number
get_keyspaces
force_keyspace_flush
force_keyspace_compaction

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-25 14:41:48 +03:00
Amnon Heiman
9027c4bd33 Adding stub implementation for storage_service
This adds a stub implementation of the storage service, to simplify
future implementation, variables that should be used in the
implementation are taken and stored.

Implementation return the currect type, but with stub values.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-16 14:30:23 +03:00
Amnon Heiman
c9fe14c0ff Cleanning the storage_service.cc
This change how values are added to the result array and use std::string
for lexical cast.

Signed-off-by: Amnon Heiman <amnon@cloudius-systems.com>
2015-06-16 14:30:23 +03:00
Amnon Heiman
dc4584254b API: Adding storage_service implementation
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>
2015-05-27 15:29:49 +03:00
Avi Kivity
b3b553821f Merge branch 'master' of github.com:cloudius-systems/seastar into db
Contains patch from Amnon to update the calls to http set_routes().
2015-04-26 13:16:35 +03:00
Amnon Heiman
aeb66fa409 API: Adding the stroage service stub
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>
2015-04-13 18:57:14 +03:00