万本电子书0元读

万本电子书0元读

顶部广告

Java EE 7 Development with WildFly电子书

售       价:¥

3人正在读 | 0人评论 9.8

作       者:Micha? ?mil

出  版  社:Packt Publishing

出版时间:2014-12-31

字       数:477.0万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
If you are a Java developer who wants to learn about Java EE, this is the book for you. It's also ideal for developers who already have experience with the Java EE platform but would like to learn more about the new Java EE 7 features by analyzing fully functional sample applications using the new application server WildFly.
目录展开

Java EE 7 Development with WildFly

Table of Contents

Java EE 7 Development with WildFly

Credits

About the Authors

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Instant updates on new Packt books

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Errata

Piracy

Questions

1. Getting Started with WildFly

An overview of Java EE and WildFly

WildFly and Enterprise Application Platform

Welcome to Java EE 7

JavaServer Faces 2.2 – JSR 344

Enterprise JavaBeans 3.2 – JSR 345

Java Persistence API 2.1 – JSR 338

Contexts and Dependency Injection for Java EE 1.1 – JSR 346

Java Servlet API 3.1 – JSR 340

JAX-RS, the Java API for RESTful Web Services 2.0 – JSR 339

Java Message Service 2.0 – JSR 343

Bean Validation 1.1 – JSR 349

Concurrency utilities for Java EE 1.0 – JSR 236

Batch applications for the Java Platform 1.0 – JSR 352

Java API for JSON Processing 1.0 – JSR 353

Java API for WebSocket 1.0 – JSR 356

New features in WildFly

Installing the server and client components

Installing Java SE

Testing the installation

Installing WildFly

Starting WildFly

Connecting to the server with the command-line interface

Stopping WildFly

Locating the shutdown script

Stopping WildFly on a remote machine

Restarting WildFly

Installing the Eclipse environment

Installing JBoss Tools

Alternative development environments

Installing Maven

Testing the installation

Summary

2. Your First Java EE Application on WildFly

WildFly 8 core concepts

The WildFly 8 directory layout

Managing the application server

Managing WildFly 8 with the web interface

Launching the web console

Deploying your first application to WildFly 8

Advanced Eclipse deployment options

Managing deployments with the web console

Changing the deployment scanner properties

Deploying applications using the command-line interface

Deploying applications to a domain

Summary

3. Introducing Java EE 7 – EJBs

EJB 3.2 – an overview

Developing singleton EJBs

Configuring the EJB project object module (pom.xml)

Coding our EJB application

Controlling bean concurrency

Using bean-managed concurrency

Cooking session beans

Adding a stateless bean

Adding a stateful bean

Deploying the EJB application

Creating a remote EJB client

Configuring the client's project object module

Coding the EJB client

Adding the EJB client configuration

Running the client application

Adding user authentication

Using the EJB timer service

Programmatic timer creation

Scheduling timer events

Adding asynchronous methods to our EJBs

Using fire-and-forget asynchronous calls

Returning a Future object to the client

Summary

4. Learning Context and Dependency Injection

Introducing Contexts and Dependency Injection

Named beans

CDI scopes

WildFly CDI implementation

Rethinking your ticketing system

Adding the required dependencies

Creating the beans

Building the view

JSF 2 facet suggestions

Getting ready to run the application

Combining the scheduler into our application

Installing RichFaces

Making your application rich

Running the application

Creating interceptors

Are EJBs and JSF Managed Beans obsolete?

Summary

5. Combining Persistence with CDI

Data persistence meets the standard

Working with JPA

Adding persistence to our application

Setting up the database

Installing the JDBC driver in WildFly

Using the command-line interface to create a new data source

Creating the Maven project

Adding the Maven configuration

Cooking entities

Adding Bean Validation

Configuring persistence

Adding producer classes

Coding queries for your application

Adding services to your application

Adding a controller to drive user requests

Coding the JSF view

Running the example

Summary

6. Developing Applications with JBoss JMS Provider

A short introduction to JMS

The building blocks of JMS

The JBoss messaging subsystem

