Notice: The website is currently being udpated. Sorry for any inconvenience.
Introduction
Halcyon is a JSON Web App Framework built on Rack for speed and light weight.
Halcyon has several aims and goals, including:
- Be fast—easy with Rack and Mongrel or Thin
- Be small—also not a problem with Rack and Mongrel
- Be cross-platform—communications are flexible with JSON transport layer
- Be flexible—since it uses HTTP, it’s very simple to be flexible
- Be easy to implement—also easy since we’re developing in Ruby here
Functionality & Performance
With Mongrel leading the pack and Rack holding things up, JSON doing the fast talking and with plenty of room to spare, how could you not be interested, even about this new framework? Still not convinced? OK, fair enough, here’s some code for you.
1 class Messages < Application 2 def new 3 # respond with fields acceptable 4 ok [:body, :title, :tags] 5 end 6 def create 7 case method 8 when :post 9 DB[:messages] << params 10 ok 11 else 12 raise NotImplemented 13 end 14 end 15 def read 16 ok DB[:messages][params[:id]] 17 end 18 def update 19 case method 20 when :post 21 DB[:messages].filter(:id => params[:id]).update(params) 22 ok 23 else 24 raise NotImplemented 25 end 26 end 27 def delete 28 DB[:messages].filter(:id => params[:id]).delete 29 ok 30 end 31 end
$ halcyon start -p 4647
That’s all it takes to open up the door to let you communicate with your applications that implement or use the simple client.
Read the Docs.
Supported Platforms
Halcyon is primarily written in Ruby, but Halcyon also supports multiple platforms due to the fact that it communicates via HTTP and packages its messages in JSON. Halcyon currently has Ruby, PHP, and Java clients available, with more clients planned.
Metrics
Ohloh’s pretty cool and we use it to track the development metrics of Halcyon. Check out some of the more interesting details on our project page. You can find the link at the top of the page.
For your viewing pleasure, here are some of the Ohloh project factoids:
Note: It says that Halcyon is mostly written in Java because we include the client libraries in the code base, each of which can have their own extensive dependencies, including the Java one. Since Ruby’s syntax is much leaner, Java’s line count overtakes the Ruby line count even though the Java code is only for the client library.
I'm speaking at
RubyFringe
about Halcyon in mid-July along with several other notable Ruby developers. RubyFringe is unlike most other Ruby conferences... check it out!
About
Halcyon is a JSON Web App Framework built on Rack for speed and light weight.
Recent Entries
Installation
Installation is easy, all you need is RubyGems and you're set. Just run the following:
$ sudo gem install halcyon
If you're interested in the most recent version, check out our GitHub page (link above). You can install the latest development version with these steps:
$ git clone git://github.com/mtodd/halcyon.git
$ cd halcyon && rake install
This will get the latest version of Halcyon and run the install task.
Note:
Due to limitations, only json_pure is a dependency since it is supported on all platforms. However, for faster performance, make sure you run this command which will install the faster C extension of JSON:
$ sudo gem install json
Community
Welcome to the infantile community, I really hope you do choose to stay with us for a while and help us get our feet on the ground.
There are several ways to participate: on IRC, you can find us at #halcyon on irc.freenode.net. Join us on our mailing list hosted by GOogle Groups. Regardless, you can always get a hold of Matt Todd via his email address.