# Mutation performance issue

**URL:** <https://discuss.dgraph.io/t/mutation-performance-issue/14698>\
**Category:** Dgraph\
**Tags:** kind:question\
**Created:** [June 23, 2021, 6:47am UTC](https://discuss.dgraph.io/t/mutation-performance-issue/14698 "2021-06-23T06:47:03Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![manuvm](https://avatars.discourse-cdn.com/v4/letter/m/7ea924/32.png) [@manuvm](https://discuss.dgraph.io/u/manuvm)\
**Post date:** [June 23, 2021, 6:47am UTC](https://discuss.dgraph.io/t/mutation-performance-issue/14698/1 "2021-06-23T06:47:03Z")

</div>

Trying to mutate data into dgraph and read it.

Please list the high level idea of what you want to do

We have a POSt and GET api created in golang (dgo client). There is a batch program which will invoke the POST api to create / mutate data into draph and read it using the GET. WE have used trasaction and commit as true. But seems like the data is taking a while to get reflected in dgraph and hence the GET fails.

Please list the things you have tried.

## Dgraph metadata

> **dgraph version**
>
> Dgraph version : v20.07.2  
> Dgraph codename : shuri-2  
> Dgraph SHA-256 : a927845127dab735c24727d5a24af411168771b55236aec50f0b987e8c0ac910  
> Commit SHA-1 : a7bc16d56  
> Commit timestamp : 2020-10-22 10:17:53 -0700  
> Branch : HEAD  
> Go version : go1.14.4

---

<div class="post-metadata">

**Author:** ![MichelDiz](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/micheldiz/32/11873_2.png) [@MichelDiz](https://discuss.dgraph.io/u/MichelDiz)\
**Post date:** [June 23, 2021, 12:50pm UTC](https://discuss.dgraph.io/t/mutation-performance-issue/14698/2 "2021-06-23T12:50:25Z")

</div>

Share details of your deployment and load weight. Without it there’s no way to be sure.

---

<div class="post-metadata">

**Author:** ![manuvm](https://avatars.discourse-cdn.com/v4/letter/m/7ea924/32.png) [@manuvm](https://discuss.dgraph.io/u/manuvm)\
**Post date:** [June 24, 2021, 6:16am UTC](https://discuss.dgraph.io/t/mutation-performance-issue/14698/3 "2021-06-24T06:16:45Z")

</div>

We have a 32GB memory unix box (aws)  
There is not much data in there may be in 100s not more than that.  
Its a fresh application that we ar building.

Generally, is there a consistency iissue noted? I cam across an old thread where someone had mentioned similar issue in 2019

---

<div class="post-metadata">

**Author:** ![iluminae](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/iluminae/32/7367_2.png) [@iluminae](https://discuss.dgraph.io/u/iluminae)\
**Post date:** [June 24, 2021, 2:09pm UTC](https://discuss.dgraph.io/t/mutation-performance-issue/14698/4 "2021-06-24T14:09:25Z")

</div>

Not enough information to say if it is this, but I believe the following would possibly show what you have been seeing:

1. txn gets in and commits as TS=X on peer 1.
2. query is made with best-effort=true and hits peer 2 (same group but replicated raft member).
3. peer 2 is only caught up to TS\<X, but since query is best-effort, he will not get a timestamp from the zero to ensure he has TS\>=X.
4. peer 2 serves request with TS=\<X and goes about his day.

Someone can jump in and correct me if I am wrong but I believe the above is possible if you use best effort queries. Is that the case? If so, can you try without best-effort?
