Developing complex software requires more than just churning out lines of code. As a software architect or developer involved in an industrial project, you must understand and be able to leverage critical software subdisciplines such as architecture, analysis and design techniques, development processes, visual modeling, and the underlying technology to be successful.
This book brings all these diverse elements together from the Java 2 Platform, Enterprise Edition (J2EE) development perspective to provide a holistic approach for the reader. Specifically, this book tries to answer the following key questions:
- What is the Unified Modeling Language (UML), and how is it relevant to J2EE development?
- How do Java and UML relate to each other?
- What are the key concepts in software architecture?
- How does a software development process fit into the J2EE software development equation?
- How can analysis and design help you to arrive at a better J2EE application design?
- What are the key J2EE technologies, and how do they fit together?
- How can you leverage the UML for J2EE development?
Rather than reinvent the wheel, the approach taken in this book is that of bringing together known works, such as Jim Conallen's Web Modeling Profile and the Sun Java Specification Request-26 for UML/EJB Mapping Specification.
To provide a practical illustration of the topics discussed, this book guides you through a sample J2EE application development project using the Rational Unified Process (RUP) and the UML. A working implementation is provided. Suggestions for further enhancements are also listed to assist you in continuing your exploration of the UML and J2EE technologies.
Intended Audience
This book is suitable for anyone interested in learning about the UML and how it can be applied to J2EE development. Current J2EE application developers will learn how to apply the UML to J2EE application development. UML practitioners will benefit from learning about the J2EE in the context of the UML. And software professionals interested in learning both the UML and J2EE will be able to get to a productive state faster facilitated by the intertwined contextual discussion.
After reading the book, you will
- Be able to effectively utilize the UML for developing J2EE applications
- Learn about the key J2EE technologies (EJB, JSP, and servlets) at a technical level
- Know when to use Model 1 versus Model 2 architecture, and identify situations where patterns such as value object and session bean chaining may be appropriate
- Understand software architecture concepts such as decomposition, layering, components, frameworks, patterns, and tiers
- Be able to apply techniques such as use case analysis, analysis object discovery, and analysis to design transformation to your J2EE project
- Understand the notion of software development processes and the fundamentals of some of the currently popular processes
- Learn how to start using the RUP for your J2EE project
This book only covers the Java language to the extent of providing a mapping of key Java concepts to the UML. Consequently, some familiarity with Java is assumed (knowing C++ or a similar language should be sufficient to get the basics from the examples). Prior knowledge of, or experience with, the UML, J2EE, or enterprise application development is not a prerequisite, but is certainly helpful.
How to Use This Book
If you are new to the UML and J2EE, you will get the most out of this book by reading it completely in a sequential manner.
Those who are comfortable with the UML and are primarily interested in learning about J2EE (or how to apply the UML to J2EE) can jump directly to Chapters 9-16.
On the other hand, if you know J2EE and mostly want to learn about UML, you should concentrate on Chapters 1-8, and then skim through the remaining portions of the book.
You will get the best results if you get your hands on a good modeling tool and try to apply visual modeling to a problem of your own!
Chapter Summaries
Chapter 1: Introduction to Enterprise Software provides a high-level overview of enterprise software development and related technologies.
Chapter 2: Introduction to the J2EE covers the basics of the Java 2 Platform, Enterprise Edition. It provides an overview of the basic technologies and the APIs, which form the J2EE.
Chapter 3: Introduction to the UML provides an overview of the UML and a quick introduction to the UML basics.
Chapter 4: UML and Java provides an overview of the Java language's mapping to the UML and covers some of the basic UML constructs.
Chapter 5: Overview of Activities introduces the notion of software development processes and outlines the approach taken in the book.
Chapter 6: Architecture, which is an important aspect of good software, introduces the notion of software architecture and provides an overview of some of the concepts in software architecture.
Chapter 7: Analyzing Customer Needs shows you how to apply UML use cases to better understand customer requirements. No matter how cool the software, if it does not meet the customer's requirements, it is a failure!
Chapter 8: Creating the Design focuses on analyzing the requirements further and creating the initial design for the case study. This chapter discusses how to translate the requirements you have gathered into software.
Chapter 9: Overview of J2EE Technologies lays the groundwork for the J2EE technologies we discuss in the remaining chapters.
Chapter 10: Servlets provides an overview of the Java servlet technology, discusses how they are modeled in the UML, and then shows a representative application of UML and servlets to the case study. Java servlets are ideal for the request-response oriented Web paradigm.
Chapter 11: JavaServer Pages teaches you about JSPs, when to use them, and how to use them in the sample project. JavaServer Pages (JSP) combine the power of servlets with the flexibility of HTML pages.
Chapter 12: Session Beans discusses how session beans are used in the middle tier and how to best model and utilize them. Session beans are one of the three types of enterprise beans provided in the J2EE. The chapter concludes with the usage of session beans in the context of the case study.
Chapter 13: Entity Beans focuses on the entity bean concept, its advantages and issues, and how to effectively model it in the UML. Entity beans provide a convenient way to objectify the stored data.
Chapter 14: Message-Driven Beans covers the technology and how to model them in the UML. Message-driven beans are a new addition to the J2EE Enterprise JavaBean specification.
Chapter 15: Assembly and Deployment discusses how UML can help assembly and deployment of a distributed application.
Chapter 16: Case Study discusses the details of the example used in this book including general requirements, restrictions, and such.
References for further reading include books, articles, and online sources.
A Glossary containing specialized terms and their meanings is provided for quick reference. An Index is provided for quick lookup and reference.
Conventions
We use several notational conventions throughout this book. A short list is provided for your reference:
- Italicized words are used to highlight key concepts or terminology.
- References to terms such as javax.servlet.http.HttpServletResponse are used to identify the exact J2SE or J2EE classes for further details. For example, in the preceding term the user is being referred to the HttpServletResponse class, which is found in the http package located in the servlet package of the javax package.
- Boldface text is used to identify keywords and reserved words in the context of Java/J2EE, for example, ejbCreate.
- Code samples are shown in a slightly different format to distinguish them from plain text, for example, public void acceptOrder() {
0201738295P10052001