Sep 15, 2009

So silent

Hi to everybody again. It has been very silent here during this summer. All of my time has went to renovate an apartment but we finally got it into shape that we can live in it. My computer - the one that I actually use for programming & drawing - is still not unpacked but hopefully that happens soon. So if everything goes well I will start flooding this blog again with new pictures and silly comments about programming.

Aug 29, 2009

Maemo 5 & N900

This is so great! All the hard work and now it is public!

Jun 7, 2009


It has been fun to play with lift framework during evenings and really good way to get your thoughts away from work. There are many things that I like about it - especially the templating system is pretty neat.

The creator of lift (David Pollak) mentioned wicket as the inspiration of the lift's templating system so I thought that I should try it. Already with very short experience I can say that it is fun thing to code with and is valuable tool for any Java web developer.

*Wicked animal tried wicket

May 23, 2009

My name is Max

Here is Max. He is a mascot and is about one year old (I did the picture one evening around 1 year ago).

No Coding, No Fun

Too much work lately, really no time to do any coding&drawing during the afternoon.

Apr 30, 2009

Horrible Creature

Funny coincidence. Two guys from our team got their first baby pretty much at the same time. That's a good reason for a present! I think that the guys will get lot of clothes with those ordinary cute pictures. To do something a bit different I did a body with a picture of a horrible creature.

The print was done using silk print method using textile colours. Whoa, have to say that cutting the mask with knife from paper is always quite tedious task even when the picture is easy one :)

Apr 28, 2009

Chicken and Lift Community

A good reason to try the Lift framework is just the people in the community. They are really, really helpful and nice. I had a bit struggle with the Scala compiler + Lift and it got it solved really quickly with help of the people and the amazing Lift forum. Thanks!

Then something different. I think there is just too few pictures of chicken - that marvelous bird that feed me so many times.
Chicken and hungry guy

Apr 9, 2009

Project status

Whoa, lately it has been quite tough at work. When things get hard in your project you need a clear target. Keeping a funny creature happy is really good target.

I decided to draw a mascot for our team. This little fellow's mood changes depending how things are going. If things are going well all reports&status stuff has a small creature smiling, if not, it is crying madly. Who would want that to happen?

Mar 30, 2009

View's in Lift

I think Lift framework is really interesting and fun thing to play with. Here is my ultra short guide how to try out the framework's Views.

Views are classes that returns content as scala.xml.NodeSeq. Lift maps a browser request to view class and its method. For example /TestView/showme would be mapped to TestView view- class and to showme method. The method name in the request is actually not an actual method in the class - it is a name that is dispatched to the dispatch method of the view class. The method returns a method to handle the request. To make it possible for Lift to find your view classes you sould store them to your.package.view package.

Lets create a simple view that shows simple response in XML. First we need to create the View class. It should be put into your [Package name].view package. Lets call the class TestView:

package your.package.view

import net.liftweb.http.LiftView
import scala.xml.NodeSeq

