Quite some time ago, I posted about my Adventures in Objective-C, postulating that people would be willing to rapidly develop in a static-typed language if the language was easy to deal with. I created the foundation of a web framework that didn't do too much, but was functional enough to prove that it was possible. I also gave up shortly after, as I found development on Windows and Linux to be a gigantic pain -- too few libraries, not much support.
Some of the same ideals I was going for in that previous post still hold true. Java still clicks in a weird way for me, even if it's too verbose and runs in a VM and 90% of the web frameworks for it annoy me to death. Objective-C was cute, but mostly useless for me. I don't mind the idea of C#, except for the fact that it's Windows-centric, and I'm still uncomfortable putting my eggs in the Mono basket.
In the meantime, I stumbled across a language called Vala. Vala's roots are in the GNOME community, where they have a couple of great C libraries: GLib, and included in that, GObject. Using this standard library, C-based GNOME applications have had a lot of the great benefits of object oriented programming while maintaining the speed and support of the C language. Unfortunately, you got everything else that C provides: no memory management, no namespaces, and difficulty in reading it later.
I'm going to get flamed for that.
Nevertheless, other people saw some of those same things. They also saw some Mono applications creeping into the GNOME core, and felt that all the pieces were there to do something better. Vala was born as a true object oriented programming language, with a very similar design to C#. The difference is, it relies on GLib and GObject to accomplish the OO goals, and therefore, compiles into C, which is then compiled by gcc. As a result, you get significantly smaller and faster binaries than VM-hosted languages, with very minimal pain. Furthermore, you don't need to use GTK or anything like that, it's still a general purpose language that can be hosted on any platform that can compile GLib. That means I can code on OS X and Linux, and, while I haven't done it in a while, Windows can join the party as well.
You see where this is going.
In the end, I took my ideas for a reasonable web framework, and started porting them to Vala. Months ago, I had a proof of concept similar to the ObjC example in my previous post. But, I kept working on it. Routing, templates, plugins, configuration, build systems, all managed to find their way in. Then, the nice things. Session, Authorization, and Form frameworks are a part of it. I've started on a fairly simple ORM, as well, Almanna. The result is, well, this.
This blog is the first production test of the framework. I ported the blog software from Catalyst to Ambition, launched it here on the existing database, and I'm going to see all the places it fails. It will likely do a lot of failing, but it's a decent first effort. After a little stress testing, I'll open this up on GitHub, and see where else it can go.
2012-07-18 at 15:49:21
I will be presenting the Ambition MVC Framework at TCCC15. Twin Cities Code Camp is a free event that occurs twice a year at the University of Minnesota in Minneapolis, MN, and it caters to novice to advanced developers using multiple languages and devices. TCCC15 will be held on October 19th, 2013, starting at 8:00am, and you can register here.
The synopsis of my talk:
There are tons of great MVC web frameworks out in the wild, for most major compiled and dynamic languages. They're great tools to get projects prototyped and quickly into production. The Ambition MVC framework is a hobby that turned into a reasonable web framework. Written using Vala, the Ambition framework allows a developer or team of developers to create web applications or RESTful services using a static-typed object oriented language without relying on a VM or a garbage collection cycle. Plus, being compiled, it allows cloud deployment to be easy and inexpensive, as memory and CPU requirements can be a fraction of PHP, Ruby, Python, or Perl sites. While it's not "officially" released, it's available on GitHub, and being actively developed. Patches, help, and end users are very welcome, and I'd like to show you more.
2013-10-08 at 18:49:28
I'm pleased to announce that there is a reasonable Couchbase library coming along for Vala, and it is semi-functional at this point. Sure, an announcement seems weird at "semi-functional", but considering the absence of a library up to this point, I'm calling it good.
Introducing GCouchbase (github/web).
GCouchbase is a combination of a fully functional vapi wrapper around the C libcouchbase library and a pleasant GObject layer on top of it. The libcouchbase functionality is available to the end user via GCouchbase or on its own, but GCouchbase makes the library work more like how one would expect out of a higher level language. The structure is loosely based off of the .NET library, but does not rely on libmemcached or any other proxy layer.
For those who may not be aware of what Couchbase is, it is (in my humble opinion) NoSQL done right. While similar in functionality to other offerings like MongoDB or CouchDB, Couchbase combines a persistence layer with a memory layer to provide fast, scalable JSON blob storage and retrieval that scales evenly with memory and CPU. In other words, you don't need to have a cache layer, a data layer, and a replication layer, Couchbase handles it for you. The built in view functionality is powerful, but can directly connect to an ElasticSearch instance for advanced queries.
It's very neat, and blends in nicely with the speed of Vala.
2014-01-01 at 22:46:31
It's getting pretty easy to see that I should start finishing some entries for this blog if it's going to be at all relevant or useful, but I'll take a moment to introduce another "thing".
This past weekend, while working on a web project in Ambition, I started wishing I could control logging in a better way than what was already provided. Specifically, I wanted to be able to amp up logging in one controller while keeping another one quiet. In a horrific turn of events, I found myself longing for something like log4j/log4perl/log4net so I could use a configuration file to handle that.
A few days go by, and here we are.
Introducing Log4Vala, available on GitHub. Available as a shared library to integrate into your Vala application or library, Log4Vala provides most of the core concepts available in the other logging frameworks, without a lot of overhead. Yes, there are still a few method calls for each logging pass, but it's quiet a bit tighter than a VM environment. I'm pretty happy with the result.
2014-06-19 at 18:07:37