how to persist db.getMongo().setSlaveOk()

Showing 1-7 of 7 messages
how to persist db.getMongo().setSlaveOk() Alex Howansky 9/14/10 1:42 PM

I've got a replica set up and running and, near as I can tell, it's
working just fine. However, I'm having problems querying the slaves. The
db.getMongo().setSlaveOk() setting doesn't seem to persist across
connections. Is there some way to specify this in a manner where it will
be allowed by default? (E.g., in order to use mongofiles or nginx-gridfs.)

Thanks,

--
Alex

Re: how to persist db.getMongo().setSlaveOk() roger 9/14/10 2:36 PM

If I understand you correctly, you'll need to pass the slaveok option
at the connection level in your driver. What language / driver are you
using ?

-Roger
Re: [mongodb-user] Re: how to persist db.getMongo().setSlaveOk() Kristina Chodorow 9/14/10 2:43 PM
slaveOk is set for each request, so there's no way (at the moment) to say it's "okay for everyone."  You could file a feature request for the tools your using (mongofiles, nginx-gridfs) for them to add a slaveOkay option.


--
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To post to this group, send email to mongod...@googlegroups.com.
To unsubscribe from this group, send email to mongodb-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mongodb-user?hl=en.


Re: [mongodb-user] Re: how to persist db.getMongo().setSlaveOk() Alex Howansky 9/14/10 3:40 PM
> If I understand you correctly, you'll need to pass the slaveok option
> at the connection level in your driver. What language / driver are you
> using ?

I'm not using any driver directly. I'm using either mongofiles or
nginx-gridfs, neither of which (to my knowledge) support this setting on
the client side.

--
Alex

Re: [mongodb-user] Re: how to persist db.getMongo().setSlaveOk() Alex Howansky 9/14/10 3:53 PM
> slaveOk is set for each request, so there's no way (at the moment) to
> say it's "okay for everyone."  You could file a feature request for the
> tools your using (mongofiles, nginx-gridfs) for them to add a slaveOkay
> option.

Nuts, looks like I have to wait for this:

http://github.com/mdirolf/nginx-gridfs/issues#issue/11

--
Alex

Re: [mongodb-user] Re: how to persist db.getMongo().setSlaveOk() Kristina Chodorow 9/14/10 3:56 PM
You can vote for/track the jira case, it should be done this fall.


Alex

--
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To post to this group, send email to mongod...@googlegroups.com.
To unsubscribe from this group, send email to mongodb-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mongodb-user?hl=en.


Re: how to persist db.getMongo().setSlaveOk() roger 9/14/10 4:05 PM

Ok thanks. Per Kristina's post, it sounds like you'll have to request
feature enhancements for that. -Roger