Oftentimes it’s necessary to write an application in which there are multiple threads that are mostly independent from one another, but require a sync up occasionally before proceeding. This is a great use case for a CyclicBarrier. It is called a Barrier because it prevents threads from proceeding, and it is called Cyclic because once […]
Java FutureTasks are a great means of offloading a computation so that you can worry about it later, but they can be tricky to use. In this post we’ll dive into a few examples to explain the utility of this java feature. A bit on Callable Before understanding a FutureTask, we must first understand a […]
It’s been a while since I’ve posted in the blog but I’ll doing so more this year. It’s starts today with a brand new site layout.
The common ‘ls’ command will allow you to display the inode numbers associated with each file in the directory. All that’s needed is supplying the ‘-i’ option. It will display the inode number right next to the file.
It’s possible to run several commands in a sed one-liner. All you have to do is separate the instructions with a semicolon:
I’ve been spending a lot of time diving into the Scala programming language as well as the Play Framework. Along with some others, I’ll be authoring posts, tutorials and tips regarding these two projects at adurolucis.
Sed is often used to replace words in input, but did you know that you can replace a set of characters with another set of corresponding characters? This is accomplished by use of the ‘y’ command. It’s essentially the same as the ‘tr’ utility and works as follows: An example of replacing all uppercase vowels […]
If you are redirecting the output of ls to a file, it will output a single file per line. Use the -C option to have ls output its usual column format
This book is one of the highest rated Java books in existence. The main reason that I chose to read this book is because one of my colleagues highly recommended it. Needless to say, I have to jump on the bandwagon and join in with all of the hoopla and praise that’s associated with this […]
Quick Vim tip that I wanted to share: When in Insert Mode: Ctrl + y – copy the character above the cursor into the current line Ctrl + e – copy the character below the cursor into the current line