esisconsulting.com

Download Report

Transcript esisconsulting.com

Section 3 - Application
Management (Assembly,
Deployment and
Configuration)
ESIS Consulting LLC
(C) ESIS Consulting LLC. All rights reserved
Application Assembly
•
•
•
•
Application contains code artifacts such as
Servlets, JSPs, EJBs and supporting class files
In order to be deployed onto a JEE Application
Server, the code artifacts need to be assembled
as Modules
There are various tools provided by IBM for
assembly and deployment
The outcome of using the assembly tool is
deployable Archive file
Application Assembly Cont...
•
•
•
•
During assembly, you create annotations or
deployment descriptors that will be used
during deploy time
You can also create environment specific
binding and IBM extensions for JEE
The extensions definitions are stored in a
separate deployment descriptor to allow
portability
You can edit any deployment descriptor
manually using an XML editor or a text editor
Deployable Modules
Structure of an Enterprise Archive
file (EAR file)
•
•
EAR file is a standard Java Archive file (jar file)
with a .ear extension
EAR file contains JEE Modules and deployment
descriptors
Application Root
META-INF
application.xml (enter
ibm specifi application.xml here)
EJB Module (.jar)
WEB Module (.war)
Client module (.jar)
Tools available for Application
assembly and deployment
1. IBM Assembly and Deploy tools for
Websphere Administration
2. IBM WebSphere Application Server
developer tools for Eclipse
3. IBM Rational Application Developer for
WebSphere Software
4. Monitored directory feature
http://www.redbooks.ibm.com/redbooks/SG248022/wwhelp/wwhimpl/js/html/wwhelp.htm
remember to add questions on the tools
capabilities
Tools available for Application
assembly and deployment Cont ...
5. Using wsadmin scripts
6. Using Java programs that operate on WAS
JMX MBeans
7. Using Java programs that that conforms to
Java EE Application Deployment API
specification (JSR-88). This method is
deprecated
Structure of an EJB module
•
EJB Module is packaged as jar file
EJB Root
META-INF
ejb-jar.xml
<ibm specific xml>
Class files
EJBs can also be packaged with a WAR file
of a Web Application for simplified
deployment
•
Structure of a Web Module
•
Web Module is packaged as WAR file which
is a standard jar file with *.war extension
Web Module Root
WEB-INF
web.xml
<websphere specific web.xml>
lib/ (library archive files)
classes/ (class files)
tags/ (.tag files)
jsp,static html files
Business Level Application
•
•
•
•
Is a model that defines an application that is
typically more than a JEE Application as it
makes sense to the business (rather than IT)
Can contain non WAS runtimes such as
Web Servers, Proxy servers
Is a configuration artifact that is stored in
WAS configuration repository
Provides management features for
applications (install,activate,monitor,remove
etc)
OSGI Application
•
•
•
•
•
•
Dynamic module based programming model
Can plug in new modules (referred to as
bundles) or update dynamically
WAS uses Equinox as the framework for
OSGI Applications
Has three layers: Module layer, Lifecycle
layer and Services layer
The modules/bundles are packaged as JAR
files
OSGI Applications are packaged as EBA
SCA - Service Component
Architecture
•
•
•
•
Is a programming model that enables to
build complex applications using SOA
(Service Oriented Architecture)
Lets you create services out of existing
components irrespective of the language
used. (Language neutral)
Services can be combined to create
composites
Components model makes the assembly of
business logic simple
Deploying Enterprise Applications Liberty Profile
Two ways to deploy a Web Application
1. Drop the ear file or exploded directory into
the configured dropins directory (by default
dropins directory is automatically monitored)
The location of the dropins directory is
configurable
2. Add an Application element in server
configuration file server.xml
<application id="myApp" name="myApp" type="war"
location="D:/apps/ImpactEBA.war"/>
Deploying Enterprise Applications
in Full Profile
Using Admin Console:
Applications > New Application > New Enterprise Application
Deploying Enterprise Applications
in Full Profile Cont...
You can install the following modules: EAR,WAR,JAR or SAR (Session
Initiation Protocol Archive)
You can upload these files either from the client you are accessing the Admin
Console (Local) or from the Server running WAS (remote)
You can choose 'Fast Path' or 'Detailed' mode for installation. 'Fast Path'
prompts for more information only when required
You can choose to generate default bindings and mappings
Important installation options available:
Precompile JavaServer Pages files (True or False)
Distribute Application (True or False)
Application Name
Override class reloading settings for Web and EJB Modules
Reload interval
Business Level Application Name (option to create new BLA)
Deploying Enterprise Applications
in Full Profile Cont...
You can map the modules to Application Servers, Clusters or Web Servers
Using IBM Assembly and Deploy
Tools for WebSphere Administration
•
•
•
•
•
•
•
Free tool to assemble and deploy
Applications to WAS (Java EE, OSGi, Web
Services applications are supported)
Fully integrated tools and support
Publish Application to the Server
Visual Editors, Code validators and
automatic Deployment Descriptors
Enhanced EAR editor
Jython Scripting Editor and Debugger
Does not include WebSphere Application
Using WebSphere Developer Tools
for Eclipse
•
•
•
•
•
An Eclipsed based Lightweight development
environment for building JEE applications
Can publish code locally and to remote
servers
Can be installed using IBM installation
manager or using Eclipse Marketplace
Does not include WebSphere Application
Server Software
Can be considered as a mini-RAD (Rational
Application Developer)