Hi,
We are doing bulk operations with gocb/v2.
While inserting 10 documents in each bulk call we see that data is getting misplaced into other key.
var sellocPincodeDataBulk []gocb.BulkOp
for key, value := range MapData {
if key != value.FName+"#"+value.LName {
fmt.Println("Values is different from ID: ", key," " ,vaa
lue.Selloc+"#"+value.Pincode)
}
MapDataBulk = append(MapDataBulk, &gg
ocb.InsertOp{ID: key, Value: &value})
count++
if count%10 == 0 && count != 0 {
err = Collection.Do(MapDataBulk, &gocbb
.BulkOpOptions{})
if err != nil {
fmt.Println("ERRROR PERFORMING BULK INSEE
RT:", err)
} else {
fmt.Println("inserted 10 docs for")
}
MapDataBulk = []gocb.BulkOp{}
}
}
When we do 1 doc insert with gocb.bulk{} it works fine. But when we insert 10 then it is misplacing one key’s data to other key.
My Doc key is a combination of LastName and FirstName which is also part of Doc Value So that I am able to find that data is getting misplaced.
Please let me know if you need any info.
Thanks,
Akhil