SoftInstigate / restheart

Rapid API Development with MongoDB
https://restheart.org
GNU Affero General Public License v3.0
807 stars 171 forks source link

Read Preference per request #450

Closed WT2 closed 1 year ago

WT2 commented 1 year ago

Hello Guys

Is there a way to choose the Read Preference for a given request, via a parameter in the url? If this parameter exists, it overrides the default one we put on the mongodb connection string. If not, i think it will be a nive improvement.

Thanks

ujibang commented 1 year ago

you can do it, see https://restheart.org/docs/upgrade-to-v7#allow-to-specify-readconcern-writeconcern-and-readpreference-at-request-level

WT2 commented 1 year ago

yep great working well :) thanks guys