System News
   
News about Solaris and Sun Microsystems

Free 4 Week Trial!


April 14, 2008
Article #19761
Volume 122, Issue 3
Section: Java Technology

 

the natural way to write code is in short iterations and feedback cycles with a short waterfall phase

-- Adam Bien, Java Champion
 


 


Java Champion Adam Bien on the Latest Technologies
A Veteran Shares His Viewpoints, Reveals His Approach

Java Champion Adam Bien has an extended history with both the Java SE and Java EE technologies, having worked with both since their inception with JDK 1.0 and Java Web Server, as Janice J. Heiss reports. At the outset of the interview, Bien identified three fallacies associated with the Java EE platform: the belief that J2EE is complex; the belief that Java EE 5 is easy; and the belief that distributed programming could be simpler. Instead, he maintains, the process of building J2EE applications is labor intensive and can be boring but not exactly complex. He offered code samples of the operations necessary to deploy the server-side component HelloBean. With Java EE 5 the process is somewhat simpler.

Bien identified distribution of data and concurrency as the two toughest challenges connected with Java EE patterns. The fact that Java EE 5 starts transactions by itself, that it features nearly transparent threading and automatically JPA entities with the database while also enabling easy detection of potential inconsistencies are all features that make the solution an improvement over its predecessors.

Heiss asked which Java EE patterns a developer needs to master, and Bien responded by saying "all of them," adding that one can't know too much. A more important consideration is whether to build an application on domain-driven or service-oriented principles. Again, code samples illustrate his point.

It is equally important, Bien noted, that developers familiarize themselves with such Java SE 6 features as Java DB, JavaScript support, the jrunscript that allows you to test the scripts "outside" the VM, and the other scripting languages, such as Groovy, Ruby, BeanShell, JavaFX, as well as the extended JConsole with its java.util.ServiceLoader class.

Bien dismissed the writing of Javadoc comments as "worthless," noting that the practice was expensive and redundant. He supported his point with code samples. He provided some advice on this subject as follows:

  • Document the unobvious background knowledge, the intention and not the result.
  • Try to capture the concepts in a central place -- for example, a wiki -- and only reference the contents.
  • "Escape" obvious facts with marker tags -- don't describe them over and over again. Be DRY.
  • Include samples, how-to's, and so on in your documentation.
  • Don't allow default Javadoc comments generated by the IDE.
  • Sometimes "No doc is the best doc" -- try to minimize the amount of documentation and describe only the key concepts.

And for those developers who were disappointed a few years ago with the GlassFish Application Server, Bien recommended having a second look, saying that the solution's performance and scalability are commendable.

Turning to the qualities a good developer should possess, Bien listed passion and curiosity and the ability to learn from colleagues.

When Heiss asked about the one indispensable Java class in his view, Bien responded with a hearty endorsement of Swing. "I like Swing because I know that everything is possible. I don't feel this about SWT or JFace," he said, adding that the recent addition of annotations, generics and enums are welcome in his view.

Queried about his work habits, Bien said the challenges and the creativity are the aspects of programming he enjoys most and the deletion of superfluous legacy code is the task he delights in. Unlike those travelers who occupy themselves with slick magazines, sudoku or crosswords, Bien said he prefers to program when he is on the road, and that he does his best work under the pressure of deadlines.

He described his approach to writing code as trying to "analyze the problem, then write some code, verify the solution, and sometimes adjust the problem to code in talking with customers. So the natural way to write code is in short iterations and feedback cycles with a short waterfall phase."

When he comes across issues that stump him, Bien said he turns to the Java Specification Request for answers and then uses Google for the answers it provides. [...read more...]

Keywords:
Other articles in the Java Technology section of Volume 122, Issue 3:

See all archived articles in the Java Technology section.


From the latest issue:



 


Customized news reports about Sun Microsystems. Just the news you need, none of what you don't.
50,000+ Members. 20,000+ Articles Published since 1998.