Create a gist now

Instantly share code, notes, and snippets.

require 'celluloid'
class FilePutter
include Celluloid
def initialize(filename)
@filename = filename
end
def load_file_and_print
@file_contents = File.read @filename
p @file_contents
end
end
files = ["/var/log/kernel.log", "/var/log/system.log", "/var/log/ppp.log", "/var/log/secure.log"]
files.each do |file|
fp = FilePutter.new file
fp.load_file_and_print!
end
@xbeta

Because of this change: celluloid/celluloid#82

Change to

fp.async.load_file_and_print
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment