From a6e7982be6f13d16a51d94ddd23fa7557ad1b052 Mon Sep 17 00:00:00 2001 From: trunglt251292 Date: Sat, 19 Mar 2022 12:08:07 +0700 Subject: [PATCH] [Update] Remove queue --- constants.go | 3 --- queue.go | 15 --------------- 2 files changed, 18 deletions(-) diff --git a/constants.go b/constants.go index ee48263..7fa7ef2 100644 --- a/constants.go +++ b/constants.go @@ -2,17 +2,14 @@ package elasticsearch const ( SubjectRequestProductUpsert = "elasticsearch/selly.request.product.upsert" - SubjectQueueProductUpsert = "elasticsearch/selly.queue.product.upsert" SubjectPullProductUpsert = "elasticsearch/selly.pull.product.upsert" SubjectRequestProductSearch = "elasticsearch/selly.request.product.search" SubjectRequestOrderUpsert = "elasticsearch/selly.request.order.upsert" - SubjectQueueOrderUpsert = "elasticsearch/selly.queue.order.upsert" SubjectPullOrderUpsert = "elasticsearch/selly.pull.order.upsert" SubjectRequestOrderSearch = "elasticsearch/selly.request.order.search" SubjectRequestUserUpsert = "elasticsearch/selly.request.order.upsert" - SubjectQueueUserUpsert = "elasticsearch/selly.queue.order.upsert" SubjectPullUserUpsert = "elasticsearch/selly.pull.order.upsert" SubjectRequestUserSearch = "elasticsearch/selly.request.user.search" ) diff --git a/queue.go b/queue.go index 0c3fbbd..bc1675a 100644 --- a/queue.go +++ b/queue.go @@ -3,18 +3,3 @@ package elasticsearch // Queue ... type Queue struct { } - -// ProductUpsert ... -func (r Queue) ProductUpsert(query UpdateDataPayload) (bool, error) { - return GetClient().PublishWithJetStream(JetStreamSearchService, SubjectQueueProductUpsert, toBytes(query)) -} - -// UserUpsert ... -func (r Queue) UserUpsert(query UpdateDataPayload) (bool, error) { - return GetClient().PublishWithJetStream(JetStreamSearchService, SubjectQueueUserUpsert, toBytes(query)) -} - -// OrderUpsert ... -func (r Queue) OrderUpsert(query UpdateDataPayload) (bool, error) { - return GetClient().PublishWithJetStream(JetStreamSearchService, SubjectQueueOrderUpsert, toBytes(query)) -}