Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Portability across a variety of middleware environments including Tomcat, and WebLogic.
  •  

In this chapter, we cover the basics of setting up and deploying an application using Fabric3. 

...

...


The starter calculator applications are the recommended way to get familiar with Fabric3. To build and deploy the calculator applications, do the following:

  • Build the starter modules.

In the directory where you extracted the samples distribution, go to the /starter

...

 project folder and execute: 

mvn {code{color:#333333}} mvn clean install

...

Code Block


Info

Note internet access is required the first time the project is built so Maven can download the required project dependencies. Remote access can be turned off for subsequent builds by executing: 

mvn -o clean install


JARs containing the application artifacts will be created in the /target output directories for each application.
* Build the Fabric3 server distribution.

Download the Fabric3 standalone runtime by executing the Maven build script from the samples /servers/vm directory:
mvn -o clean install



This will create a server image for use with the samples in the /target/image directory.  Note the server is configured to run as a single instance. The /servers/cluster directory contains modules which will configure a multi-cluster Fabric3 installation. The starter applications can be deployed to either topology.
* Start the server. 

To launch a Fabric3 server in single-VM mode, execute the following from the /bin directory /servers/vm/target/image by executing:
java -jar server.jar


Alternatively, the Fabric3 server can be started from another working directory by executing:
java -jar <path to bin directory>server.jar


* Deploy the application.

After the server has booted, deploy a calculator application archive by copying it to the Fabric3 runtime /deploy directory.
The runtime will write a message to the console after the war has been deployed. Depending on the application deployed, one of the following will be available.
* The web calculator UI can be accessed at http://localhost:8181/ calculator/entry.html.

* The REST calculator resource can be accessed using a GET with the formula to calculate included in the URI as in: http://localhost:8181/calculator/1+1

* The web services calculator can be accessed at http://localhost:8181/calculator and its WSDL from http://localhost:8181/calculator?wsdl.

The samples also contain a separate client for the web services calculator. The client module is located at /samples/wscalc-client. The WSCalcClient class can be executed using the Java command line or via an IDE.

h1. Building and Deploying BigBank

To build and deploy BigBank, do the following:
* Build the BigBank source.

To build BigBank, go to the bigbank project folder and execute:
mvn clean install


The build will produce two archives: bigbank-loan-1.7.jar (the server module) and bigbank-client-1.7.jar (the web service client)
* Start the server.

Boot the Fabric3 runtime from the server/vm/image/bin directory by executing:
java -jar server.jar


* Deploy the archives.

Copy bigbank-loan-1.7.jar to the runtimes/vm/deploy directory.
* Deploy and Execute the client applications

BigBank includes a web application front-end and loan officer web application. Note both web applications currently do not support Internet Explorer. Please use FireFox, Chrome, or Safari.
Copy bigbank-web-1.7.jar and bigbank-backoffice-1.7.jar to the runtimes/vm/deploy directory.

Deploying BigBank to a Distributed Domain


The samples distribution also contains an automated build process for producing a set of clustered servers. To create the clustered servers, execute the following from the servers/cluster directory:
mvn clean install


...