Friday, June 27, 2008

Reading up on Groovy and Grails

The good thing about Groovy is its likeness to Java, and reading Groovy code should pose no difficulty to a seasoned Java programmer who's taken a days worth reading. The problem with Groovy is writing good code. Not because you do it wrong, but you can always write it better! As with Ruby, there are alot of nifty features in the language that shortcuts ugly code in Java. But, you have to know that these features exists before you can use them. Grails? It just might become the next dogma in Java application development!

This is the litterature list and resources I've used in my pursuit of becoming a Groovier developer:

Wednesday, June 25, 2008

The joys of Sun Spotting

I've had one joyful day of tinkering with a SUN SPOT developer kit, courtesy of javaBin

  • My first impression is WAY COOL.

Monday, June 23, 2008

Java Sorting Box for dynamically invoking receptors

System color is not a requirement.The system I want to create must invoke the receptor's call(x) with the objects from the pile that correspond the receptors interface.

I have a pile of objects of the classes; PinkTriangle, GreenSylinder and RedSquare, implementing Interfaces Triangle, Square and Circle, and a set of receptors; TriangleHole, SquareHole og SircleHole, who's call(x) functions accept Triangle, Square or Circle interfaces (or children).

Wednesday, June 18, 2008

Vizualizing metadata with Google maps

Google mapsI'm amazed by the imagery you get on google maps with terrain, images and wikipediaarticles.

I see a hammer I want to use, now to find some nails.

Lets say you work for a news publicist who wants to leverage their articles metadata quality to make navigation and search easier for their customers and researchers and writers.

Tagging with metadata requires that the metadata is applied correctly and in a standardized fashion. Vizualizing the metadata can make the categorization easier and be an incentive for revisiting already tagged metadata and improving it.

Sunday, June 15, 2008

Miss detective

AUser story: Find anonymized celebrity

Norwegian media have a nasty habit of "half-telling" stories of people in focus of the police or are on the media shitlist. Finding these people should initially be hard, but by gathering the pieces of information, one can often easily find out who that person is. Often weblogs tell what the media "anonymize" or aren't allowed to, and may draw their own conclusions. Like a miss detective, the application will help a curious person of finding out who the victim of media hatred is :)

Exibit A: Lommemannen

The "pocket man" is someone notorious for asking small boys to "find out what's in his pockets".

Lazy loading from a Topic Map


  1. Load topics from my.xtm

  2. Car.list()

  3. [car1, car2].isAlsoA(Boat.class) - Which of these cars are also a boat. Or by using another context query


Why dynamic - Later ask for things that is only known to the TM. Define the relations statically by Interface, when needed.

Objects contain no state/reference to other objects. The TM has this information, and it depends on context.

Define which domain class are to be decorated. Some functions like list are generic, while owthers such as car.isAlso(Boat.class) have to be known how to build by query API

Creating the next big idea

Note to self:

  • Good Ideas are the ones that are simple to understand and take little time to implement

  • The more complexity in the idea, the more it will cost and risk increases

  • Stop when you've created a minimalistic prototype. Work should then be used on documenting it. What you have made now is most likely the most valuable part

  • Before you start implementing, make sure that the prioritized task is the one which gives the most value

  • Tasks should never be longer than 'til the end of the day. You will feel more satisfied and vigorous if you accomplished the task and can walk away from it with a clean concious, rather than beeing irritated of the work you still have to do, which you can't start on for another week

  • Keep expectations low and commitments few until confident in delivering. It might be a painful to walk away from a project which doesn't have the right of life

Saturday, June 14, 2008

Dissecting Grails for Maven building

Show me your war, and I will tell you how it does!

Upgrading a Java project from a legacy buildsystem to Maven involves lots of reverse engineering to understand how the application works. Starting to investigate a project by its deliverables is often the most easy, taking a working application and picking away piece by piece, like dissecting a frog, to see if it still works after some abuse and halfchanced guesswork.

I started by grails create-app'ing a simple book tutorial grails app, and grails war'ing it. The contents of the war were extracted into src/main/webapp of a maven demo project, supported by groovy-all, GMaven (Groovy Maven plugin) and Maven Jetty plugin.

Thursday, June 12, 2008

java.no as a student resource

java.no, maintained by javaBin, is a resource for a mature crowd of Java developers.

The majority of newbie Java developers, are students looking for tutorials, demoes and code samples to complete their 101 programming homework. Alas, like The Serverside and InfoQ, java.no alienates new Java developers. Todays agenda is architecting billion dollar enterprise systems, improving project agility or Business Intelligence. It is way past telling how to write hello world or make a robot play soccer, and I don't think the Java news resources ever have written how to.

Saturday, June 7, 2008

Tagger Tracker

Detailed: Community driven website for tracking tagers, where users can:

  • upload pictures of the artwork

  • upload surveillance footage

  • track time and place

  • comment on style, similarities and possible suspects.


Sentral to this application is a file. A file is a record of a sighting, containing time, positioning sightings on a street map, footage of incident, linking to other files or a suspects portafoilo and comments. The suspects gather a portafolio of files.

It is important that the site offers anonymizing the information, such that the incriminating details can be uploaded, but is only accessible for people with the right credentials. The information also needs a rating system to say something about the propability and correctness of information, to increase the data quality. Such an application will need an active set of moderators to avoid negative publicity.

Data analysis: The application must facilitate finding similarities between files, and finding relations between sightings and the motivation, and profile of suspects.

This can help structuring information such as

  • places of interest and facilities often visited (home, work, school)

  • social events

  • drinking/drug habits


Implementation: Topic map to store and relate the gathered information. Simple data storage of pictures and video footage. Map integration with Google maps or similar. Simple forum or wiki to discuss the sightings. Tracker GUI to view the material based on suspects, elapsed time, put sightings into context events such as parties aso, location of maps, spot similarities between artwork.

Conclusion: Creating a Tagger Tracker should not face any implementation difficulties. Creating an active community of commiters should not pose a problem. The moral issue of playing neighbourhood vigilante is something to be aware of, but differs according to application and country. Such an project has the potential for great opensourceness, but most likely little flow of income.

Copyright of the author. Creative Commons license.