Commit 2b7c019b authored by 谢宇轩's avatar 谢宇轩 😅

修改deadline time

parent 864f06bb
...@@ -60,7 +60,7 @@ func MatedateSender(ctx context.Context) { ...@@ -60,7 +60,7 @@ func MatedateSender(ctx context.Context) {
count := bulkRequest.NumberOfActions() count := bulkRequest.NumberOfActions()
if count > 0 { if count > 0 {
log.Printf("Send messages to Index: %d : \n", bulkRequest.NumberOfActions()) log.Printf("Send messages to Index: %d : \n", bulkRequest.NumberOfActions())
timectx, cancel := context.WithTimeout(context.Background(), 500*time.Millisecond) timectx, cancel := context.WithTimeout(context.Background(), 1000*time.Millisecond)
response, err := bulkRequest.Do(timectx) response, err := bulkRequest.Do(timectx)
cancel() cancel()
if err != nil { if err != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment