In recent years, a large amount of software development activity has migrated from the client to the server. The client-centric model, in which a client executes complex programs to visualize and manipulate data, is no longer considered appropriate for the majority of enterprise applications. The principal reason is deploymentit is a significant hassle to deploy client programs onto a large number of desktops, and to redeploy them whenever the application changes. Instead, applications are redesigned to use a web browser as a "terminal." The application itself resides on the server, formatting data for the user as web pages and processing the responses that the user fills into web forms.
If you set out to develop a web application, you need to choose a technology that has several important characteristics. You need to generate large amounts of dynamic HTML conveniently. You require access to databases and other services. The technology must provide an architectural foundation for performance and stability. Finally, you must be able to partition your pro-gram logic in a way that allows for future growth and maintainability. The first web applications used the CGI (Common Gateway Interface) mechanism and a collection of server-side scripts, typically written in Perl, but occasionally in C, Python, PHP or other languages. There are numerous problems with this approach. The CGI mechanism does not scale well since every web request spawns a new server process. Communication between processes-for example, to share resources such as database connections-is extremely awkward to program. And finally, exotic programming languages may have their charm but they lack the ability to do the "heavy lifting." Features such as database access or security are typically not part of the language but supplied by a non-standard third-party library. That puts the programmer at the mercy of not only the implementors of the language itself but also the providers of various third-party libraries.
Java programmers have enjoyed the power of servlets for some time, which solves many of these problems. Servlets are programmed in Java, a language that is widely supported. Java has built-in features for database access, networking, multithreading, security, and so on. Each servlet executes in its own thread, thus avoiding the cost of generating server processes. Servlets can easily share resources such as session state and database connections. The principal disadvantage of servlets is that it is plainly tedious to generate HTML. All HTML must be generated programmatically, by statements that print all the text and tags. In particular, that means that the pages are generated by programmers. We all know what can happen when programmers try their hand at web design.
An increasingly popular approach in recent years has been the use of webserver scripting languages such as Netscape LiveWire and Microsoft ASP (Active Server Pages). With these systems, a programmer embeds code snippets into web pages. The pages themselves can be professionally designed by a web designer. The web server executes the code snippets when serving the page, inserting the HTML that results from the execution of each snippet. The advantage of this approach-and the reason for its popularity-is that you can get simple results very quickly. But what looks like fun and great productivity early on turns out to be a maintenance nightmare later. When you intermingle the presentation (the static parts of the HTML pages) and the business logic (the code snippets), it becomes very difficult to change either when the need arises. Web designers will not know how to move the code around when redesigning the pages. This makes any redesign a costly affair involving frequent interaction between programmers and web designers. Finally, keep in mind that you are tied into a particular web server. For example, if you develop your application in ASP and later want to use Apache instead of Microsoft IIS, you are stuck.
The JSP technology that is the topic of this book overcomes these issues. JSP has the same advantages as servletsin fact, JSP pages are servlets. You use the full power of the Java language, and not some scripting language, to implement your business logic. By using beans, XML transformations, and tag libraries, JSP lets you separate the presentation logic and business logic. For example, in a well-structured JSP application, you can have the same business logic with multiple interfaces, giving your users the choice to use a regular web browsers or a mobile phones that uses WAP (the wireless access protocol).
This book teaches you how to build robust and scalable web applications with JSP. It covers the JSP syntax, the features that JSP inherits from servlets such as session management, the interaction between servlets and beans, a number of useful Java topics such as JDBC (Java Database Connectivity) and XML. Finally, and most importantly, you will learn about application partitioning and deployment-these subjects make all the difference between a quick hack and a robust application that will withstand the test of time. Unlike other books, this book takes a properly JSP-centric approach, in accordance with the recommendations that Sun Microsystems makes in their Java Enterprise blueprints. This is very appropriate and a major strength. Where other books start out with servlets and discuss JSP as a second method for web programming, this book shows you why JSP pages have a higher position in the food chain. A JSP page can do everything a servlet can, but where you have to do a lot of tedious programming and organizing when you use servlets, JSP has higher level capabilities that let you focus on your business problems instead.
In the spirit of the Core series, this book contains is plenty of real-world advice that you won't find in the online documentation. The authors don't dwell on tedious syntax and boring minutiae. Unlike so many computer book authors, they have done the hard work and separated the wheat from the chaff. You won't waste time studying features that you won't use, but you will find good coverage of those subjects that you actually need when building real applications. I am confident you will find this Core book truly useful. I hope you enjoy it and have the opportunity to use it for building great web applications.Cay Horstmann
San Jose, August 2000
Every Core Series book:
Core JSP delivers:
Product Details
Would you like to update product info or give feedback on images?
|
|
Share your thoughts with other customers:
|
||||||||||||||||||||||
|
Most Helpful Customer Reviews
10 of 11 people found the following review helpful:
2.0 out of 5 stars
Reconsider,
This review is from: Core JSP (Paperback)
If you're like me and type in the examples provided in the textbook to make sure I understand what I'm doing, then you will NOT like this book. There's WAY too many errors in the examples provided. Not only that but the source code accompanying the CD is also full of them. I wonder why this book is NOT at all like it's counterpart, "Core Servlets and Java Server Pages". The examples and syntax mistakes in this book make it definitley a book, if I had known, NOT to buy. Almost every single example has major inconsistencies. Another thing I wonder is did the authors of this book REALLY know JSP and HTML when they were writing this...and also if the publisher was really so dumb enough to let this book slide without testing out some random codes from the book...My review is that if you like reading just the book, then you'll be fine with this text, however if you do the examples, then you'll want to return this book. Unfortunately, I bought this book so I'll have to keep it. Find another book on JSP if you can because this is NOT the one you would want...trust me. And I agree with the few individuals who did not give this book a high rating because they, like me, were the only ones who ACTUALLY read this book...i'm surprised that some of the developers also gave this book a high rating even though they should have picked up on the problems in the code right from chapter 2 of this book.
5 of 5 people found the following review helpful:
3.0 out of 5 stars
Needs work,
By A Customer
This review is from: Core JSP (Paperback)
I would rank this book as mediocre at best. More annoying than the numerous editorial oversights in the text and code (and there are many) are the misuses of terms, both technical and nontechnical. One gets the impression that the authors are trying to write beyond their abilities. It also makes me question the accuracy of the rest of the material when I find such errors on topics with which I am already familiar.Also frustrating is the way a lot of concepts are referenced before being introduced, with no indication that such is the case. If I didn't already know Java very well and have an inkling about JSP coming in, I expect I would have been very confused. I was looking for something that would get me up to speed on JSP quickly and not get too bogged down in details, and in that respect the book did reasonably well. But I gave up on it halfway through because I found it too frustrating. It's not terrible, but with a bit of work and better editing, it could have been a lot better.
4 of 4 people found the following review helpful:
2.0 out of 5 stars
Examples weren't throroughly tested,
By Taco Bill (Elkton, MD USA) - See all my reviews
This review is from: Core JSP (Paperback)
Don't know how this text got past the editors. Just about every chapter had typos and syntax errors. Some of the scriptlets had class instantiation problems that needed to be corrected. There were include directives that referenced code that wasn't included on the accompanying CD - nor shown in the book. The JNDI/LDAP section was a joke and the XML didn't work without debugging either.For those giving the book 5 stars - I wonder if they tried the examples or just read the text?
Share your thoughts with other customers: Create your own review
|
|
Tag this product(What's this?)Think of a tag as a keyword or label you consider is strongly related to this product.
Tags will help all customers organize and find favorite items. |