Specifications

CHAPTER 3
38
Deploy checklist
Before you deploy your application, ensure that your proxy servers, firewalls, and assets are configured properly.
Adobe provides a deployment checklist that you can follow. For more information, see Deployment checklist” on
page 304.
Remove wildcards
If your application relies on assets loaded from another domain, and that domain has a crossdomain.xml file on
it, remove wildcards from that file if possible. For example, change the following:
<cross-domain-policy>
<allow-access-from domain="*" to-ports="*"/>
</cross-domain-policy>
to this:
<cross-domain-policy>
<allow-access-from domain="*.myserver.com" to-ports="80,443,8100,8080" />
</cross-domain-policy>
Also, set the value of the to-ports attribute of the allow-access-from tag to ensure that you are only allowing
necessary ports access to the resources.
Check your application for calls to the allowDomain() and allowInsecureDomain() methods. During devel-
opment, you might pass these methods a wildcard character (*), but now restrict those methods to allowing
requests only from the necessary domains.
Deploy assets to WEB-INF
In some deployments, you want to make assets such as data files accessible to the application, but not accessible
to anyone requesting the file. If you are using a J2EE-based server, you can deploy those files to a subdirectory
within the WEB-INF directory. Based on J2EE security constraints, no J2EE server can return a resource from the
WEB-INF directory to any client request. The only way to access files in this directory is with server-side code.
Precompiling source code
If you are using the Flex module for Apache and IIS, precompile MXML files, JSP files, and class files. After you
precompile your MXML and JSP files, remove the source files from the public-facing server. You should not be
using the Flex module for Apache and IIS to compile MXML file in a production environment.
To precompile MXML files, use the mxmlc compiler utility in the bin directory. For more information on using
the utility, see About the command-line compilers” on page 131.
To precompile JSP files on JRun, for example, you use the jspc precompiler utility located in the JRun bin
directory. For information on precompiling JSP files on your application server, see your application server
documentation.