# Question about controller threading

**URL:** <https://discuss.rubyonrails.org/t/question-about-controller-threading/8261>\
**Category:** rubyonrails-talk\
**Created:** [February 6, 2007, 7:55am UTC](https://discuss.rubyonrails.org/t/question-about-controller-threading/8261 "2007-02-06T07:55:28Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pat\_Maddox](https://avatars.discourse-cdn.com/v4/letter/p/eb9ed0/32.png) [@Pat\_Maddox](https://discuss.rubyonrails.org/u/Pat_Maddox)\
**Post date:** [February 6, 2007, 7:55am UTC](https://discuss.rubyonrails.org/t/question-about-controller-threading/8261/1 "2007-02-06T07:55:28Z")

</div>

Rails is single-threaded, so I don't have to worry about changing stuff around when a request is made, right? I'm going to be using ActiveResource, but don't know ahead of time what the class's site will be. So basically on every request I'll be changing it (if I need to). Is it okay to do that? Once a request is made, no other requests can use the process...so as long as I update MyARes.site I should be okay. Is there a better all around way to do it?

Pat

---

<div class="post-metadata">

**Author:** ![Dan\_Manges1](https://avatars.discourse-cdn.com/v4/letter/d/839c29/32.png) [@Dan\_Manges1](https://discuss.rubyonrails.org/u/Dan_Manges1)\
**Post date:** [February 6, 2007, 8:57pm UTC](https://discuss.rubyonrails.org/t/question-about-controller-threading/8261/2 "2007-02-06T20:57:41Z")

</div>

Seems like a fine approach to me, although I am not very familiar with ARes. Jamis just posted about setting the timezone per request, which has the same approach: [http://weblog.jamisbuck.org/2007/2/2/introducing-tztime](http://weblog.jamisbuck.org/2007/2/2/introducing-tztime)

Dan Manges
