Perl and the Elasticsearch percolator

Quote

Intro

For our most recent hack day, I worked with my colleagues Antonio Barone and Nelio Nunes to implement an alert-me-when function for our site. In production, we use Solr at the moment as the search engine to serve our frontend. Unfortunately, implementing alerting functionality with it means you have to go down a do-it-yourself route.

Continue reading

Announcements

NAP::Messaging – glue and policies for interacting with ActiveMQ

As part of our service oriented architecture, our Perl applications send messages over ActiveMQ; a few of them also consume those messages and act on them.

All these consumer applications are based on Catalyst. Initially, we used Catalyst::Engine::Stomp and a rather complicated set of in-house libraries to wrap it.

Those in-house libraries have, in time, grown to incorporate more and more responsibilities, including testing, logging, message serialisation, plugin loading… it was time to break them apart and write something cleaner.

Continue reading

Perl

Learning the perl debugger: Lesson 3

pbug-workshop-attendees

This post follows on from lesson 2 in this series of posts.

If you’ve followed the lessons so far you’ll have some basic knowledge around starting the debugger and examining variables.

It’s time to find out how to descend into the depths of some code, stepping into functions.

Continue reading

Open Source

Asynchronous web services with PSGI and IO::Async

Some of our internal web applications are low-traffic enough that a
preforking server can handle them without difficulty. Some others, on
the other hand, can really benefit from a non-blocking implementation,
so that each server process can serve multiple requests “at the same
time”, by working on a request while waiting for other services to
return data for other requests.

Up to now all our non-blocking web services were written for the JVM,
usually with the Akka framework, but I wanted to see how hard would it
be to build something similar in Perl.

Turns out, it’s not very hard at all, if you use the right libraries
and pay attention at a few tricks.

Continue reading