Tuesday, July 31, 2012

I write a new app in a new stack

The time has seemingly come, as it occasionally does, for me to learn some new frameworks and/or languages and build a new app. I do this every once in a while when I'm completely bored by what I'm doing at work, and/or when I feel like I'm falling too far behind the cutting edge of the fast-paced world of web development. Basically, if I find myself thinking that I'm tired of programming, I slap myself and say, "Duh, you're not tired of programming; you're born to code! The problem is that you're stagnating. You need new horizons to explore." And it always turns out I'm right.

This time I think I want to write a game. That's nothing new; I usually write games for fun. But I need to learn something new. I've been doing a lot of JSF/Seam/ICEfaces at work, and I'm frankly quite sick of the stack (whether through some actual fault of the technologies, or simply from contempt bred of familiarity, I'm not sure). This stack is heavy and stateful, and tries to push all the client-side development out of Javascript and into server-side component libraries. The problems this approach can raise I am now very familiar with, so naturally my current grass-is-greener scenario involves a really stateless server and a lot more client development. Oh, and a lot of separation between server and client.

In fact, I'd love to completely divorce my client and server. Just to see if I can, I'd like to write one server component that is mostly centered around providing JSON services (maybe REST), using nothing but tests or possibly a command line as a client. Then I want to add in a web client, an Android client, and possibly even an iOS client and (if I get really crazy) a Windows and/or Mac desktop client. All these clients should be able to interact with the server the same way, meaning that you can play on the web against your friend who is playing on his Android.

This is ambitious, I know. But one advantage of this approach should be that if I lose steam halfway through that list of clients, I'll still have something to show for it.

I've started researching technologies. One I'm very interested in is Scala. I like many of the functional programming idioms, and I like the JDK, but I hate how slow Java the language is to add new features and keep itself relevant (still no closures?!). Developing in Java these days can be quite a chore when you've had a taste of the other languages that are available. Groovy was a possibility, but I've tried a large project in Ruby, and one thing it taught me is that I'm not a fan of dynamic typing. Scala is functional, concise, statically-typed, and gaining a lot of traction in the community. so Scala is a must for my server.

But the Scala web development world is confusing and new. The biggest players seem to be Lift and Play, but there are also smaller, purposefully lighter-weight projects called Scalatra and Unfiltered. I'll be researching these, taking notes here, and eventually choosing the one that seems to fit my needs.

I also like Javascript. For the web client, I want to use some of the amazing JS libraries that I'm aware of which have sprouted up in the years since I was really doing Javascript development. JQuery probably, and Angular or something like that. Batman, Cappuccino, etc. I know little about all of these, so a lot of research is in order. I don't yet understand what they all offer, so I'll be researching them and chronicling my findings here.

Some HTML5 research will probably be in order.

Android too. I'll have to take Android development back up at some point, and that will get some time here.

For now, that's all I'll promise. Stay tuned for the results!

No comments:

Post a Comment