Exemplo n.º 1
0
 /// <summary>
 /// 服务反注册
 /// </summary>
 public IActionResult OnPostAsync(string serviceName)
 {
     ViewData["HttpMethod"]  = "post";
     ViewData["ServiceName"] = serviceName;
     _consulSrv.UnRegService(serviceName).GetAwaiter().GetResult();
     return(Page());
 }
        /// <summary>
        /// 服务反注册
        /// </summary>
        public async Task <IActionResult> OnPostAsync(string serviceName)
        {
            ViewData["HttpMethod"]  = "post";
            ViewData["ServiceName"] = serviceName;
            await _consulSrv.UnRegService(serviceName);

            return(Page());
        }