I’ve had a couple of personal projects on my mind for a while. I need a few simple tools that exist in other forms but would, as programming projects, lend themselves to programming experimentation. Plus, I like to build my own tools.

The tool I need the most is a time keeping application. The requirements are super simple.

It:

must store information about projects.

must make it easy to store start and stop times for tasks within projects.

must store some metadata about each task.

must provide summary information about the time spent at the task level and project level.

should be available across devices.

should have keyboard shortcut accessible features.

should have text based shortcuts for selecting project names. For example, typing # should bring up a list of projects to chose from or #project_name should automatically associate a task with its project.

would be nice if the application could remind me to check in with it every once in a while.

Now, I’m spoiled. I came to Rust from Scala and still work with Scala regularly. The Scala ecosystem is flush with good web application frameworks the most notable being Play which I love and is my tool of choice for web applications. But, in addition to needing tools, I’m very curious about the state of web application development in Rust.

Therefore I decided I’m going to write my time tracking application in Rust.

I spent some time going through the documentation for the most prominent of the Rust web frameworks, Iron and nickel.rs, to see where they stand. In the end I chose to build my application in Iron for a few reasons to which I’ll come back.

As for my first impressions of the most prominent Rust web frameworks? My initial impressions aren’t good. Here they are in rough order of importance.

Most importantly, both projects need better documentation. In fact, the reason I decided to write this series of posts is because I could not find a decent tutorial for writing an application in Iron. This series is my contribution to the documentation effort.

Both projects seem really complicated for turnkey web application frameworks attempting to be tent poles in the Rust ecosystem. The modules/plugins/extension/modifier system in Iron, in particular, is woefully under documented and uses a nomenclature which is kinda sorta explained but you have to go looking for the explanation and then squint really hard to understand it. modules/plugins/extension/modifier; All of those words are used in the docs and I still have no idea what their differences are. I hope to figure it out quickly.

Here’s the thing about the extension system though. I don’t want to figure out what extensions I need just to get a simple application up and running. I expect that when I start to use a web application framework it’s going to have most of what I need to drive off the lot. As of right now, it looks like I have the engine but I need to find tires, a steering wheel, lights, seats would be nice… and on and on and on. I’m sure all of this stuff exists and I understand these projects are still young and eventually it will be easier to get started with them, but right now it isn’t easy and this is why documentation is super important.

The view templating story is very, very, very short and boring. I have the option of using any templating framework I want as long as it’s handlebars or handlebars or handlebars or something I write (not going to happen).

Database support looks to be abysmal.

Finally, I chose Iron because it seems like the more mature of the two frameworks, with more users which looks to be super important due to the lack of documentation, and because I’m not a fan of express.js, the inspiration for nickel.rs. I may try out nickel for my next project.

In summary, I’m not feeling great about this experiment. I think the developers of both projects should stop writing code and spend some time on the documentation. Documentation is one of the biggest problems in the Rust ecosystem right now and, while web development isn’t necessarily the target for Rust, it wouldn’t hurt if we had some top notch web application frameworks with good documentation. I’m going to do my part for Iron by documenting my project as I work on it. If nothing else, maybe some good docs will come out of this work.