Do you want to know how to develop your skillset to become a Java Rockstar?
Subscribe to our newsletter to start Rocking right now!
To get you started we give you our best selling eBooks for FREE!
1. JPA Mini Book
2. JVM Troubleshooting Guide
3. JUnit Tutorial for Unit Testing
4. Java Annotations Tutorial
5. Java Interview Questions
and many more ....
I agree to the Terms and Privacy Policy

Double your money again

Overview A long time ago I wrote an article on using double for money. However, it is still a common fear for many developers when the solution is fairly simple. The problem with using double for money double has two types of errors. It have representation error. i.e. it cannot represent all possible decimal values exactly. Even 0.1 is not ...

Read More »

EJB 3.1 Global JNDI Access

java-interview-questions-answers

As outlined in the previous parts of this series, the major drawback of the EJB v. 3.0 Specification was the lack of portable global JNDI names. This implies that there’s no portable way to link EJB references to a bean outside your application. The EJB v. 3.1 Specification fills this gap defining, in its own words: “a standardized global JNDI ...

Read More »

EJB Programmatic Lookup

java-interview-questions-answers

In our previous post we learnt about EJB references and EJB injection. Even though EJB injection is a powerful container facility that eases modular application development, sometimes performing a programmatic EJB lookup is instead desirable. Let’s suppose, for example, that a set of distinct EJBs implement a common strategy, defined by a common business interface. Depending on the result of ...

Read More »

The Perfect Singleton

From time to time I met Java programmers that are not really sure how they should implement Singleton pattern properly. (if you don’t have an idea what Singleton is just try Wikipedia: Singleton pattern). And I’m not talking about proper implementation in threaded environment. But using the most common implementation you can find over internet you can easily create as ...

Read More »

Basic EJB References, Injection and Lookup

java-interview-questions-answers

In the first part of this series we’ve introduced the mechanisms provided by the Enterprise JavaBeans v. 3.0 Specification to define EJB components, declare a reference to an EJB and wiring them up both by dependency injection or programmatic JNDI lookup. In this blog post we’ll examine some basic examples to understand how to use the EJB API. A Basic ...

Read More »

An Introduction to EJB 3.0 Injection and Lookup

java-interview-questions-answers

Introduction The Enterprise JavaBeans Specification v. 3.0 introduces a simplified, annotation based API for EJB injection and lookup. EJB 3.0 are now POJOs and can be injected in other components (such as EJBs and Servlets) using simple annotations. EJB 3.0 is one of many other POJO-based specifications that made it to Java EE 6, such as JSR-229 “Contexts and Dependency ...

Read More »

Hibernate Gotchas to Watch out

I’ve been using Hibernate for some time now and when I don’t work on a hibernate project for a while I find myself doing the same mistakes I did the previous times. So here is a sort of watch list for my self hopefully will be useful to someone else as well. Implement hashCode and equals You should always implement ...

Read More »

Breaking Down an Agile process Backlog

The process of breaking down a backlog is one of the most important steps in any Agile process. I have found over the years that the better a backlog is broken down the smoother the implementation of that backlog is. I have found that the single greatest influencer in the success or failure of a backlog is the process of ...

Read More »