Get the source
0.8 (1.8MB)

Rootin Tootin is a fast and easy Web Framework that uses D

  • Start
  • Install
  • News
  • Development
  • Tutorial
  • API
  • Status

Why use Rootin Tootin?

  1. It is written in D, so it is fast and uses little memory.
  2. It uses the MVC design paradigm made popular by Rails.
  3. It uses RESTful URLs like Rails and Django.
  4. It statically links everything. So it will 'Just Work' even on generic virtual hosts.
  5. It precompiles templates, so it does not have to parse them at runtime.
  6. It has an ORM that enforces referential integrity by default. So no more dangling foreign key errors.
  7. It will soon be nonblocking like node.js.
  8. It uses JSON configuration files.

How do I create a project?

rootintootin name:journal port:3000 db_user:root db_password:letmein
cd journal
./gen recreate development database
./gen create noun singular:note plural:notes
./gen create scaffold note title:unique_string content:text \
validates presence_of:title,content
./gen migrate development
./run
Linux
FreeBSD
Windows
Trunk

Download and install on Linux:

wget http://launchpad.net/rester/trunk/0.8/+download/rootintootin-0.8.0.tar.gz
tar -zxvf rootintootin-0.8.0.tar.gz
cd rootintootin-0.8.0
sudo ./make install
wget http://launchpad.net/rester/trunk/0.7/+download/rootintootin-0.7.0.tar.gz
tar -zxvf rootintootin-0.7.0.tar.gz
cd rootintootin-0.7.0
sudo make install_python2.6

Apparently you can install LDC on FreeBSD from here. But I have yet to get it to work. Please email mattjones@rootin.toot.in if you can help get this to work.

I have yet to get LDC and tango installed on Windows. The only information I have found on it is here. Please email mattjones@rootin.toot.in if you can help get this to work.

Download and install from source:

bzr branch lp:rester rootintootin
cd rootintootin
sudo ./make dev

Release 0.8 - June 10, 2011

This release is about making it easier to install on different Linux distros. It should now actually work on x86 64bit systems.

  • Fixed Bug #787911: 'Move to using official LDC and Tango builds'.
  • Fixed Bug #789736: 'Use Python platform.dist instead of lsb_release'.
  • Fixed Bug #751094: 'Move to a python based makefile'.
  • Fixed Bug #751100: 'Make it install and build on openSUSE'.
  • Fixed Bug #742975: 'Have manual install use python site-packages and dist-packages'.
  • Fixed Bug #743380: 'Requirement libmysqlclient16-dev should be libmysqlclient-dev'.
  • Fixed Bug #742952: 'LSB Release is missing as a Fedora requirement'.
  • Fixed Bug #722510: 'Rebuilding no longer picks up code changes'.

Release 0.7 - January 1, 2011

This release is about making the framework complete enough to be usable. Major features include an API reference, unit tests, and bug fixes.

  • Fixed bug #585975: 'There is no API reference'.
  • Fixed bug #531142: 'The UI namespace in views is unnecessary'.
  • Fixed bug #687714: 'Give a nice error when static linking won't work'.
  • Fixed bug #635122: 'Rename helper to web_helper and extract from class'.
  • Fixed bug #691798: 'Add a way to run the unit test without installing'.
  • Fixed bug #687708: 'Make it work with python 2.6 and 2.7'..
  • Fixed bug #687715: 'Make it work with 32bit fedora LDC'.
  • Fixed bug #633586: 'Make dynamic or static linking configurable'.
  • Fixed bug #660290: 'Creating scaffolding with references does not work'.
  • Fixed bug #598630: 'In dev and test modes symlink public folder instead of copying'.
  • Fixed bug #653419: 'Add a way to run unit tests'..
  • Fixed bug #652783: 'Add model find conditions'.
  • Fixed bug #635131: 'Building script regression rebuilds everything'.
  • Fixed bug #635161: 'Sessions ids are always unknown'.
  • Fixed bug #643251: 'Crud put and delete no longer work'.
  • Fixed bug #632083: 'Apps under fast cgi can't log or create files'.
  • Fixed bug #636098: 'The ubuntu package does not work on amd64'.
  • Fixed bug #598629: 'Make backtraces not show in release'.

Release 0.6 - September 6, 2010

