// DELETE /schema/:index
//
// delete the schema file and all the stored index files.
//
// path parameter
//  - index  name of index
DELETE /schema/:index

delete the schema file and all the stored index files.

path parameter
- index  name of index
// DELETE / schema / : index // // delete the schema file and all the stored index files . // // path parameter // - index name of index
func DeleteSchema(c *mgin.Context) {
	index := c.Param("index")
	indexer.RemoveIndexer(index)
	if err := conf.DeleteSchema(index); err != nil {
		c.Error(http.StatusInternalServerError, err.Error())
		return
	}
	c.JSON(http.StatusOK, map[string]interface{}{
		"code": http.StatusOK,
		"msg": "schema deleted",
		"index": index,
	})
}
func DeleteSchema ( c * mgin . Context ) { index := c . Param ( " " ) indexer . RemoveIndexer ( index ) if err := conf . DeleteSchema ( index ) ; err != nil { c . Error ( http . StatusInternalServerError , err . Error ( ) ) return } c . JSON ( http . StatusOK , map [ string ] interface { } { " " : http . StatusOK , " " : " " , " " : index , } ) }
DELETE /schema/:index
DELETE / schema / : index