basho/riak_pipe — pull request #51 by beerriot (2012-08-01 18:56:16+00:00)
Title: avoid race to code:load_file by using code:ensure_loaded instead

It appears that R15B01 changed the triggers for when the "Module X must be purged before
loading" error is logged (as compared to R14B04).

As reported here: http://lists.basho.com/pipermail/riak-users_lists.basho.com/2012-July/008828.html

This patch should fix the issue by avoiding the race between the check on `is_loaded` and the call to `load_file`.