This release is about making deployment simpler, and separating production and development configurations.

  • Fixed bug #600490: 'Make a fast cgi deploy script'.
  • Fixed bug #598628: 'make it so we can have development and production configs'.
  • Fixed bug #585977: 'The configuration is hard coded'.
  • Fixed bug #603021: 'If startup app build fails, rebuilding will always fail'.
  • Fixed bug #598613: 'Invalid route format gives an ugly error message'.
  • Fixed bug #612828: 'The ipc is too slow for large strings'.
  • Fixed bug #509771: 'There is no way to upload files'.
  • Fixed bug #613310: 'Connections fail with ab test'.
  • Fixed bug #603409: 'The ipc messages get truncated with binary data'.

Release 0.5 - June 28, 2010

This release was aimed at making app rebuilds automatic, and the framework easier to install. We are having new problems with the Ubuntu PPA. So just install using the package for now.

  • Fixed bug #591855: 'Compilation needs to be more strict'.
  • Fixed bug #589959: 'gen configure server header_max_size is ignored'.
  • Fixed bug #589820: 'Change configuration files to json'.
  • Fixed bug #584748: 'Move from Tornado to Dornado'.
  • Fixed bug #584807: 'Regex makes startup and requests extremely slow'.
  • Fixed bug #594439: 'escape_value and unescape_value are slow'.
  • Fixed bug #585528: 'Move the server and app to separate processes'.
  • Fixed bug #597053: 'Failed builds should show in the browser'.
  • Fixed bug #590977: 'Server is always old version RootinTootin_0.1'.
  • Fixed bug #597049: '404 pages do not show in Chrome'.
  • Fixed bug #586631: 'Rebuilding is too slow'.
  • Fixed bug #598700: 'The server needs to show unhandled exceptions'.
  • Fixed bug #598609: 'Large responses break the server'.
  • Fixed bug #598615: 'Application console output should show on the server'.
  • Fixed bug #584744: 'ppa does not work on ubuntu 10.04'.

Update - May 20, 2010

We are having issues with the PPA on Ubuntu Lucid 10.04. Please install from Trunk for now.

Release 0.4 - March 02, 2010

  • Fixed bug #511025: 'Controller template uses wrong view on create fail'.
  • Fixed bug #509711: 'Decimal datatype has zero precision'.
  • Fixed bug #509707: 'Decimal database type mapped to D double'.
  • Fixed bug #514143: 'Annoying obsolete FIXME in the routes'.
  • Fixed bug #513483: 'routes use zero-or-more instead of one-or-more'.
  • Fixed bug #510452: 'Requests for files do not show in server output'.
  • Fixed bug #510450: 'The unknown controller 404 page uses the wrong content type'.
  • Fixed bug #511027: 'Validation is missing in generated crud'.
  • Fixed bug #510488: 'html is dropped on create and update'.

Release 0.3 - January 19, 2010

  • Actions can be rendered in html, json, or xml.
  • Routes are more RESTful and use regular expressions.
  • Models can be converted to json and xml via their to_json & to_xml methods.
  • Views can use the link_to function to render links.
  • The './gen create scaffolding' now gives model fields default values, instead of null.
  • The './gen create scaffolding' now gives each field a proper html control, instead of a textbox.
  • The './gen create scaffolding' now only allows valid field types.
  • The server now rebuilds only when files under the app dir change, instead of any file changing.
  • Templates now use <%= for print with escape, and <%# for just print.
  • The web server now returns 'building ...' while compiling.
  • The'./gen recreate database' command recreates a database.
  • Fixed bug #503179: 'DB data is not formatted correctly when rendered'.
  • Fixed bug #502003: 'Not providing an argument for show crashes the server'.
  • Fixed bug #503190: 'Having the same plural and singular word for a noun fails'.
  • Fixed bug #503981: 'CRUD UI with no data is confusing'.

Release 0.2 - December 31, 2009

  • Moved from GPLv2 to GPLv3
  • Added a blacklist of words to be disallowed by the gen script.
  • Moved to a Python Tornado and D based server for speed and concurrency.
  • Updated the server so it automatically rebuilds when files change.
  • Replaced the ./build and ./run scripts with just ./run.
  • Model.find_by_id returns null on nothing found, while Model.find throws.
  • Added proper copyright/license headers to each file.
  • Changed the framework to use string as an alias for char[].
  • Changed most imports to be private.
  • Fixed broken sessions.
  • Added flash notice support.
  • Made the download of arbitrary files work.
  • Added a basic mime type map, for downloaded files.
  • Moved scaffolding js and css to their own files.
  • Added proper page titles.
  • Added a default page that lists controllers.
  • Added an unknown action page.
  • Fixed bug #501459: 'Dangling slashes in urls break routes'.
  • Fixed bug #500882: 'mysql connection error on new project'.

