summaryrefslogtreecommitdiff
path: root/src/chttpd_misc.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/chttpd_misc.erl')
-rw-r--r--src/chttpd_misc.erl23
1 files changed, 3 insertions, 20 deletions
diff --git a/src/chttpd_misc.erl b/src/chttpd_misc.erl
index 77d40b16..9a05f69e 100644
--- a/src/chttpd_misc.erl
+++ b/src/chttpd_misc.erl
@@ -16,8 +16,7 @@
handle_all_dbs_req/1,handle_replicate_req/1,handle_restart_req/1,
handle_uuids_req/1,handle_config_req/1,handle_log_req/1,
handle_task_status_req/1,handle_sleep_req/1,handle_welcome_req/1,
- handle_utils_dir_req/1, handle_favicon_req/1, handle_metrics_req/1,
- handle_system_req/1]).
+ handle_utils_dir_req/1, handle_favicon_req/1, handle_system_req/1]).
-include_lib("couch/include/couch_db.hrl").
@@ -36,7 +35,7 @@ handle_welcome_req(#httpd{method='GET'}=Req, WelcomeMessage) ->
send_json(Req, {[
{couchdb, WelcomeMessage},
{version, list_to_binary(couch:version())},
- {cloudant_build, get_version()}
+ {dbcore, get_version()}
]});
handle_welcome_req(Req, _) ->
send_method_not_allowed(Req, "GET,HEAD").
@@ -89,8 +88,7 @@ handle_sleep_req(Req) ->
send_method_not_allowed(Req, "GET,HEAD").
handle_all_dbs_req(#httpd{method='GET'}=Req) ->
- Customer = cloudant_util:customer_name(Req),
- {ok, DbNames} = fabric:all_dbs(Customer),
+ {ok, DbNames} = fabric:all_dbs(),
send_json(Req, DbNames);
handle_all_dbs_req(Req) ->
send_method_not_allowed(Req, "GET,HEAD").
@@ -209,21 +207,6 @@ handle_log_req(#httpd{method='GET'}=Req) ->
handle_log_req(Req) ->
send_method_not_allowed(Req, "GET").
-handle_metrics_req(#httpd{method='GET', path_parts=[_]}=Req) ->
- {_, L} = lists:unzip(gen_event:which_handlers(couch_metrics_event_manager)),
- send_json(Req, L);
-handle_metrics_req(#httpd{method='GET', path_parts=[_, Id]}=Req) ->
- case chttpd:qs_value(Req, "slice") of
- undefined ->
- Data = couch_metrics_event:get_global_metrics(?b2a(Id));
- SliceStr ->
- Slice = list_to_integer(SliceStr),
- Data = couch_metrics_event:get_global_metrics(?b2a(Id), Slice)
- end,
- send_json(Req, Data);
-handle_metrics_req(Req) ->
- send_method_not_allowed(Req, "GET,HEAD").
-
% Note: this resource is exposed on the backdoor interface, but it's in chttpd
% because it's not couch trunk
handle_system_req(Req) ->