# Thread safety resources

**URL:** <https://www.ruby-forum.com/t/thread-safety-resources/155352>\
**Category:** Ruby\
**Created:** [December 10, 2008, 11:19pm UTC](https://www.ruby-forum.com/t/thread-safety-resources/155352 "2008-12-10T23:19:31Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tjholowaychuk](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/82dd89/32.png) [@tjholowaychuk](https://www.ruby-forum.com/u/tjholowaychuk)\
**Post date:** [December 10, 2008, 11:19pm UTC](https://www.ruby-forum.com/t/thread-safety-resources/155352/1 "2008-12-10T23:19:31Z")

</div>

What would you consider the cleanest, yet effective way to produce  
thread-safe libraries? any tips or suggestions for a Ruby newb would be  
fantastic

---

<div class="post-metadata">

**Author:** ![tjholowaychuk](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/82dd89/32.png) [@tjholowaychuk](https://www.ruby-forum.com/u/tjholowaychuk)\
**Post date:** [December 10, 2008, 11:31pm UTC](https://www.ruby-forum.com/t/thread-safety-resources/155352/2 "2008-12-10T23:31:41Z")

</div>

Tj Holowaychuk wrote:

> What would you consider the cleanest, yet effective way to produce  
> thread-safe libraries? any tips or suggestions for a Ruby newb would be  
> fantastic

Does your library use threads itself, or do you just want your library  
to be callable from multiple threads?

---

<div class="post-metadata">

**Author:** ![tjholowaychuk](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/82dd89/32.png) [@tjholowaychuk](https://www.ruby-forum.com/u/tjholowaychuk)\
**Post date:** [December 10, 2008, 11:48pm UTC](https://www.ruby-forum.com/t/thread-safety-resources/155352/3 "2008-12-10T23:48:49Z")

</div>

Im not talking about any one library specifically, but I suppose both  
would certainly be good to learn. I have been looking through the  
standard library and others trying to discover consistent / clean  
conventions but I have seen a few variants and I am not quite sure about  
the ideal way to create thread safety within the library itself as well  
as execution from within threads like you mentioned
