3.1 Why J2EE?
Reuse is an adjective that can beckon the attention of developers, managers, and bean counters. It promises savings in the form of shorter development efforts and higher quality. Unfortunately, reuse has been oversimplified, and overhyped, resulting in a minimized impact. For instance, some reuse (of the base class libraries) occurs just through using Java as a programming environment. If you add J2EE components, more reuse occurs. Of course, this is not the business domain type of reusability that would allow us to snap together applications as in the proverbial IC chip analogy made by Brad Cox. Nevertheless, Java's OO nature and the standards of J2EE are a progression toward achieving high degrees of reuse.
J2EE-based technologies provide what can be classified as horizontal technology reuse (Figure 3.2). Contracts, primarily in the form of Java interfaces, allow developers to use vendor-supplied technology solutions with a high degree of transparency. Imagine if the JDBC specification did not exist and developers had to write directly to vendor-supplied APIs; of course, then good OO developers would build designs that would decouple and wrapper vendor-specific APIs with a neutralized access API. Even though SQL is also a standard, each new target SQL-based data source would require a modification to this neutral API.
Figure 3.2. Horizontal technologies.
Fortunately, the JDBC specification allows the burden of access APIs to be moved to vendors. Developers simply acknowledge the specified contracts and generalized implementations and use them in applications to execute SQL against any vendor honoring the JDBC specification, which most, if not all, do.
Other horizontal technologies are vendor neutralized in a similar approach, allowing developers to concentrate on application-specific logic by using standards-compliant solutions. This frees developers from worrying about having to produce or refactor a horizontal implementation. Instead, the best vendor-supplied solutions can be engaged, resulting in shorter delivery times of applications that are robust and scalable.