Sha256: af0e44e25b19fd5b06664842bcea6c7c0ff96f74055c58cfa1ab45570be84d89

Contents?: true

Size: 345 Bytes

Versions: 84

Compression:

Stored size: 345 Bytes

Contents

#! /usr/bin/env ruby

require 'socket'
server = TCPServer.new('127.0.0.1', 9090)
while (session = server.accept)
  puts "Found a session"
  request = session.gets
  puts "Request: #{request}"
  time = request.to_i
  puts "Sleeping for #{time}"
  sleep time
  session.print "Slept for #{time} seconds"
  session.close
  puts "Session closed"
end

Version data entries

84 entries across 84 versions & 23 rubygems

Version Path
samhendley-god-0.7.13 test/configs/degrading_lambda/tcp_server.rb
strobemonkey-god-0.7.13 test/configs/degrading_lambda/tcp_server.rb
god-0.13.4 test/configs/degrading_lambda/tcp_server.rb
god-0.13.3 test/configs/degrading_lambda/tcp_server.rb
god-0.13.2 test/configs/degrading_lambda/tcp_server.rb
god-0.13.1 test/configs/degrading_lambda/tcp_server.rb
god-0.13.0 test/configs/degrading_lambda/tcp_server.rb
god-0.12.1 test/configs/degrading_lambda/tcp_server.rb
god-0.12.0 test/configs/degrading_lambda/tcp_server.rb
firenxis-god-0.11.0 test/configs/degrading_lambda/tcp_server.rb
god-0.11.0 test/configs/degrading_lambda/tcp_server.rb
god-0.10.1 test/configs/degrading_lambda/tcp_server.rb
god-0.9.0 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.9.2 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.9.1 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.9.0 test/configs/degrading_lambda/tcp_server.rb
god-0.8.0 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.8.2 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.8.1 test/configs/degrading_lambda/tcp_server.rb
olgen-god-0.8.0 test/configs/degrading_lambda/tcp_server.rb