This readme.txt file describes the Flex 3 compiler module for J2EE application servers.
*******************************
* Introduction *
*******************************
The Flex compiler module for J2EE application servers is a Web Application aRchive (WAR) file that you can deploy
to most J2EE application servers that support servlets. This lets you rapidly compile,
test, and deploy an application: Instead of compiling your MXML file into a SWF file and
then deploying it and its wrapper files on a web server, you can just refresh the MXML
file in your browser.
The Flex compiler module for J2EE application servers also provides a JSP tag library
that lets you write Flex applications in JSPs.
The Flex compiler module for J2EE application is not for production use. The Flex compiler
module web application should not be made available on a public-facing web server.
*******************************
* Requirements *
*******************************
The Flex compiler module for J2EE application servers comes as a WAR file. You can deploy
it to any of the following J2EE web application servers:
* Adobe JRun 4 Updater 7
* Apache Tomcat 6.0.x
* IBM WebSphere 6.1.x � IBM 1.5
* BEA WebLogic 10 � Sun 1.5
* JBoss 4.2.x
*******************************
* Installation *
*******************************
To install the Flex compiler module for J2EE application servers, create an application root
directory and extract the contents of the WAR file into that directory. Your application server
might have a facility for deploying WAR files that you should use. After you deploy the WAR file,
restart your application server.
For example, on Tomcat, create a new directory under the {tomcat_install_dir}/webapps directory
and expand the WAR file into that new directory. Save your MXML and JSP files in that directory.
*******************************
* Configuration *
*******************************
The Flex compiler module for J2EE application servers uses the following configuration files:
WEB-INF/flex-config.xml
Defines the default settings for the Flex compiler.
WEB-INF/flex-webtier-config.xml
Defines settings specific to the web tier, such as logging, caching, and debugging.
WEB-INF/web.xml
Defines the web component settings for the Flex web application, such as servlet definitions
and mappings, and tag library definitions.
To use custom SWC files or ActionScript classes in your applications, add them to the
WEB-INF/flex/user-classes directory.
If you want to use data visualization components in your Flex applications, add the appropriate
SWC files to the WEB-INF/flex/libs directory.
****************************************************************
* Integrating with LiveCycle Data Services ES 2.6 or BlazeDS *
****************************************************************
LiveCycle Data Services ES 2.6 and BlazeDS do not include an integrated web tier compiler, but you can easily integrate the Flex compiler module for J2EE into a LiveCycle Data Services ES or BlazeDS web application.
1. Unzip the webtier.war file to a directory called webtier.
2. Copy all of the files in the webtier/WEB-INF/lib to to the corresponding WEB-INF/lib directory of your LiveCycle Data Service ES web application. Do not overwrite any existing files.
3. Make a backup copy of the services-config.xml file WEB-INF/flex directory of your LiveCycle Data Service ES web application.
3. With the exception of the services-config.xml file, copy all of the files and directories in the webtier/WEB-INF/flex directory to the corresponding WEB-INF/flex directory of your LiveCycle Data Service ES web application. Do not overwrite any existing files. In the event that you accidentally overwrite the services-config.xml file in your web application, restore it using the backup copy you created.
4. Copy the player and locale directories as well as the datavisualization.swc file from the LiveCycle Data Services ES or BlazeDS install_root/resources/frameworks/libs directory to the WEB-INF/flex/libs directory of your LiveCycle Data Service ES web application.
5. From the following web.xml sample content, add the text contained between
<!-- start from webtier web.xml -->
and
<!-- end from webtier web.xml -->
to the web.xml file in the WEB-INF directory of your LiveCycle Data Service ES or BlazeDS web application:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<display-name>LiveCycle Data Services Samples</display-name>
<description>LiveCycle Data Services Application with Samples</description>
<!-- start from webtier web.xml -->
<context-param>
<param-name>flex.class.path</param-name>
<param-value>/WEB-INF/flex/hotfixes,/WEB-INF/flex/jars</param-value>
</context-param>
<!-- end from webtier web.xml -->
<!-- Http Flex Session attribute and binding listener support -->
<listener>
<listener-class>flex.messaging.HttpFlexSession</listener-class>
</listener>
<!-- MessageBroker Servlet -->
<servlet>
<servlet-name>MessageBrokerServlet</servlet-name>
<display-name>MessageBrokerServlet</display-name>
<servlet-class>flex.messaging.MessageBrokerServlet</servlet-class>
<init-param>
<param-name>services.configuration.file</param-name>
<param-value>/WEB-INF/flex/services-config.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<servlet-name>PDFResourceServlet</servlet-name>
<display-name>Helper for retrieving dynamically generated PDF documents.</display-name>
<servlet-class>flex.samples.pdfgen.PDFResourceServlet</servlet-class>
</servlet>
<!-- start from webtier web.xml -->
<servlet>
<servlet-name>FlexMxmlServlet</servlet-name>
<display-name>MXML Processor</display-name>
<description>Servlet wrapper for the Mxml Compiler</description>
<servlet-class>flex.bootstrap.BootstrapServlet</servlet-class>
<init-param>
<param-name>servlet.class</param-name>
<param-value>flex.webtier.server.j2ee.MxmlServlet</param-value>
</init-param>
<init-param>
<param-name>webtier.configuration.file</param-name>
<param-value>/WEB-INF/flex/flex-webtier-config.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<servlet-name>FlexSwfServlet</servlet-name>
<display-name>SWF Retriever</display-name>
<servlet-class>flex.bootstrap.BootstrapServlet</servlet-class>
<init-param>
<param-name>servlet.class</param-name>
<param-value>flex.webtier.server.j2ee.SwfServlet</param-value>
</init-param>
<!-- SwfServlet must be initialized after MxmlServlet -->
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>FlexForbiddenServlet</servlet-name>
<display-name>Prevents access to *.as/*.swc files</display-name>
<servlet-class>flex.bootstrap.BootstrapServlet</servlet-class>
<init-param>
<param-name>servlet.class</param-name>
<param-value>flex.webtier.server.j2ee.ForbiddenServlet</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>FlexInternalServlet</servlet-name>
<servlet-class>flex.bootstrap.BootstrapServlet</servlet-class>
<init-param>
<param-name>servlet.class</param-name>
<param-value>flex.webtier.server.j2ee.filemanager.FileManagerServlet</param-value>
</init-param>
<load-on-startup>10</load-on-startup>
</servlet>
<!-- end from webtier web.xml -->
<servlet-mapping>
<servlet-name>MessageBrokerServlet</servlet-name>
<url-pattern>/messagebroker/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>PDFResourceServlet</servlet-name>
<url-pattern>/dynamic-pdf/*</url-patt
评论3
最新资源