Architecture

Now that you have a good idea of how the volumes in this series progress, I want to focus on what will be covered in this book. This description follows the flow of the book itself, and lets you know where to turn if you’re looking for something specific. I’ll also give you a little more detail here than what is in the the preface.

Databases

After walking through some design issues, the first technical topic in this book is that of databases. Although almost every Java developer working on enterprise applications has used a database, very few are competent database developers. In other words, programmers know how to create rows and columns, but have very little understanding of the best way to tune tables, of how to perform database normalization, or of making a database work in an efficient, useful way.

In the chapters on database design and setup, I’ll show how to create a database structure via the Structured Query Language (SQL). More importantly, I’ll focus on how to set up a good relational structure and examine how EJBs need to access the data. This discussion should allow you to move from using a database to mastering one, at least in the context of enterprise applications. Discussions will be applicable to any database vendor.

Directory Servers

While traditional relational databases are still the prevalent force for data storage in enterprise applications, alternative data mediums are becoming popular. XML-based databases and object-oriented databases are in direct competition with relational databases, and directory servers offer a complementary solution to existing databases. For data that is read far more often than it is written, directory servers excel in performance. Examples of this sort of data are authentication credentials, such as usernames and passwords, which tend to be performance-driven. In other words, the less time a user waits to log in, the better your application is perceived.

This book takes an extensive look at directory servers in order to show you how to develop systems that integrate multiple types of data stores. I’ll explain how to set up the directory store schema (which is analogous to the tables and columns of a relational database) and how to populate the directory store. I’ll also show you how the Java Naming and Directory Interface (JNDI) can provide fast access to a directory server. Finally, I’ll cover the tricky issues that surround using multiple data stores: replication, data overlap, and keeping data in sync and uncorrupted.

Enterprise JavaBeans

Once you’ve got a data store (actually, a couple of them) in place, I’ll finally move on to Java, and accessing that data through Java. In addition to the JNDI access for directory servers, you’ll learn how to use Enterprise JavaBeans (EJB) to interact with a database. I’ll cover setting up your EJB container, writing entity beans for data access, and using session beans to provide a layer between your entity beans and the rest of your application. Finally, I’ll detail how message-driven beans can allow communication between components that was almost impossible in earlier versions of the EJB specification.

Of course, we’ll quickly move beyond these basics. I’ll demonstrate the impact that EJB 2.0 has on your enterprise applications, and cover more complex issues such as using database sequences, direct access to entity beans, and how the container affects your EJB design. I’ll also detail the ins and outs of Remote Method Invocation (RMI) and how to make it perform at its best. Several chapters will be devoted to the EJB layer, so you’ll have plenty of Java code to sink your teeth into: entity beans, session beans, and message-driven beans will all be explored in relation to the enterprise application.

Get Building Java Enterprise Applications now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.