Update - December 18, 2009

The Ubuntu PPA issues have been resolved. Rootin Tootin should now work on i386, amd64, and lpia CPUs. Packages for Fedora and OpenSUSE are still being investigated.

Update - December 16, 2009

The first release (0.1) is out. If you are on ubuntu, you may have issues with the LDC PPA. Since it is a daily PPA, it tends to break every once in a while. I am working on fixing it by moving one of the working packages into our PPA.

Development happens over at launchpad:

  • Launchpad Homepage
  • Code Repository
  • Bug Reports
  • Mailing List

If you have any problems, you can contact Matt Jones at: mattjones@rootin.toot.in

Let's create a simple journal application. Make sure you have installed the framework, and are running a Linux based OS.
  1. Create a new Rootin Tootin project. It will be named "journal", run on port 3000, and use the mysql user "root" with the password "letmein".
    rootintootin name:journal port:3000 db_user:root db_password:letmein
  2. The rootintootin command created a directory named "journal" that contains the complete app. Move into this folder.
    cd journal
  3. To create the mysql database, we will use the gen script. As with any scripts in Rootin Tootin, we will run them like "./gen". The "./" simply means to run the script in the local directory.
    ./gen recreate development database
  4. We will want to create a model and controller named "note". In order for the framework to know about the noun "note", we will tell it how to pluralize and singularize this noun. Singularize means one instance and pluralize means many instances.
    ./gen create noun singular:note plural:notes
  5. Now we will create a skeleton website or "scaffolding" for our journal. We will need a database model named notes with string fields title and content. This will also create our models, views, controllers, and migrations.
    ./gen create scaffold note title:string content:string
  6. Now we will run the migration that will create the tables that the models are mapped to.
    ./gen migrate development
  7. Now we will run the project. The run command will start the server on port 3000. The server will look at the project files and compile them automatically when they change.
    ./run
  8. Now visit the website in a web browser.
    http://localhost:3000/notes

The next release will be 0.9. See the roadmap for the release date and details.

Below are details on the current 0.8 release.

Status:

Rootin Tootin is alpha software, and not ready for production use. It is missing many key features, and has yet to be significantly tested for security, performance, and reliability. The API is extremely unstable. It is highly recommended that Rootin Tootin is not used on anything, until the 1.0 release. No known websites actually use Rootin Tootin.

Caveats:
  1. The only database that is supported is Mysql. In later releases, we should support Postgres and others.
  2. The documentation is non existent.
  3. There is no email support yet.
  4. There is no internationalization support yet.
  5. File uploading works, but the server puts the entire file in memory. This is used to parse the http multipart encoding that browsers uses when uploading.
License:

Rootin Tootin is licensed under the GNU General Public License version 3 (aka GPLV3). Because it is using the LDC compiler, libraries can only be statically linked. This means that software compiled with Rootin Tootin, will be considered a derivative work of Rootin Tootin, and therefore licensed under the GPLV3.

You can avoid having to use GPLV3 by three means: By distributing your software in a source code form, without being statically linked to Rootin Tootin; By only distributing the unlinked object files; Or by not distributing the binary, and having it run as a server.

Patches and Copyright Assignment:

The Rootin Tootin project does not require copyright assignment. This means that you own any contributions you make. All patches are required to be submitted as Bazaar branches. This way, your contributions are documented in the Bazaar repository.

System Requirements

  1. Mysql Server
  2. Mysql Client
  3. Mysql Client Library
  4. Python 2.6 or 2.7
  5. Python Mysql
  6. Python Pexpect
  7. Python Mako
  8. GCC
  9. Make
  10. LDC (LLVM D Compiler)
  11. Tango Library for D
  12. PCRE (perl compatible regular expressions)
  13. Lib FastCGI
  14. Inotify Tools

Operating System Support:

Rootin Tootin uses the LDC compiler (LLVM D Compiler), and Tango library. The only Operating Systems with packages for LDC and Tango are Debian, Ubuntu, and Fedora. In the future I hope to see LDC and Tango on major Linux, BSD, and even Windows Operating Systems.

Copyright © 2008 - 2012 Matthew Brennan Jones
Rootin Tootin is licensed under The GNU General Public License v3.0.
This website and all documentation is licensed under The Creative Commons Attribution License v3.0.