public ActionResult DeleteIndex()
        {
            ElasticsearchHelper.DeleteIndex("genres");
            string mesaj = "<script language='javascript' type='text/javascript'>alert('Silme İşlemi Başarıyla Gerçekleşmiştir!');window.location.href = '/home/index/';</script>";

            return(Content(mesaj));
        }
Ejemplo n.º 2
0
        private static void CleanElasticsearch()
        {
            var elasticsearchUri = ConfigurationManager.AppSettings["ElasticsearchUri"];

            try
            {
                ElasticsearchHelper.DeleteIndex(elasticsearchUri);
            }
            catch (Exception exp)
            {
                Assert.Inconclusive(String.Format("Error occured connecting to ES: Message{0}, StackTrace: {1}", exp.Message, exp.StackTrace));
            }
        }