RGW creates a new, unique req_state for each incoming request. In general, only one thread is operating on a request (or it's unique req_state instance) at any time. A special case is when (lower level) RADOS operations are being started and completed during the processing of the RGW request--a different set of (currently) threads is responsible for executing the RADOS operations, so there is locking involved. Matt On Wed, May 20, 2020 at 9:20 AM Abhinav Singh <singhabhinav0796@xxxxxxxxx> wrote: > > Hello everyone, > > I have a doubt, > > What I seems to understand : > > when a client makes a req to rgw, then the req is spawn into multiple threads and the each of the thread will have its own req_state instances, and so if I define any data structure inside req_state then there cant be any race condition right to that data structure > > Am I right? If not then does this mean that req_state is global to multiple threads and there is chance of race condition? > _______________________________________________ > Dev mailing list -- dev@xxxxxxx > To unsubscribe send an email to dev-leave@xxxxxxx -- Matt Benjamin Red Hat, Inc. 315 West Huron Street, Suite 140A Ann Arbor, Michigan 48103 http://www.redhat.com/en/technologies/storage tel. 734-821-5101 fax. 734-769-8938 cel. 734-216-5309 _______________________________________________ Dev mailing list -- dev@xxxxxxx To unsubscribe send an email to dev-leave@xxxxxxx