I was recently Lyst’s delegate to the Amazon Web Services re:Invent conference in Las Vegas. It’s their annual show where they announce big new features and EC2 instance types, and also a great opportunity to learn how to make best use of new and existing services. This year was no exception, with the launch of AWS Elastic Container Service, bringing an EC2-like API to the running of Docker containers (see Alex’s recent blog post on Docker), and also AWS Lambda, truly a potential game changer where Amazon will run short lived instances of your own functions to process discrete items of data from an event stream.
We’re fairly heavy users of RabbitMQ here at Global Personals, with 10 distinct workflows spread across 2 separate dual-node clusters. At peak our biggest workflow is around 1,200 messages a second, mostly processed by a Node.js worker. The majority of our workers however are Ruby-based using the Bunny synchronous AMQP gem. Across all our clusters and workloads we process around 3,000 RabbitMQ transactions per second.
…or: How I Learned to Stop Worrying and Love Git Rebase
The globaldev team is gradually becoming more polyglot, and is constantly
churning out more supporting applications to help run our platform. Deploying
all these apps the “old fashioned way” provides a big headache for our
Operations team. Luckily, the industry is moving more and more towards
containerised PaaS-style deployment such as that used by Heroku.
If you need to store an IP address in a database, it’s possibly because you’re logging web requests or similar. This means the table can get very large, very quickly. If you’re storing the addresses in a VARCHAR, you will use up a lot of space in your table and make indexing a nightmare. A lot of people don’t know that you can represent these as an INT which is much more db-friendly.
IPv4 addresses are just 32-bit integers. In most languages (including in MySQL itself, useful for Sphinx indexes) you can use the equivalent of inet_ntoa(3) to convert to string and inet_aton(3) to convert to an int. In Ruby however this is hidden inside the IPAddr class. This instantiation can be quite expensive for what is really a simple conversion, so you can use the following: