anchor.diff:      exit(normal).
   
   
  -build_pool_info(Id, UserPassword, InfoLevel, LocalAddr) ->
  +build_pool_info(Id, IsAdmin, InfoLevel, LocalAddr) ->
       UUID = get_uuid(),
   
  -    F = build_nodes_info_fun(menelaus_auth:check_auth(UserPassword), InfoLevel, LocalAddr),
  +    F = build_nodes_info_fun(IsAdmin, InfoLevel, LocalAddr),
       Nodes = [F(N, undefined) || N <- ns_node_disco:nodes_wanted()],
       Config = ns_config:get(),
       BucketsVer = erlang:phash2(ns_bucket:get_bucket_names(Config))
  
positive.code:     end.
  
  handle_pool_info(Id, Req) ->
      UserPassword = menelaus_auth:extract_auth(Req),
      LocalAddr = menelaus_util:local_addr(Req),
      Query = Req:parse_qs(),
      WaitChangeS = proplists:get_value("waitChange", Query),
      PassedETag = proplists:get_value("etag", Query),
      case WaitChangeS of
          undefined -> reply_json(Req, build_pool_info(Id, UserPassword, normal, LocalAddr));
          _ ->
              WaitChange = list_to_integer(WaitChangeS),
              menelaus_event:register_watcher(self()),
              erlang:send_after(WaitChange, self(), wait_expired),
              handle_pool_info_wait(Req, Id, UserPassword, LocalAddr, PassedETag)
      end.
  
  handle_pool_info_wait(Req, Id, UserPassword, LocalAddr, PassedETag) ->
      Info = mochijson2:encode(build_pool_info(Id, UserPassword, stable, LocalAddr)),
      ETag = integer_to_list(erlang:phash2(Info)),
      if
          ETag =:= PassedETag ->
              erlang:hibernate(?MODULE, handle_pool_info_wait_wake,
                               [Req, Id, UserPassword, LocalAddr, PassedETag]);
          true ->
              handle_pool_info_wait_tail(Req, Id, UserPassword, LocalAddr, ETag)
      end.
  
  handle_pool_info_wait_wake(Req, Id, UserPassword, LocalAddr, PassedETag) ->
      receive
          wait_expired ->
              handle_pool_info_wait_tail(Req, Id, UserPassword, LocalAddr, PassedETag);
          {notify_watcher, _} ->
              timer:sleep(200), %% delay a bit to catch more notifications
              consume_notifications(),
              handle_pool_info_wait(Req, Id, UserPassword, LocalAddr, PassedETag);
          _ ->
              exit(normal)
      end.
  
negative.code: -export([ns_log_cat/1, ns_log_code_string/1, alert_key/1]).
  
  -export([handle_streaming_wakeup/4,
           handle_pool_info_wait_wake/4]).
  
  -import(menelaus_util,
          [server_header/0,
  