TimedSemaphore implementation in Ruby

Ruby is a programming language¬†with a focus on simplicity and productivity. However, it lacks in performance comparing to other programming languages, especially in applications which make a lot of non-blocking operations like database and network calls. Concurrency can help with this, even though Ruby doesn’t support true multithreading (talking about MRI). The problem is that Ruby doesn’t provide many synchronization¬†primitives, like some other languages designed with concurrency in mind (e.g Go). This post will show an implementation of a class based on lower level mechanisms for synchronization: TimedSemaphore.

read more
Sadzid SuljicTimedSemaphore implementation in Ruby

Debugging Ruby and Rails applications

Debugging is an everyday reality for developers. We are using debugger, printing to STDOUT or some other way to analyze inner processing of our applications. Debugging is great, we can learn a lot trough this process. Some technologies are better at debugging, some less so. Ruby is on a lower end of this spectrum but steadily climbing. While moving from Java to Ruby I was surprised that Ruby did not have IDE for debugging, debugging was only possible through a console. There have been some stabs at this problem, but most of IDE debug solutions for Ruby are simply not that good.

read more
Haris KrajinaDebugging Ruby and Rails applications