anchor.diff:  
       ok = ssl_manager:clear_pem_cache().
   
  -restart_ssl_services() ->
  +all_services() ->
  +    [ssl_service, capi_ssl_service, xdcr_proxy, query_svc, memcached].
  +
  +notify_service(ssl_service) ->
       %% NOTE: We're going to talk to our supervisor so if we do it
       %% synchronously there's chance of deadlock if supervisor is about
       %% to shutdown us.
  
positive.code: handle_cast(_, State) ->
      {noreply, State}.
  
  handle_info(cert_and_pkey_changed, OldState) ->
      misc:flush(cert_and_pkey_changed),
      {CertPEM, PKeyPEM} = ns_server_cert:cluster_cert_and_pkey_pem(),
      Compat30 = cluster_compat_mode:is_cluster_30(),
      Node = node(),
      NewState = build_state(CertPEM, PKeyPEM, Compat30, Node),
      case OldState =:= NewState of
          true ->
              {noreply, OldState};
          false ->
              ?log_info("Got certificate and pkey change"),
              save_cert_pkey(CertPEM, PKeyPEM, Compat30, Node),
              ?log_info("Wrote new pem file"),
              restart_ssl_services(),
              ?log_info("Restarted all ssl services"),
              {noreply, NewState}
      end;
  handle_info(_Info, State) ->
      {noreply, State}.
  
  
negative.code:     ns_config:sync_announcements(),
      ok = gen_server:call(?MODULE, ping, infinity).
  
  build_cert_state(CertPEM, PKeyPEM, Compat30, Node) ->
      BaseState = #cert_state{cert = CertPEM,
                              pkey = PKeyPEM,
                              compat_30 = Compat30},
      case Compat30 of
          true ->
              BaseState#cert_state{node = Node};
          false ->
              BaseState
      end.
  