Creating and using connection factories

Using JMS destinations

Adding message-driven beans to your application

Cooking message-driven beans

Adding the JMS producer

Compiling and deploying the application

Specifying which message to receive using selectors

Transaction and acknowledgment modes

Using JMS to integrate with external systems

A real-world example – HornetQ and ActiveMQ integration

Installing the ActiveMQ resource adapter

Consuming ActiveMQ messages

Summary

7. Adding Web Services to Your Applications

Developing SOAP-based web services

Strategies to build SOAP-based web services

JBoss SOAP-based web services stack

A brief look at the JAX WS architecture

Coding SOAP web services with WildFly

Developing a POJO web service

Inspecting the web service from the console

Testing our simple web service

EJB3 Stateless Session Bean (SLSB) web services

Developing a web service consumer

Developing REST-based web services

Accessing REST resources

JBoss REST web services

Activating JAX-RS

Adding REST to our ticket example

Adding filters

Consuming our REST service

Compiling our ticket example

Adding AngularJS

Choosing between SOAP and REST services

Summary

8. Adding WebSockets

An overview of WebSockets

How do WebSockets work

Creating our first endpoint

Expanding our client application

Transforming POJOs to JSON

An alternative to WebSockets

Summary

9. Managing the Application Server

Entering the WildFly CLI

Launching the CLI

Connecting from remote hosts

Using a CLI in the graphical mode

Constructing CLI commands

Determining the resource address

Performing operations on resources

Using the tab completion helper

Deploying applications using the CLI

Deploying applications to a WildFly domain

Deploying to all server groups

Deploying to a single server group

Creating CLI scripts

Deploying an application to several WildFly nodes

Restarting servers in a domain

Installing a data source as a module

Adding JMS resources

Using advanced languages to create powerful CLI scripts

Using scripting languages to wrap CLI execution

Using the raw management API to manage the application server

Reading management model descriptions via the raw management API

Creating your resource watches using the detyped API

Role-based security

Auditing administrative operations

Patching a running instance

Summary

10. Securing WildFly Applications

Approaching the Java security API

The WildFly security subsystem

Setting up your first login module

Using the login module in the Ticket web application

Switching to FORM-based security

Creating a Database login module

Encrypting passwords

Using the Database login module in your application

Securing EJBs

Securing web services

Securing the transport layer

Enabling the Secure Socket Layer on WildFly

Certificate management tools

Securing the HTTP communication with a self-signed certificate

Generating the server and client certificates

Creating an SSL-aware security realm

Securing HTTP communication with a certificate signed by a CA

Securing EJB communication

Connecting to an SSL-aware security realm

Summary

11. Clustering WildFly Applications

Clustering basics

WildFly clustering

Starting a cluster of standalone nodes

Starting a cluster of domain nodes

The domain controller configuration

Host configurations

Deploying clustered applications

Creating HA Stateful Session Beans

Clustering the Ticket example

Turning your cache into a distributed cache

Coding the cluster-aware remote client

Deploying and testing high availability

Web application clustering

Load balancing your web applications

Installing mod_cluster

Clustering your web applications

Programming considerations to achieve HA

Achieving HA in JSF applications

Summary

12. Long-term Tasks' Execution

The overview of the batching framework

Our first batch job

Creating a chunk-based batch step

Creating a job-based batch step

Using concurrency utilities in Java EE

Introducing threads to enterprise beans

Summary

13. Testing Your Applications

Test types

Instruments used for testing

Getting started with Arquillian

Writing an Arquillian test

Configuring the pom.xml file

Writing your first Arquillian test

Running Arquillian TicketTest

Running Arquillian tests using Spock

ShrinkWrap Resolver

ShrinkWrap Descriptors

Persistence testing

Arquillian Warp

WebSockets testing

Enhancing your Arquillian test

Additional information

Summary

A. Rapid Development Using JBoss Forge

Installing Forge

Starting Forge

Creating your first Java EE 7 application with JBoss Forge

Building and deploying the application

Your Forge-demo application in action

Index

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部