Wednesday, June 2, 2010

Status

Because some projects are keeping me busy, my publishing activity is pretty mutch reduced to Twitter (just look to the right).
One ongoing project is (as always) revolutionizing the internet.
I have used many web applications, read a lot of interesting articles, listened to podcasts, watched keynotes and even skimmed through some books, and came to the conclusion, that the perfect media for my messages have not been developed yet - so I am working on that right now.
If you are a Java (including JRuby and/or Scala) Web Developer or a (JavaScript/CSS) UX Designer looking for a 50/50 Partnership, please contact me for more details! Of course 50/50 is just a euphemism for "No salary!".
That's why my other work is writing applications for an additional job to some nice web development agencies in Hamburg.
And last but not least, Lumbergh started being active again and I am writing a lot of new lyrics recently.
It is always interesting to see the tides of creativity coming and going.
Hopefully I will soon be back with more info on the big Project X.
Until then visit me on Twitter!

Wednesday, April 7, 2010

About Productivity

I need to get better in deciding when to adopt a new tool to improve my workflow, and when to stick with what I have.
Yesterday I spent lots of time figuring out how to integrate Google Tasks into my Linux desktop, just to give up in the end, because all results were worse than iGoogle, which I had already used.
In the process I also asked myself if it is really a good Idea to minimize tool providers, or if one should rather use different tools by different companies, even if that means more accounts and certainly higher syncing efforts.
In every case, Google is not always the way to go, even if it sometimes appears like it.
As soon as Evolution syncs tasks with Ubuntu One, I will probably use it via Tasque with Tomboy Notes or via Getting Things GNOME.

Tuesday, March 23, 2010

Scala, Maven and some Frameworks on Google App Engine

As soon as you want to use more libraries than Google App Engine provides, things are getting a lot more complicated. So I decided to share my learned lessons and maybe help saving some time for others. There may be some unmentioned updates over time. I will also write more about the client side soon.

To configure my own building process I chose Maven. Figuring out how to use it with Eclipse was tiresome, so I switched to IntelliJ Idea and have not regretted it since, even though it meant abandoning the GAE plugin.
Maven, Scala and JavaScript (and therefor jQuery) integration are helpful. For Scala you need to install the extra plugin.

Frameworks and Maven Plugins

For my purposes I need a decent programming language, a RESTful framework and a simple templating engine. After reviewing some alternatives I decided to use Scala with Restlet, some Lift helpers and Simple Xml since I could never get Xstream running properly on GAE.

Restlet's Resources offer a nice alternative to HttpServlets, making it easier to render different representations for different requests.

Lift offers a really nice bind-method that helped me quickly creating my own xml templating tags. This way, templates can be designed with real world content rather than cryptic placeholders.

Finally the Maven Gae Plugin provides some App Engine specific goals. If you start them out of Idea you can shorten build times by switching off online mode and testing.

Repositories

Up until now, there is no official Google Maven repository, so I used this one instead:

http://maven-gae-plugin.googlecode.com/svn/repository

It so far has been updated instantly after new releases.


There is one now.

The pom.xml

It took me a while to figure this out, and other blog posts containing Maven customizations have been a big help. There is still room for improvements. I appreciate all comments and questions.


