从Elastic Search中删除索引时,我收到HTTP错误:403。删除索引的代码如下:
static void DeleteIndex(string indexName)
{
// Delete index, recreate
if (_client.IndexExists(desc => desc.Index(indexName)).Exists)
{
var response = _client.DeleteIndex(desc => desc.Index(indexName));
if (!response.IsValid)
{
Console.WriteLine(response.ConnectionStatus);
Console.WriteLine("Press any key to continue");
Console.ReadKey();
}
}
}
有关如何删除禁用错误的任何指示?