From 297782f089943fd9dbf68b1ef2a0d185c537e226 Mon Sep 17 00:00:00 2001 From: trunglt251292 Date: Fri, 1 Apr 2022 10:15:11 +0700 Subject: [PATCH] [Update] Delete multiple index --- constants.go | 2 ++ request.go | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/constants.go b/constants.go index 8e004ab..4001f1d 100644 --- a/constants.go +++ b/constants.go @@ -20,6 +20,8 @@ const ( SubjectPullUserUpsert = "selly.pull.user.upsert" SubjectRequestUserSearch = "selly.request.user.search" SubjectRequestUserCreateIndex = "selly.request.user.create_index" + + SubjectRequestDeleteMultipleIndex = "selly.request.delete.multiple_index" ) const ( diff --git a/request.go b/request.go index 8a13a80..d2f87a4 100644 --- a/request.go +++ b/request.go @@ -63,3 +63,8 @@ func (Request) KeywordUpsert(payload Payload) (*Response, error) { func (Request) KeywordCreateIndex() (*Response, error) { return requestNats(SubjectRequestKeywordCreateIndex, toBytes(Payload{})) } + +// DeleteMultipleIndex ... +func (Request) DeleteMultipleIndex(indexes []string) (*Response, error) { + return requestNats(SubjectRequestDeleteMultipleIndex, toBytes(indexes)) +}