Monday, September 29, 2008

Facebook and GoogleAppsEngine

Because Facebook has so many users it's an extremely interesting place.

Personally I think it was even more interesting a year ago - because at that time third pary apps seemed to be virally working their way through the book with incredible speed... however, in the last year, partly because of Facebook API changes and partly because of Facebook users growing up (there are only so many people who want to play vampires vs pirates!) then the viral spread of apps has decreased.

One of the nice things about GoogleAppsEngine is that it makes it easier to write scaleable applications - hence easier to write applications that might satisfy the Facebook member's needs.

Looking around, a few facebook developers have spotted this - and they've posted some helpful material on:
http://dollarmani-facebook.blogspot.com/2008/09/facebook-applications.html
http://wiki.developers.facebook.com/index.php/Python

And they've formed a group at:
http://groups.google.com/group/facebook-and-google-app-engine

Some charting investigations

Whatever I do next it's likely to involve some data analysis - mainly cos I'm a bit in love with stats...

On the .NET side there seem to be a few open source libraries available, one of which is called Zedgraph - I had a look at this - and have to see it looks quite powerful - especially for producing nice looking charts very quickly from server side data (or client side if you build it into an app).

http://www.codeproject.com/KB/graphics/zedgraph.aspx
http://zedgraph.org/wiki/index.php?title=Multi-Pie_Chart_Demo

On the webside.... I quickly came across Google Visualisations - which quite frankly look stunning... to see them in use take a look at google's finance site - http://www.google.co.uk/finance

So far I think Google's winning...

Wednesday, September 24, 2008

Microsoft vs Google

I've been considering which of two platforms to experiment with for my next project.

On the Microsoft front there's some .NET code I quite like the look of - Visual WebGui - http://www.visualwebgui.com/ - it build on lots of Microsoft stuff I already know, it produces very cool looking AJAX applications very quickly, it hides lots of nasty javascript and D/XHTML complexities from you...

And on the Google front there's the Google App Engine - http://code.google.com/appengine/ - and there's a whole load more besides (they have more APIs available every day...). This is still quite new, it's only available using Python which I haven't used for a couple of years and if you want to develop websites then you'll get to get your hands dirty with text editors and simple code.

Here's some background I've done so far...

Visual WebGui - http://www.visualwebgui.com/
The download and install went super quick and I got my first app up and running in no time - real impressive - easy to create a form, add a treeview, add a splitter, add some more UI elements, hook up some events in C# - then hit F5 and it just worked - no problems. Lovely.

Then I took a look through some of the samples (code snippets) at http://www.visualwebgui.com/Community/Resources/Codes/tabid/326/Default.aspx - all seemed to work OK, although a few relatively simple tasks did take ages - e.g. I couldn't add my own user control - eventually I discovered this was down to needing to add my Control to the <controls> list in the web.config file....

<controls>
<control type="WebGUIApplication1.MyScripts, WebGUIApplication1">
<control type="WebGUIApplication1.CustomControl1, WebGUIApplication1"/>
</controls>

I then played around some more of the code snippets - especially the Google Maps integration - trying to copy this one to do my own thing proved nasty - there just seemed to be magic instructions to follow everywhere - things like that <controls> list and things like the javascript and image files needing to be marked as Embedded Resources (and even then they often did not seem to get included...

Overall, my impressions were:
  • If you want to use the toolkit as is to build an explorer-like UI in a web page, then this is a superb toolkit - it makes visually very impressive apps very quickly.
  • You may, however, discover lots of nuances and quirks if you start doing more advanced things - such as adding your own controls... and often these are very frustrating to solve.
Google Apps Engine - http://code.google.com/appengine/
This is part of Google's answer to Amazon's server services - it's basically a hosting service for web applications which lets you host applications on Google's hardware. What this could mean for a developer is huge - it could mean access to an incredibly robust, incredibly scalable hosting environment.

The download and install of this went pretty quick and easy - first installing Python 2.5 (I already had 2.3 and 2.4 installed so now just adding another to the installed list...), then installing the SDK from http://code.google.com/appengine/downloads.html.

Having got this working I then (for once) actually just followed the quick start instructions - and was quite impressed that most things just worked straight off - http://code.google.com/appengine/docs/gettingstarted/ - in fact, the only problem I had was when I tried to add another page (beyond the instructions) just for fun... and I couldn't work out why my new code wouldn't work... it eventually turned out I'd copied the code inside a post rather than inside a get... simple error but really hard to debug...

Which led me to start looking at Eclipse - http://www.eclipse.org - and at the pydev integration - http://code.google.com/appengine/articles/eclipse.html (actually I didn't follow this document - but rather the IBM version - http://www.ibm.com/developerworks/opensource/library/os-eclipse-mashup-google-pt1/

This integration (after some time spent tweaking) gave me debugging capabilities - they weren't quick - but at least I could set breakpoints, could watch values and could step through code.

Finally I spent some time looking at some of the projects other people have already done on this platform, especially:
  • the sample app code site - http://code.google.com/p/google-app-engine-samples/ - this showed a few cute samples with remarkably few lines of code...
  • the open source community - especially looking through these samples - http://groups.google.com/group/google-appengine/web/google-app-engine-open-source-projects - reading through the code of a couple of these apps certainly helped me understand how somw things work... For example, cpedialog is a simple but nice looking blog engine - http://code.google.com/p/cpedialog/wiki/How_To_Install_cpedialog

Back from the death!

This blog died the death that many blogs die... It wasn't quite as bad as it might look to a casual observer - it didn't actually die after just one post - but it did suffer from an extreme lack of attention.

Let's try again...

This time round this blog's here for one big purpose - it's here to talk about lots of hobby software development I'm spending time on.