<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6929830</id><updated>2011-10-12T23:31:48.480+02:00</updated><title type='text'>Metamorphic</title><subtitle type='html'>Of mice and men</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://gnejs.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>5</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6929830.post-112197997767302756</id><published>2005-07-21T22:52:00.000+02:00</published><updated>2005-07-21T23:06:17.676+02:00</updated><title type='text'>JBoss - Bad Vibes</title><content type='html'>JBoss Inc continues to destroy their own trademark.&lt;br /&gt;&lt;br /&gt;I guess Mr Fleury and Mr Burke got tired of bashing BEA and IBM and instead decided to go after one of the Open Source projects that is stealing some of the spotlight from the almighty 'JBoss Monolithic AppServer' &lt;i&gt;(insert compulsory reference to 'One ring to rule them all...' etc..)&lt;/i&gt; - Spring. &lt;br /&gt;&lt;br /&gt;I wonder if this is what's called "Professional Open Source"?&lt;br /&gt;&lt;br /&gt;Read Logemann's summary &lt;a href="http://www.logemann.org/blojsom/blog/default/2005/07/21/JBoss_Inc_continues_attacking_Spring_I21.html" title="JBoss Inc. continues attacking Spring/I21"&gt;here&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6929830-112197997767302756?l=gnejs.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://www.logemann.org/blojsom/blog/default/2005/07/21/JBoss_Inc_continues_attacking_Spring_I21.html' title='JBoss - Bad Vibes'/><link rel='replies' type='application/atom+xml' href='http://gnejs.blogspot.com/feeds/112197997767302756/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6929830&amp;postID=112197997767302756&amp;isPopup=true' title='262 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/112197997767302756'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/112197997767302756'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/2005/07/jboss-bad-vibes.html' title='JBoss - Bad Vibes'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author><thr:total>262</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6929830.post-112134547212488923</id><published>2005-07-14T14:42:00.000+02:00</published><updated>2005-07-15T20:00:56.820+02:00</updated><title type='text'>Default log4j configuration?</title><content type='html'>Something that really annoys me is how &lt;a href="http://jakarta.apache.org/log4j"&gt;log4j&lt;/a&gt; behaves when there's no "log4j.properties" or "log4j.xml" in the classpath.&lt;br /&gt;&lt;br /&gt;Instead of printing out my log statements to &lt;span style="font-style: italic;"&gt;System.out&lt;/span&gt; I simply get:&lt;br /&gt;&lt;pre&gt;log4j:WARN No appenders could be found for logger (com.foo.Bar).&lt;br /&gt;log4j:WARN Please initialize the log4j system properly.&lt;/pre&gt;Wouldn't it be nice if log4j could provide a default configuration instead?&lt;br /&gt;&lt;br /&gt;When discovering that there is no user-provided configuration, log4j would use a "fall-back" configuration instead (say, "default-log4j.properties" from the log4j.jar file). The content of such a file would be something really simple such as:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;log4j.rootLogger=DEBUG, Console&lt;br /&gt;log4j.appender.Console=org.apache.log4j.ConsoleAppender&lt;br /&gt;log4j.appender.Console.layout=org.apache.log4j.PatternLayout&lt;br /&gt;log4j.appender.Console.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Update: &lt;/span&gt;&lt;span style="font-style: italic;"&gt;There's a version 1.3 of log4j that's supposed to be released at some point. Does anyone know if this feature (or something similar) will be included in that release?&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6929830-112134547212488923?l=gnejs.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://gnejs.blogspot.com/feeds/112134547212488923/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6929830&amp;postID=112134547212488923&amp;isPopup=true' title='41 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/112134547212488923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/112134547212488923'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/2005/07/default-log4j-configuration.html' title='Default log4j configuration?'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author><thr:total>41</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6929830.post-108429289542405927</id><published>2004-05-11T18:15:00.000+02:00</published><updated>2004-05-11T18:29:01.063+02:00</updated><title type='text'>Working with Dates and stuff</title><content type='html'>Java is known for its lousy date handling classes java.util.Date and java.util.Calendar. Working with, comparing and displaying dates is, simply put, a bitch.&lt;br /&gt;&lt;br /&gt;A more manageable solution might be to store date information (in the database) using a plain &lt;i&gt;long&lt;/i&gt;, and use a decorator class to access this information:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;public class Time implements java.io.Serializable, Comparable {&lt;br /&gt;    private long internalTime = 0L;&lt;br /&gt;    public Time(long timestamp){&lt;br /&gt;        internalType = timestamp;&lt;br /&gt;    }&lt;br /&gt;    public long getValue(){&lt;br /&gt;        return internalType;&lt;br /&gt;    }&lt;br /&gt;    public static Time valueOf(java.util.Date date){&lt;br /&gt;        return new Time(date.getTime());&lt;br /&gt;    }&lt;br /&gt;    public java.util.Date toDate(){&lt;br /&gt;        return new java.util.Date(internalTime);&lt;br /&gt;    }&lt;br /&gt;    public int compareTo(Object another){&lt;br /&gt;        if(another instanceof Time){&lt;br /&gt;            return this.internalTime - ((Time)another).internalTime;&lt;br /&gt;        }&lt;br /&gt;        else { throw new ClassCastException(another+" is not an instance of "+getClass().getName()); }&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;A Time-class can also be constructed to represent a special interval such as Day, Month or the dreaded Week (there are actually two week "1" in most Calendar years... which is just plain stupid).&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6929830-108429289542405927?l=gnejs.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://gnejs.blogspot.com/feeds/108429289542405927/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6929830&amp;postID=108429289542405927&amp;isPopup=true' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108429289542405927'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108429289542405927'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/2004/05/working-with-dates-and-stuff.html' title='Working with Dates and stuff'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6929830.post-108426680594776307</id><published>2004-05-11T11:13:00.000+02:00</published><updated>2004-05-11T11:14:37.153+02:00</updated><title type='text'>Testing posting through the API</title><content type='html'>This post is written in &lt;a href="http://www.vim.org"&gt;VIM&lt;/a&gt; and uploaded using the BloggerAPI from a Ruby XML-RPC client.&lt;br /&gt;&lt;br /&gt;Coolt indeed!&lt;br /&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6929830-108426680594776307?l=gnejs.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108426680594776307'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108426680594776307'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/2004/05/testing-posting-through-api.html' title='Testing posting through the API'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6929830.post-108420092229844278</id><published>2004-05-10T16:51:00.000+02:00</published><updated>2004-05-10T16:55:22.296+02:00</updated><title type='text'>First wobbly steps into BlogLand</title><content type='html'>Yupp, I suppose it's time to take a stand and publish all that shit I'm currently pestering my friends and co-workers with...&lt;br /&gt;&lt;br /&gt;Don't expect to see daily updates though - I'm still trying to structure the way I'd like to do this.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6929830-108420092229844278?l=gnejs.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://gnejs.blogspot.com/feeds/108420092229844278/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6929830&amp;postID=108420092229844278&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108420092229844278'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6929830/posts/default/108420092229844278'/><link rel='alternate' type='text/html' href='http://gnejs.blogspot.com/2004/05/first-wobbly-steps-into-blogland.html' title='First wobbly steps into BlogLand'/><author><name>Anders Engström</name><uri>http://www.blogger.com/profile/00645478873504685066</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='30' src='http://hem.passagen.se/azure/pix/myself2.gif'/></author><thr:total>1</thr:total></entry></feed>
