Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Tree: 47509228ab
16 lines (16 sloc) 0.555 kB
require 'json'
require 'iron_cache'
require 'models/complex_model'
puts "Got params:#{params.inspect}"
puts "Deserializing"
complex_model = JSON.load params["complex_model"]
puts "Performing calculations"
complex_model.calculate
puts "pushing model to iron_cache"
puts complex_model.to_json
iron_config = JSON.parse(params['iron_config'])
puts "Initializing cache :#{iron_config.inspect}"
client = IronCache::Client.new(iron_config)
cache = client.cache("IronWorker101Example")
puts "Putting model to cache"
cache.put(@iron_task_id, complex_model.to_json)
Jump to Line
Something went wrong with that request. Please try again.