<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <!-- The Basics -->
    <groupId>com.beecourt</groupId>
    <artifactId>site</artifactId>
    <version>1.0</version>
    <packaging>war</packaging>                          

    <properties>
        <gae.version>1.3.3.1</gae.version>
        <project_charset>UTF-8</project_charset>

        <!-- customized -->
        <restlet.version>2.0-RC3</restlet.version>
        <scala.version>2.7.7</scala.version>
        <gae.port>8080</gae.port>
        <gae-plugin.version>0.5.8-SNAPSHOT</gae-plugin.version>
    </properties>

    <dependencies>
        <!--unit test related dependencies-->
        <dependency>
            <groupId>com.google.appengine</groupId>
            <artifactId>appengine-api-1.0-labs</artifactId>
            <version>${gae.version}</version>
            <!--<scope>test</scope>-->
        </dependency>
        <dependency>
            <groupId>com.google.appengine</groupId>
            <artifactId>appengine-api-1.0-stubs</artifactId>
            <version>${gae.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.google.appengine</groupId>
            <artifactId>appengine-api-1.0-runtime</artifactId>
            <version>${gae.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.google.appengine</groupId>
            <artifactId>appengine-tools-sdk</artifactId>
            <version>${gae.version}</version>
            <scope>test</scope>
        </dependency>
        <!--servlet api -->
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.4</version>
            <scope>provided</scope>
        </dependency>
        <!--app engine related dependencies-->
        <dependency>
            <groupId>com.google.appengine</groupId>
            <artifactId>appengine-api-1.0-sdk</artifactId>
            <version>${gae.version}</version>
        </dependency>
        <dependency>
            <groupId>com.google.appengine.orm</groupId>
            <artifactId>datanucleus-appengine</artifactId>
            <version>1.0.6.final</version>
        </dependency>
        <dependency>
            <groupId>org.apache.geronimo.specs</groupId>
            <artifactId>geronimo-jta_1.1_spec</artifactId>
            <version>1.1.1</version>
        </dependency>
        <dependency>
            <groupId>javax.jdo</groupId>
            <artifactId>jdo2-api</artifactId>
            <version>2.3-ec</version>
        </dependency>
        <dependency>
            <groupId>org.datanucleus</groupId>
            <artifactId>datanucleus-core</artifactId>
            <version>1.1.5</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.datanucleus</groupId>
            <artifactId>datanucleus-jpa</artifactId>
            <version>1.1.5</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>asm</groupId>
            <artifactId>asm</artifactId>
            <version>3.2</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.geronimo.specs</groupId>
            <artifactId>geronimo-jpa_3.0_spec</artifactId>
            <version>1.1.1</version>
        </dependency>
        <!-- customized -->
        <dependency>
            <groupId>net.liftweb</groupId>
            <artifactId>lift-util</artifactId>
            <version>1.1-M8</version>
        </dependency>
        <dependency>
            <groupId>org.restlet.gae</groupId>
            <artifactId>org.restlet</artifactId>
            <version>${restlet.version}</version>
        </dependency>
        <dependency>
            <groupId>org.restlet.gae</groupId>
            <artifactId>org.restlet.ext.servlet</artifactId>
            <version>${restlet.version}</version>
        </dependency>
        <!-- file upload -->
        <dependency>
            <groupId>org.restlet</groupId>
            <artifactId>org.restlet.ext.fileupload</artifactId>
            <version>2.0-M3</version>
        </dependency>
        <dependency>
            <groupId>com.noelios.restlet</groupId>
            <artifactId>restlet</artifactId>
            <version>1.0.5</version>
        </dependency>
        <dependency>
            <groupId>commons-fileupload</groupId>
            <artifactId>commons-fileupload</artifactId>
            <version>1.2.1</version>
        </dependency>
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>1.4</version>
        </dependency>

        <!-- testing -->
        <dependency>
            <groupId>org.scala-tools.testing</groupId>
            <artifactId>specs</artifactId>
            <version>1.6.2.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.7</version>
        </dependency>
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>1.2.16</version>
        </dependency>
    </dependencies>

    <!-- Build Settings -->
    <build>
        <finalName>skeleton</finalName>
        <sourceDirectory>src/main</sourceDirectory>
        <testSourceDirectory>src/test</testSourceDirectory>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
            </resource>
            <resource>
                <directory>src/main/java</directory>
                <includes>
                    <include>**/*.xml</include>
                </includes>
            </resource>
        </resources>
        <testResources>
            <testResource>
                <directory>src/test/resources</directory>
            </testResource>
            <testResource>
                <directory>src/test/java</directory>
                <includes>
                    <include>**/*.xml</include>
                </includes>
            </testResource>
            <testResource>
                <directory>src/test/scala</directory>
                <includes>
                    <include>**/*.xml</include>
                </includes>
            </testResource>
        </testResources>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>1.5</source>
                    <target>1.5</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>net.kindleit</groupId>
                <artifactId>maven-gae-plugin</artifactId>
                <version>${gae-plugin.version}</version>
                <configuration>
                    <port>8080</port>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.scala-tools</groupId>
                <artifactId>maven-scala-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>compile</goal>
                            <goal>testCompile</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <scalaVersion>${scala.version}</scalaVersion>
                    <args>
                        <arg>-target:jvm-1.5</arg>
                    </args>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.datanucleus</groupId>
                <artifactId>maven-datanucleus-plugin</artifactId>
                <version>1.1.4</version>
                <configuration>
                    <!--
                        Make sure this path contains your persistent
                        classes!
                    -->
                    <mappingIncludes>**/model/*.class</mappingIncludes>
                    <log4jConfiguration>${basedir}/src/main/resources/log4j.properties</log4jConfiguration>
                    <verbose>true</verbose>
                    <enhancerName>ASM</enhancerName>
                    <api>JDO</api>
                </configuration>
                <executions>
                    <execution>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>enhance</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>org.datanucleus</groupId>
                        <artifactId>datanucleus-core</artifactId>
                        <version>1.1.5</version>
                        <exclusions>
                            <exclusion>
                                <groupId>javax.transaction</groupId>
                                <artifactId>transaction-api</artifactId>
                            </exclusion>
                        </exclusions>
                    </dependency>
                    <dependency>
                        <groupId>org.datanucleus</groupId>
                        <artifactId>datanucleus-rdbms</artifactId>
                        <version>1.1.6</version>
                    </dependency>
                    <dependency>
                        <groupId>org.datanucleus</groupId>
                        <artifactId>datanucleus-enhancer</artifactId>
                        <version>1.1.4</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>
    <repositories>
        <repository>
            <id>mvnsearch</id>
            <url>http://www.mvnsearch.org/maven2</url>
        </repository>
        <repository>
            <id>datanucleus</id>
            <url>http://www.datanucleus.org/downloads/maven2</url>
        </repository>
        <repository>
            <id>gae-plugin</id>
            <url>http://maven-gae-plugin.googlecode.com/svn/repository</url>
        </repository>
        <repository>
            <id>maven-restlet</id>
            <name>Public online Restlet repository</name>
            <url>http://maven.restlet.org</url>
        </repository>
        <repository>
            <id>scala</id>
            <url>http://scala-tools.org/repo-releases</url>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>datanucleus</id>
            <url>http://www.datanucleus.org/downloads/maven2</url>
        </pluginRepository>
        <pluginRepository>
            <id>gae-plugin</id>
            <url>http://maven-gae-plugin.googlecode.com/svn/repository</url>
        </pluginRepository>
        <pluginRepository>
            <id>mvnsearch</id>
            <url>http://www.mvnsearch.org/maven2</url>
        </pluginRepository>
    </pluginRepositories>
</project>

Sunday, March 7, 2010

TED

There are some new TED talks from the February conference in Long Beach online now. These are two I have particularly enjoyed:
The first one
by Daniel Kahnemann does concern the pursuit and experience of happiness, the second one is by Bill Gates and about pushing research of new energy sources.

Wednesday, February 10, 2010

Programming and Typing

There is a lot of stuff going on.

My most prominent employer offered me the task to develop a web application to manage Power Point Presentations, or more precisely, their contents.
Of course I accepted and now have a lot of stuff at my hands.

One lesson learned: I should have started with sketching use cases, or at least paralleling sketching use cases with technology research.
Instead I have jumped right into programming mode and am now paying the price in form of stress.

To reduce this stress a little, I have decided once again to learn typing with my eyes focused on the screen. This tool has proven helpful and motivating so far. It keeps very informative stats. First thing I did was switching off the keyboard view.

Saturday, February 6, 2010

Hilarious

I am back for at least a moment to share this gem of internet culture.

Also I have (of course) changed pretty much my whole tool base for web application design again, including my preferred language to write about it. Just in case you did not notice.

I will write about that and a little about my first real business app under construction soon.

I also wanted to share these two accounts of mine, where I collect links and thoughts/answers/questions about programming:

One is at Diigo (probably posted that one a while ago, but still think it is a nice tool), and the other one is at stackoverflow, which evolved to a kind of first address for programming issues.

Also I have decided not to open links in new tabs anymore. Just use the middle mouse button or some other way of choice, if you want to stick around.

Monday, November 2, 2009

Dinge mit P

Als Freund der Fernesehserie "The Big Bang Theory" sah ich mich gezwungen, der Subkultur der "Graphic Novels" auf den Grund zu gehen, und wurde bisher nicht enttäuscht.
Das Internet verriet mir die Adresse eines schönen Comicladens, wo ich mir auf Empfehlung des Verkäufers "Preacher" von Garth Ennis und Steve Dillon anschaffte.
Der Comic hat eher Fantasy als Science-Fiction Elemente.
Grob zusammengefasst geht es um einen saucoolen Priester, der einer hypnotischen Stimme bewaffnet nach Gott sucht, welcher sich laut Aussage eines Engels irgendwo in Texas vor seiner Verantwortung als Universalregent versteckt.

Außerdem hatte ich mich vor langer Zeit einmal um einen (beta-)Testaccount für das ungarische Roboterkampf-MMORPG Perpetuum beworben. Heute habe ich unverhofft eine Zusage erhalten.
Der Client ist bereits installiert, läuft allerdings etwas ruckelig auf meinem zugegebenerweise lahmen System.
Bisher weist das Spiel große Ähnlichkeit mit Eve Online auf, auch wenn man sich lediglich in zwei Dimensionen (auf der Oberfläche eines Planeten) bewegt.
Bewertend kann ich noch nichts sagen.
Falls ich die Zeit für ein längeres Einarbeiten finde, lege ich natürlich nach. Ansonsten sollte man die ersten Reviews bereits anderswo finden.