This chapter from "SOA Using Java Web Services" examines how to build an Ajax front-end to an online shopping application. Through detailed code examples, it walks you through building an Ajax application that consumes RESTful Java Web services endpoints.
SOA Using Java Web Services is a hands-on guide to implementing Web services and Service Oriented Architecture (SOA) with today's Java EE 5 and Java SE 6 platforms. Author Mark Hansen presents in explicit detail the information that enterprise developers and architects need to succeed, from best-practice design techniques to state-of-the-art code samples.
Hansen covers creating, deploying, and invoking Web services that can be composed into loosely coupled SOA applications. He begins by reviewing the "big picture," including the challenges of Java-based SOA development and the limitations of traditional approaches. Next, he systematically introduces the latest Java Web Services (JWS) APIs and walks through creating Web services that integrate into a comprehensive SOA solution. Finally, he shows how application frameworks based on JWS can streamline the entire SOA development process and introduces one such framework: SOA-J.
- Introduces practical techniques for managing the complexity of Web services and SOA, including best-practice design examples
- Offers hard-won insights into building effective SOA applications with Java Web Services
- Illuminates recent major JWS improvements-including two full chapters on JAX-WS 2.0
- Thoroughly explains SOA integration using WSDL, SOAP, Java/XML mapping, and JAXB 2.0 data binding
- Walks step by step through packaging and deploying Web services components on Java EE 5 with JSR-181 (WS-Metadata 2.0) and JSR-109
- Includes specific code solutions for many development issues, from publishing REST endpoints to consuming SOAP services with WSDL
- Presents a complete case study using the JWS APIs, together with an Ajax front end, to build a SOA application integrating Amazon,Yahoo Shopping, and eBay
- Contains hundreds of code samples-all tested with the GlassFish Java EE 5 reference implementation-that are downloadable from the companion Web site, http://soabook.com.
For more information on Ajax and Java Web services go to Prentice Hall Publishing.
Mark Hansen, Ph.D., is a software developer, consultant, and entrepreneur. His company, Javector Software, provides consulting and software application development focused on Web Services. Mark is a content developer for Project GlassFish and a member of the expert group for JAX-RS: The JavaTM API for RESTful Web Services JSR-311. Mark has also developed the open source SOA-J application framework for WSDL-centric Web Services development.