Read issue in MongoDB asynchronous replication -


i'm new mongodb. created java app using mongodb database. configured 3 servers in replica set. pseudo code: {

createuser getuser updateuser

}

here createuser creates user getuser fails return user in somtimes.

when analysed due data replication latency.

how can overcome issue?

is there anyway replicate data when created?

is there other way user without fail?

thx in advance!

if issue due replication latency, 1 thing can make sure writes safe , using w flag. way, mongodb wait until data replicated @ least n nodes before returning. can client driver well.

mongodb getlasterror

are reading slaveok=true ? if read replicaset primary, shouldn't issue either.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -