Tom Tromey (Red Hat) who wrote the GCJx as a extension to GCC to support Java 1.5 features among other changes has proposed a merge with ECJ, the Eclipse compiler from the Eclipse Foundation. The ramifications of this change are rather interesting.
"While programs in the Java language are theoretically immune from memory leaks, there are situations in which objects are not garbage collected even though they are no longer part of the program's logical state. This article shows you how Soft references, like weak references, can help applications prevent object loitering by enlisting the aid of the garbage collector in making cache eviction decisions."
If you've been coding in Java for awhile, you know how to write a method to test equality. Why write tests for something you can code in your sleep? Because, as Jeff Langr points out, you've probably made plenty of dumb mistakes in your career, either while asleep or while wide awake. It's simpler and safer to just think of tests as specifications that you always have to code.
"Turnabout is fair play, and it is refreshing to see that IBM is beginning to understand that it needs a strategy to try to bring the 100000 partners who write code for Microsoft's Windows platform onto all of its eServer platforms - not just xSeries and BladeCenter servers that run Windows natively on Intel and AMD processors. For a decade, software vendors have been porting their OS/400, AIX, and MVS applications to Windows, or creating whole new application suites that compete against software developed for those platforms. Now, IBM wants to turn the tables on the Windows ecosystem, and it is enlisting the support of Mainsoft to do this."
"The Java based lightweight implementation of the Internet Engineering Task Force Secure Shell protocol provides secure remote log-in and other secure network services over an insecure network. The protocol has three major components: Transport Layer, User Authentication and Connection. The implementation is lightweight due to using the highly optimized cryptographic library IBM CryptoLite for Java, efficient buffer and I/O handling, memory reuse to avoid excessive garbage collection, and threads are not used."
"Many new and veteran developers are hopping onto the ever-growing Apache Geronimo bandwagon. Thus, the ability to build Geronimo is becoming increasingly important to developers who want to incorporate changes or full-custom modules. Unfortunately, building Geronimo is no trivial task. It requires learning new build scripts and companion build applications. Luckily, you can follow this step-by-step guide to understand exactly how to build the Apache Geronimo source code from scratch."
The latest units/quantities packages (for the upcoming JScience 3.0) has been submitted to the JSR-275 expert group for review. It provides compile time check of quantities consistency through class parameterization. You can browse the proposed API here (two new packages javax.quantities and javax.units). The JScience pre-release implementation is available here: sources, binaries.
GNU Classpath 0.20 has been released. "New StAX pull parser and SAX-over-StAX driver. Full XMLEncoder implementation. The packages javax.sound.sampled, javax.print.attribute and javax.print.event have been implemented. Lots of new datatransfer, print, swing and swing.text work. Performance improvements in the painting/layout mechanism. Additional 1.5 support, including (separate) generic branch release. SecurityManager cleanups and start of review of all Permission checks. Buildable on cygwin. Fully buildable as 'in-workspace' library-plus-vm inside (native) Eclipse. Real world Free Swing and CORBA example added." There is also a Roadmap paper available.
Although, because of its prominence, Java gets a lot of attention and with it much criticism (some of it valid), many don't realize that some big breakthroughs have arrived and that the Java development landscape is solving important problems. Also, Developer.com posted their "product of the year" awards for 2006. Java related products have the strongest showing with the largest number of awards.
If you are a security developer and need to interface a Java application with the local operating system user registry, what do you do? This article gives you the answer: UNIX/Linux PAM-compatible systems that use authentication based on the GNU MD5 extensions to the crypt() system call. A pure Java implementation of MD5 crypt can provide a simple interface that can be used by Web applications to authenticate against the local UNIX registry.
"This article provides a brief overview of the currently available Java Development Kits and Java Runtime Environments for Linux on POWER. It covers the Linux distributions running on the IBM eServer iSeries, including eServer i5; eServer pSeries, including eServer p5; eServer BladeCenter JS20; and eServer OpenPower."
A surefire way to ignite a Web flame war is to say one programming language is better than another. James Gosling, known the "father of Java," understands that as well as anybody.
"Classpath hit 98% of 1.4 , and I think we'll see another big bump tomorrow since the XMLEncoder patch went in . I think we're in the 90s against 1.5, though it is hard to say since there hasn't been a branch merge in quite a while. Of course, japi isn't the final word on how we're doing, which is why Mark is going to talk about this at FOSDEM. The coming year looks as though it will be a very good one for gcj and Classpath. I think we'll finish 1.5."
There are always exceptions to the rule, right? In Java, those exceptions allow a clean break from normal program flow in the event of an exceptional situation. They're not used for program flow interruption, but for program flow branching, which can sometimes lead to difficult-to-maintain code. Marcus Zarra walks you through several best practices for using exceptions in Java.
"Data validation is a common chore in programming any user interface. The Java language's regular-expression support can make data validation easier. You can define a regular expression that describes valid data and then let the Java runtime see if it matches. But certain types of data have different formats in different locales. The ResourceBundle class lets you work with locale-specific data in an elegant way. This article shows how to combine the two techniques to solve a common data-entry problem."
The Mobile 3D Graphics API retained mode lets you work with a scene graph representation of your 3D world. This article, the second of a two-part series, describes just that -- an easy way to manage your 3D objects. Immediate mode renders 3D objects directly on the screen. Retained mode, on the other hand, lets you build a scene graph that you can manipulate and render at a later time.
"The Eclipse Foundation will make the Eclipse Web Tools Platform 1.0 release generally available the week of Dec 19th, 2005. Eclipse WTP 1.0 is an extensible, standards-based tool platform for developing J2EE and Web applications. This full version release solidifies the platform API for 3rd party extension, and accompanying major documentation improvements make WTP ready for the next-level of vendor adoption."
Although it is possible to use Core Data with little or no coding on your part, what if you want or need more fine-grained control over the persistence layer in your application? Marcus Zarra walks you through some of the more advanced features of Core Data.
"Clustering allows an application server to support multiple nodes with failover, session data sharing, and load balancing across many network nodes. This article provides details, direct from Apache Geronimo clustering effort team leader, Jeff Genender. Find out who is working on the details, how they work together to get the code written, and the ramifications these efforts are having on the open source community."
Dependency injection and aspect-oriented programming are complementary techniques, so it's natural to want to use them together. This article shows you how to add some power to your programming by combining dependency injection of the Spring framework with aspects written using AspectJ.