Project

diode

0.0
The project is in a healthy, maintained state
Diode helps you to build REST application servers by providing a container for your servlets. About as simple as rack but more powerful, and nowhere near as complex as passenger, Diode has only four classes that make it easy to get up and running quickly, and provides more features as you progress, but only if you want them.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 2
~> 2
 Project Readme

Diode

Diode

Diode lets you quickly build a fast, simple, pure-ruby application server.

Gem Version

Installation

Add this line to your application's Gemfile:

gem 'diode'

And then execute:

$ bundle

Or install it yourself as:

$ gem install diode

Usage

class Hello
  def serve(request)
    body = JSON.dump({ "message": "Hello World!" })
    Diode::Response.new(200, body)
  end
end

require 'diode/server'
routing = [
  [%r{^/}, "Hello"]
]
Diode::Server.new(3999, routing).start
# visit http://localhost:3999/

Documentation

Please see the wiki for more details.

Contributing

We welcome contributions to this project.

  1. Fork it.
  2. Create your feature branch (git checkout -b my-new-feature).
  3. Commit your changes (git commit -am 'Add some feature').
  4. Push to the branch (git push origin my-new-feature).
  5. Create new Pull Request.