Skip to content


Time management: optimized feeds, mail, twitter and phone.

I spend a lot of time behind my PC, during my workday but also in the evening. My new years resolution this year was to “optimize” and remove some clutter, saving time in the end.

This is what I did:

Organized Google Reader

A read a lot of blogs. Started with pure Java centric, it has become an important central part of all my knowledge gather. Blogs such as LifeHacker, PM Hut, 5whys, and many more resulted in a large aggregation.

Since March 26, 2007 you have read a total of 171,897 items.

From your 157 subscriptions, over the last 30 days you read 5,232 itemsclicked 94 itemsstarred 5 items, and emailed 0 items.

LifeHacker has an excellent blog about organizing your RSS feeds: which resulted into following:

Organized Reader

Organized by Priority

Cleaned up Twitter

I was following some funny, but totally useless spammers which cluttered my tweetwall, such as @mbaeten .
Got rid of those and used the Find Friends tool and started following some new. Let’s see if they make the cut next year.

Cleaned up phone

Removed all games which I ended up playing in bed while being insomniac.

Flashed my HTC Desire with Cyangenmod, for a better exchange calender integration, auto-update everything while on wifi only and created a priority call filter which only allows incoming calls from very few people while sleeping…

Cleaned up GMail

Unsubscribed from every newsletter who mailed me in last 6 months. Subscribed to their RSS feeds instead, if they had any. I got about 50 mails a day I needed to archive on my personal mail.

With the saved time, I wrote this blog.

So it has payed off already :)

Posted in Time management.


Collection of software laws

A collection of software laws…

Postel’s Law

Be conservative in what you send, liberal in what you accept.

Parkinson’s Law

Work expands so as to fill the time available for its completion.

Pareto Principle

For many phenomena, 80% of consequences stem from 20% of the causes

Sturgeon’s Revelation

Ninety percent of everything is crud.

The Peter Principle

In a hierarchy, every employee tends to rise to his level of incompetence.

Hofstadter’s Law

A task always takes longer than you expect, even when you take into account Hofstadter’s Law.

Murphy’s Law

If anything can go wrong, it will.

Brook’s Law

Adding manpower to a late software project makes it later.

Conway’s Law

Any piece of software reflects the organizational structure that produced it

Kerchkhoff’s Principle

In cryptography, a system should be secure even if everything about the system, except for a small piece of information — the key — is public knowledge.

Linus’s Law

Given enough eyeballs, all bugs are shallow.

Reed’s Law

The utility of large networks, particularly social networks, scales exponentially with the size of the network.

Metcalfe’s Law

In network theory, the value of a system grows as approximately the square of the number of users of the system.

Moore’s Law

The number of transistors on an integrated circuit will double in about 18 months

Rock’s Law

The cost of a semiconductor chip fabrication plant doubles every four years.

Wirth’s law

Software gets slower faster than hardware gets faster.

Zawinski’s Law

Every program attempts to expand until it can read mail. Those programs which cannot so expand are replaced by ones which can.

Fitt’s Law

The time to acquire a target is a function of the distance to and the size of the target.

Hick’s Law

The time to make a decision is a function of the possible choices he or she has.

Lehman’s laws

 Continuing Change — E-type systems must be continually adapted or they become progressively less satisfactory.

 Increasing Complexity — As an E-type system evolves its complexity increases unless work is done to maintain or reduce it.

I’m probably missing some, any idea’s?

Posted in general.


Maven: difference between -DskipTests and -Dmaven.test.skip=true

Recently came across this the existance of the -DskipTests argument while running maven.

From the userguide:

You can also skip the tests via command line by executing the following command:

mvn install -DskipTests

If you absolutely must, you can also use the maven.test.skip property to skip compiling the tests. maven.test.skip is honored by Surefire, Failsafe and the Compiler Plugin.

mvn install -Dmaven.test.skip=true

Skiptests is a feature of surefire, while -Dmaven.test.skip is a feature of maven itself.

Posted in Uncategorized.


IBM Java Health Center

The IBM Support Assistant comes with a variety of  tools, one of them being the Java Health Center. I recently found out about this tool and it’s a great one!

The Java Health center is

very low overhead monitoring tool. It runs alongside an IBM Java application with a very small impact on the application’s performance. Health Center monitors several application areas, using the information to provide recommendations and analysis that help you improve the performance and efficiency of your application. Health Center can save the data obtained from monitoring an application and load it again for analysis at a later date.1

It’s also pretty easy to install 2.

  1. Add the healthcenter.jar to %JAVA_HOME%/jre/lib/ext folder
  2. start whatever application with -Xhealthcenter
  3. Default port is 1912

The openingscreen:

and for instance the profiling tab:

References:

  1. Java Health Center- a low overhead monitoring tool - http://www-01.ibm.com/support/docview.wss?uid=swg21413628
  2. Installing the Health Center agent - http://publib.boulder.ibm.com/infocenter/realtime/v2r0/index.jsp?topic=/com.ibm.rt.doc.20/healthcenter/com.ibm.java.diagnostics.healthcenter.gui/docs/installingagent.html
  3. IBM Support Assistant -  http://www-01.ibm.com/software/support/isa/

Other:

  1. Feature overview: http://www.youtube.com/watch?v=5Tcktcl0qxs

Posted in Uncategorized.


JPA2 metamodel example

JPA2 includes the new metamodel, which allows us to use JPA typesafe. To see what has changed since JPA 1, I can recommend this and this blog.

Generating the metamodel turned out to be somewhat harder than I first thought. Since I’m a JBoss alcoholic, I’m using Hibernate as persistence provider with and the jpamodelgen subproject.

Generating the metamodel

According to the official documentation, all we need to do is add the hibernate-jpamodelgen to the classpath.

<dependency>
    <groupId>org.hibernate</groupId>
    <artifactId>hibernate-jpamodelgen</artifactId>
</dependency>

However, this resulted  in nothing. The only thing that did work for me was adding extra configuration with maven-annotation-plugin.

<plugin>
    <groupId>org.bsc.maven</groupId>
    <artifactId>maven-processor-plugin</artifactId>
    <executions>
        <execution>
            <id>process</id>
            <goals>
                <goal>process</goal>
            </goals>
            <phase>generate-sources</phase>
            <configuration>
                <!-- source output directory -->
                <outputDirectory>
target/metamodel
</outputDirectory>
            </configuration>
        </execution>
    </executions>
</plugin>
<plugin>
    <groupId>org.codehaus.mojo</groupId>
    <artifactId>build-helper-maven-plugin</artifactId>
    <version>1.3</version>
    <executions>
        <execution>
            <id>add-source</id>
            <phase>generate-sources</phase>
            <goals>
                <goal>add-source</goal>
            </goals>
            <configuration>
                <sources>
                    <source>target/metamodel</source>
                </sources>
            </configuration>
        </execution>
    </executions>
</plugin>

Success! The User.java file

@Entity
public class User implements UserDetails {
 /** The Constant serialVersionUID. */
 private static final long serialVersionUID = 1L;
 /** The user name. */
 @Id
 @Column(name = "USER_ID")
 @Size(min = 3, max = 10)
 private String username;
 /** The password. */
 @NotNull
 @Size(min = 6, max = 40)
 @Column(name = "PASSWORD")
 private String password;
 /** The name. */
 @Column(name = "NAME")
 private String name;
 /** The first name. */
 @Column(name = "FIRSTNAME")
 private String firstName;

was transformed into User_.java

import javax.persistence.metamodel.SingularAttribute;
import javax.persistence.metamodel.StaticMetamodel;
@StaticMetamodel(User.class)
public abstract class User_ {
 public static volatile SingularAttribute<User, String> username;
 public static volatile SingularAttribute<User, String> name;
 public static volatile SingularAttribute<User, String> firstName;
 public static volatile SingularAttribute<User, String> password;
}

Now we can use the model to do typysafe queries:

public UserDetails loadUserByUsername(final String username) throws UsernameNotFoundException,
 DataAccessException {
 CriteriaBuilder criteriaBuilder = entityManager.getCriteriaBuilder();
 CriteriaQuery<User> criteriaQuery = criteriaBuilder.createQuery(User.class);
 Root<User> u = criteriaQuery.from(User.class);
 Predicate usernameCondition = criteriaBuilder.equal(u.get(User_.username), username);
 criteriaQuery.where(usernameCondition);
 TypedQuery<User> query = entityManager.createQuery(criteriaQuery);
 try {
 return (User) query.getSingleResult();
 } catch (NoResultException e) {
 throw new UsernameNotFoundException("User not found: " + username, e);
 }
 }

Posted in jboss.


BruJug: Sébastien Stormacq, Build a RESTful Client-Server RIA with JavaFX Technology and Jersey

Copy paste ;) :

Speakers and Talks

Sébastien Stormacq

Sébastien Stormacq

Sébastien Stormacq is a Senior Software Architect at Oracle (Sun Microsystems). He uses his 15 years of professional experience to design large scale, secured and highly transactional architectures based on Sun’s middleware solutions. He also speaks at various high level Java conferences, like JavaOne 2009 and 2010, and he is one of the JUG Leaders of the Luxembourg JUG.

http://www.yajug.org

http://www.stormacq.com/

.

Build a RESTful Client-Server Rich Internet Application with JavaFX Technology and Jersey (JSR 310)

Rich Internet Applications (RIA) do require a strong service access and data access layer located on the back-end, just as traditional or web based applications. It is therefore essential to combine desktop technologies and server technologies in order to provide fast, efficient and secure access to your data. This talk will teach how to combine desktop technologies, such as JavaFX technologies, and back-end technologies, like web services and REST based services to build state of the art desktop applications. We will use the following technologies: RESTful web service and JSR 310 (Jersey) API on the server side, JavaFX on the client side. The JavaFX application will asynchronously poll RESTful web services to collect data that will be used to dynamically update the client rich UI.

Hands-On Training

After the 1st halftime, Sébastien proposes a hands-on training. Everyone is invited to bring long their laptop with Netbeans 6.91, Glassfish and JavaFX installed. If wished, we can make teams of 2-3 persons. Every team will develop simple application doing JavaFX – REST – Java EE. Sébastien will walk around, help and discuss.

So please don’t forget your laptop, and if you have a multi-outlet power strip at hand, we don’t mind neither :)

Let’s do JavaFX from the zero to hero in one evening :)

I’ll be there!

More information at http://www.brussels-jug.be/wiki/doku.php?id=events:2010_09_session1

Posted in Java, jbug.


Feedback impact

Feedback is an important tool for working together. As tech lead, I organize on a fairly regular basis feedback rounds with the people I work under and with people that work under me. With this experience, I distilled some tips on how to to set up the feedback rounds with impact.

About feedback

Feedback is an important tool as it gives invaluable information about you, the other person and the team. The goal is to improve his/her work as your own work as team lead.

Preparation

  • Plan feedback rounds well in advance. Not only is it important to let the other party prepare, but also communicating the upcoming feedback rounds weeks in advance makes the team aware of the upcoming feedback rounds. It’s easier to create an impact with feedback where an example can be given of the behavior.
  • Take enough time. I always plan 1h for each, although it’s not the plan to fill the entire hour. Typical feedback rounds take about 20min, but giving yourself the freedom to go into detail if necessary, makes the conversation open and not overhasty.
  • Plan personal conversations. Sincere feedback is feedback done in small groups. For developers, I bring the project lead with me, since the project lead can give another perspective.
  • Prepare yourself
  • Ask the other to explicitly prepare themselves. Point the other party that a good preparation is necessary.
  • It’s important to give both positive as negative feedback.

How to give efficient feedback

  1. Describe behavior that can change
  2. Use concrete examples that you have seen for yourself (preferred) or heard from.
  3. Use the I-form. I noticed that…
  4. Describe the effect the behavior had on yourself
  5. Let the other respond
  6. If relevant: ask for the desired behavior
  7. Explore the background and/or solutions

Follow up

An important aspect of feedback is the follow up. Plan something a couple of weeks after the feedback and see how the feedback changed you or the one you gave feedback to.

Regards,
Andries

Posted in management.


Next JBUG.be event is out there!

The program for our upcoming event is complete! Here it is…

18:00 – 19:00: Kabir Khan - What’s Cooking in JBoss AS 6

Kabir will talk about the JBoss AS 6 roadmap, the new development model, ongoing optimizations since AS 6. He will also give a bird’s eye overview of the new projects that will be bundled in AS 6, such as Weld, HornetQ, RestEasy and several more. There will be a short demo at the end showing some of the new features in AS.

19:00 – 20:00: Kris Verlaenen – Looking forward to the future of (j)BPM

There’s much going on in the area of BPM. This presentation will offer you an overview of how the jBPM project will continue to offer you business processes support (in their entire life cycle), while also taking these new challenges into account, like more dynamic or adaptive processes, standardization using the BPMN2 process definition language, etc.

I think we can all agree on the fact that these talks will be very interesting (to say the least).
So… do not forget to register for this event! (Maximium capacity is set to 45 people)

See you soon on the 3rd of June at Xplore premises!

Posted in jboss.


jBPM developers guide review

Finally some time to do the review.

Let me start with my biggest discovery: the book is written about jBPM3 and not the newer jBPM4. This is not mentioned on the Packt publishing site. Too bad, a jBPM4 book is still missing in the offering.

Conclusion

PRO:

  • Probably the best developers book about jBPM3 so far. Compared to BPM With JBoss jBPM, this book is aimed more for developers and goes further into the technical details.
  • The book brings beginners to an advanced level. It does not bring advanced users to a further level.
  • I would advice beginner jBPM developers to start with this book. It emphasizes on getting the basics right but does not hide the more advanced features.
  • The explanation is good, providing context and sufficient examples.

CON:

  • Their is definitely a language impedance for the writer. Sentence are basic, language constructs are poor and almost all the sentences start with “You’ll see” or “You will”. Very sad to see this poor editorial from Packt Publishing. Clearly no review by them, and I blame them and not the writer.
  • Some content is noble, but also beyond the goal of this book. Chapters 1 & 2 are not interesting to jBPM Developers. They cover a motivational speech about why you should care for open source, what is BPM and how to create your own BPM engine.
  • Some must have advanced topics are missing: integration with test frameworks, exception handling for example.

As stated, I do recommend this book for new jBPM developers since it does provide a rather good learning curve for new developers. Don’t expect this book to be a reference, therefore it is much to verbose and not advanced enough. The userguide of jBPM is a better reference.

Kind regards,
Andries

Posted in Uncategorized.


JBPM4 Spring integration has made it to Spring Enterprise Recipes

This is the first book that explains the Spring integration within jBPM. I’ve managed to see a copy of the long explanation. I’m impressed with the explanation and it is very understanding and complete! Saves me the trouble of testing the integration on Spring3 aswell ;)

I’m also referenced by name in the book, a nice pitch for me! I’ve ordered the book and I’ll publish a review later, but from what I’ve seen it looks very promising.

It’s written by Gary Mak of the best-selling Spring Recipes and Josh Long, an expert Spring user and developer.

Posted in bpm, jbpm, Spring.




Improve Your Life, Go The myEASY Way™