class TestView extends LiftView {
def dispatch = {
case "testPath" = > provideTestPath _

def provideTestPath(): NodeSeq = <html><body>Test</body></html>
So the class extends the trait LiftView. It defines the method dispatch that maps the requests with real class methods. In our case we only have testPath that matps to provideTestPath method. That method then returns the NodeSeq.

Next we need to tell Lift that we have this View available and allow it to display it. This happens by modifying our SiteMap. Go to your bootstrap.liftweb package and open the Boot class. Then go to the part where the SiteMap is defined. Assuming that you are playing with the skeleton created by the maven archetypes you should modify it to this:

// Build SiteMap
val viewEntry = Menu(Loc("testView",
("TestView" :: Nil) -> true,
val entries = Menu(Loc("Home", List("index"), "Home")) :: viewEntry :: User.sitemap

What we have done here? Created a new Menu entry called "TestView". With the part "TestView"::Nil we tell to Lift that map /TestView/* to this link. We have now allowed that /TestView/testPath maps to our TestView class and then to the method inside it. If you don't add the link into the SiteMap then Lift prevents anybody to access the link. It only shows 404 error. This is way to ensure that you as a developer can control what parts should be accessed.

Thats it. Now just point to your server /TestView/testPath and you will see the results!

Mar 25, 2009


Scala's type system is a pretty nasty monster to tame. It really tried to bite me yesterday but after some sweat and tears I was able to handle it. Today it was behaving really nicely and let me snap a picture of it.

Mar 21, 2009

Match Me Scala

Pattern matching is fun in Scala. It is nothing new - just check Erlang, Ocaml etc. - but it is again one of those features that makes me like the S-language.

def funnyFunc(lst:List[Int]):Unit = lst match {
case List() => print("Nil")
case lstHead::lstTail => {
Example is a simple function that takes a list and prints its structure. It has two rules for pattern matching: empty list (List()) and non empty part lstHead::lstTail. The nice part is that the matching already split the list into two parts: head and tail.

In Scala we can fine tune the pattern matching. Lets assume that we are close to the evil matching monster that eats code that prints number 5 (don't ask me why). We can avoid this by just adding a new rule:

def funnyFunc2(lst:List[Int]):Unit = lst match {
case List() => print("Nil")
case 5::lstTail => {
println("Don't Eat Me::")
case lstHead::lstTail => {
would print: 1::2::3::4::Don't Eat Me::6::7::Nil

Mar 18, 2009

Crazy Meat Eating Rugby Rabbit!

What happens if you breed GWT and Google App Engine? Answer is naturally a crazy meat eating rugby rabbit! I think I need to explain this. I have been playing a bit with the Google app engine and GWT. Few evenings ago I decided that I could even try to do some really small application - just for fun. The result is not a rabbit but a small web app that can be used to plan SCRUM sprints.

Currently the app is very simple and still not that many lines of code. I will release something about it when I feel that it is ready for its first public appearing. Perhaps then I also tell more about the experience with both of those frameworks.

Naturally the rabbit wants to be there also!

Crazy Rugby Animal

Mar 12, 2009

Google App Engine

Creating a web app is nowadays easy. We have tons of good frameworks, good tools etc. and most of them are free. One thing that is also now emerging is that the infrastructure - servers, databases - are also free or very cheap. Just look at the Google App Engine. Its idea is pretty neat. You get Google's servers and infrastructure for free for your web services&applications. Only when it starts to attract more users you need to pay. Google itself is promising that the initial quota should be enough for around 5 million web page loads per month - pretty big.

What does it mean for developer? I had to give a try for it and it seamed to be really easy to get started. Currently coding is done with Python and the guys at Google are hinting that in future other environments will be also supported. Google provides own light weight framework which is easy to use. It however also supports pretty much any other Python based framework - you just need to use their database system. And why wouldn't you do that when you get their load balancing for free? Anyhow - you can get pretty far just by using the framework they provided. Documentation is also good. Too easy?

Google is doing lot to lower the barrier to enter web apps markets. With Google App Engine companies doesn't need to do any initial investments to the server infrastructure. They can pretty much try out if the service is going to fly until they need to pay. That has big impact on the risk and needed initial funding. I wouldn't be surprise if in near future there are tons of web apps running on Google's infrastructure.

Now back to coding...

Vroom, vroom engine

Mar 5, 2009

Lift me!

It has been a while when I last time played with web coding. After wondering a while - should I start to play more with Google App engine (which is really great stuff), Ruby or go and try some stuff from Java world I bumped into Lift. Lift is a Scala based web framework that promises to do thing differently (surprise, surprise). Because I have long wanted to really dig into Scala I knew that this would be my next playground. Lets see how different it really is...

Mar 3, 2009

Coding and Drawing

I wish I would have 16 fingers - coding with amazing speed!

Hello everyone and welcome to my blog. You have to start a blog with a post and usually it is the hardest one.  My intention is to mostly write about stuff related to coding and drawing. I can't however promise that some other topics wouldn't sneak into the blog also. To keep it short - welcome all and unleash your coding troll.

A troll with amazing coding skills...