Adam Bien's Weblog
bad pbr sig - and a simple solution
After the addition of a hard disc to a mirrored zfs rpool, the boot process immediately stopped with the GRUB message: "bad pbr sig". It means that something is wrong with the Primary Boot Record (aka Master Boot Record). The solution was simple - I swapped the boot order of the hard discs in BIOS. Now it works perfectly again.
Posted at 10:55AM Feb 07, 2010 by Adam Bien in solaris | Kommentare[0]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
kenai.com is dead - long live kenai (under different name)
Even got this email:
"In an effort to get information out to the Kenai community quickly, while trying to manage the integration of our two companies, I think we did a poor job at communicating our plans for Kenai.com to you. I would like to remedy that now. Our strategy is simple. We don't believe it makes sense to continue investing in multiple hosted development sites that are basically doing the same thing. Our plan is to shut down kenai.com and focus our efforts on java.net as the hosted development community. We are in the process of migrating java.net to the kenai technology. This means that any project currently hosted on kenai.com will be able to continue as you are on java.net. We are still working out the technical details, but the goal is to make this migration as seamless as possible for the current kenai.com projects. So in the meantime I suggest that you stay put on kenai.com and let us work through the details and get back to you later this month.
Thanks for your feedback and patience."
These are actually great news. Hopefully all the kenai.com infrastructure like mercurial (subversion isn't fun), jira and hudson will be supported by java.net. So I'm waiting with the migration of "Real World Java EE Patterns" project and will even commit some more content soon. The great story about mercurial: the whole repository with history etc. sits on my machine and can be pushed wherever I want :-). kenai.com is/was an interesting platform - suitable not only for opensource projects.
Posted at 02:07PM Feb 06, 2010 by Adam Bien in Real World Java EE Patterns - Rethinking Best Practices | Kommentare[0]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Object Pooling Can Be Still Useful - For Entirely Different Reasons
Pooling was initially introduced as a tuning action for the slow performance of object creation and garbage collection in particular. On a modern JVM > 1.4 pooling is no more needed for the optimization of memory management in a typical business application. It can even have a negative effect on the garbage collector performance. In special cases, like creating millions of instances in every method call, it could still pay off.
Instance pooling, however is still interesting for objects with slow custom "post construction". In some cases you want to inject some dependencies after the object creation, read some configuration etc. This can be slow and doesn't have to be performed over and over again. In such cases object pooling will improve the overall performance.
Instead of prematurely optimize your application, I would rather build the simplest possible thing and measure the performance continuously (e.g. with VisualVM). In most cases you will be surprised where the actual bottlenecks actually are.
Posted at 09:00AM Feb 02, 2010 by Adam Bien in Real World Java EE Patterns - Rethinking Best Practices | Kommentare[2]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Free JUG Session In Hamburg - Real World Java EE Patterns - Rethinking Best Practices
At 02.02.2010, 8 P.M. I'm going to give a free JUG talk about Java EE 6 / 5 cool stuff and best practices in Hamburg.
We will discuss the relation between Contexts and Dependency Injection (CDI / JSR-299), Dependency Injection for Java (JSR-330) and EJB 3.1 - the lightweight components :-) Also the new Java EE 6 stuff like: stereotypes, interceptors, decorators, validation, REST + EJB 3.1 are going to be covered.
The Java EE 6 impact on architecture, build and test will be discussed as well. Heretical questions are especially welcome - this is a JUG session so it should be interactive fun.
Posted at 04:07PM Jan 30, 2010 by Adam Bien in Events | Kommentare[9]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Sun + Oracle, NetBeans, Glassfish, JavaOne and the Death of Kenai
JavaOne will take place in San Francisco from September 19-23, 2010 - so I was semi right :-). Most of the questions are answered here. kenai.com will be killed. What is a pity - it is/was a great platform with mercurial support. Glassfish, however, will be also commercially supported by Sun/Oracle.
Posted at 12:34PM Jan 28, 2010 by Adam Bien in General | Kommentare[5]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
JDeveloper vs. NetBeans - The Poll Results
The results are amazing: 434 (NetBeans) vs. 18 (JDeveloper). JDeveloper comes with some interesting stuff - it would be a nice extension of NetBeans. The integration wouldn't be that hard - both IDEs are Swing based...
Posted at 02:37PM Jan 27, 2010 by Adam Bien in Netbeans | Kommentare[8]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Sun + Oracle = Snorcle?
The new Sun + Oracle logo was revealed. Somehow aquarium / oracun and sparky related :-)
Posted at 09:06PM Jan 22, 2010 by Adam Bien in Fun | Kommentare[1]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Sun And Oracle - The Deal Is Approved
Some details. Hopefully the strategic plans / roadmap regarding Glassfish, NetBeans, OpenSolaris and hardware will be revealed soon. ...and what about JavaOne? :-)
Posted at 04:20PM Jan 21, 2010 by Adam Bien in General | Kommentare[0]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
My Opinion About Java FX
I was interviewed (java.sun.com) about Java FX in the enterprise, Java FX tooling and superfluous GoF patterns.
Posted at 10:07AM Jan 21, 2010 by Adam Bien in Publications | Kommentare[0]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices
Do We Need Stateless Session Bean Pooling?
Pooling is still mentioned in the EJB 3.1 / Java EE 6 specification. The question is: do you have to care? The answers are:
- Pooling is not a requirement, it is just an assumption: "...Since stateless session bean instances are typically pooled, the time of the client’s invocation of the create method need not have any direct relationship to the container’s invocation of the PostConstruct/ejbCreate method on the stateless session bean instance..."[EJB 3.1 spec, page 78]
- EJB container can either pool the instances or create a new one for each request
- The most important thing is, that every transaction (often request), gets an independent instance. Then you don't have to care about low level locking mechanisms. This can be achieved with or without (=creating a new instance for each request) pooling.
- Pooling is no more needed in modern JVMs for performance reasons in general. This, however, is highly dependent on the JVM and garbage collector configuration.
- With pools you can throttle the concurrency, because most (all I know) application servers allow you the configuration of max number of instances. You can control the concurrency of every bean type (Boundary) in a fine grained way. This is important for the avoidance of DoS attacks and dealing with legacy resources.
Posted at 11:11AM Jan 15, 2010 by Adam Bien in Real World Java EE Patterns - Rethinking Best Practices | Kommentare[11]
[my tweets]
Rss My book: Real World Java EE - Rethinking Best Practices

