Skip to content

Instantly share code, notes, and snippets.

@kyledrake
Created June 20, 2016 21:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kyledrake/46f7188022d956de08ced4cbe4754c11 to your computer and use it in GitHub Desktop.
Save kyledrake/46f7188022d956de08ced4cbe4754c11 to your computer and use it in GitHub Desktop.
Crystal HTTP Benchmark
# A very basic HTTP server
require "http/server"
server = HTTP::Server.new(8080) do |context|
context.response.content_type = "text/plain"
context.response.print "Hello world"
end
puts "Listening on http://0.0.0.0:8080"
server.listen
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment