Sei sulla pagina 1di 54

Deploying the Web Intelligence Report Engine SDK

BusinessObjects Enterprise XI Windows and UNIX

Copyright

If you find any problems with this documentation, please report them to Business Objects S.A. in writing at documentation@businessobjects.com. Copyright Business Objects S.A. 2004. All rights reserved.

Trademarks

Business Objects, the Business Objects logo, Crystal Reports, and Crystal Enterprise are trademarks or registered trademarks of Business Objects SA or its affiliated companies in the United States and other countries. All other names mentioned herein may be trademarks of their respective owners. Business Objects owns the following U.S. patents, which may cover products that are offered and sold by Business Objects: 5,555,403, 6,247,008 B1, 6,578,027 B2, 6,490,593 and 6,289,352.

Patents

Contents
Chapter 1 Introduction 5 Business Objects products and J2EE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Components you need to install for J2EE web applications . . . . . . . . . 6 Custom J2EE application deployment . . . . . . . . . . . . . . . . . . . . . . . . . . 8 Chapter 2 Assembling a Web Application 11

J2EE web applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Assembling the application in a WAR file . . . . . . . . . . . . . . . . . . . . . . 12 Adding the Business Objects components . . . . . . . . . . . . . . . . . . . . . 13 Which Business Objects components does my web application need? 13 How do the Business Objects components fit together? . . . . . . . . . . . 18 Defining the web application directory structure . . . . . . . . . . . . . . . . . . . . 19 Assembling the components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 The document root directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 The /WEB-INF directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 The /WEB-INF/classes directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 The WebiApplet directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 The WebiApplet/AppletConfig directory . . . . . . . . . . . . . . . . . . . . . . . . 26 The /WEB-INF/lib directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 The /META-INF directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Generating a WAR file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Static resource files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Customizing and running a sample Ant script . . . . . . . . . . . . . . . . . . . . . . 29 Before using a custom Ant script . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 The sample Ant scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 Configuring the batch file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 Configuring the properties file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 Running the Ant script . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

Deploying the Web Intelligence Report Engine SDK iii

Contents

Chapter 3

Deploying a Web Application

39

Deploying a J2EE web application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 Static resources on a web server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Manually deploying a J2EE custom application . . . . . . . . . . . . . . . . . . 42 Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 Whats in the documentation set? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 Where is the documentation? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 Send us your feedback . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 Customer support, consulting and training . . . . . . . . . . . . . . . . . . . . . . . . . 47 How can we support you? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 Looking for the best deployment solution for your company? . . . . . . . . 48 Looking for training options? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 Useful addresses at a glance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49

iv Deploying the Web Intelligence Report Engine SDK

Deploying the Web Intelligence Report Engine SDK

Introduction

chapter

Introduction Overview

Overview
With BusinessObjects, you can create custom solutions using the Java 2 Platform Enterprise Edition (J2EE) technology. You can then deploy and run these solutions on an application server. This chapter explains which components you need to install for J2EE deployment and how they relate to each other. It also provides an overview of the steps required to deploy custom solutions.

Business Objects products and J2EE


J2EE is a platform from Sun Microsystems for building distributed enterprise applications. Among its core components are JavaServer Pages (JSPs). JSP is a technology that you can use to design and build web sites with dynamic content. JSPs use a range of related Java technologies, allowing you to build anything from a simple form up to a full business application based on Web Intelligence. JSPs contain server-side scripts embedded in HTML code using special tags. In a JSP, you write scripts in Java. These scripts can access the Web Intelligence Report Engine object model (REBean), BusinessObjects Enterprise and Crystal Reports object models. For information about creating web applications using the Web Intelligence Report Engine SDK, refer to the Customizing Web Intelligence with REBean guide. You can find information about J2EE at http://java.sun.com/j2ee/.

Components you need to install for J2EE web applications


To develop and deploy a custom solution using Web Intelligence report engine SDK you must install:

BusinessObjects Enterprise XI Java 2 SDK an application server

6 Deploying the Web Intelligence Report Engine SDK

Introduction Business Objects products and J2EE

a web server You can configure many application servers to function simultaneously as both an application server and a web server. This is known as a standalone configuration. In this case you do not need to install a separate web server.

The figure below shows how these components fit together in a J2EE custom application deployment.

Application Server Web Application Web Server JSP BusinessObjects Enterprise SDK and/or Web Intelligence SDK and/or RAS and Viewers SDK Repository Databases

Business Objects Enterprise Cluster

calls JSP page Browser Java 2 SDK

The following two sections discuss Java 2 SDKs and application servers. For information on installing BusinessObjects XI, see the BusinessObjects Enterprise Installation Guide.

Installing the Java 2 SDK


To write JSPs you need to install a Java 2 SDK which contains a suite of class libraries and debugging tools for creating JSP pages. You can download this software from the Sun web site. At the time of publishing, the correct URL is: http://www.java.sun.com/j2ee/ Tip: To check if you have a Java 2 SDK installed, open a DOS command prompt on Windows or a shell prompt on UNIX and enter the following command:

Deploying the Web Intelligence Report Engine SDK 7

Introduction Business Objects products and J2EE

java -fullversion

If you have a Java 2 SDK installed, the command returns the Java 2 SDK version.

Installing an application server


Application servers are programs that process operations for applications that run via a web server. They provide object services for JSP pages and Java servlets on the web server. Some application servers provide additional features such as load balancing, transaction management, and clustering. To install the application and web servers and configure them to work together, follow the setup and configuration procedure in the documentation provided with your application or web server.

Custom J2EE application deployment


To enable users to access a custom J2EE application, you must make it available over an intranet, an extranet or the Internet. To do so, you must deploy the assembled application on an application server. For a custom application that uses the Web Intelligence Report Engine SDK or Business Objects Enterprise SDK, you must deploy the necessary Business Objects components with the application. To do so, you must: 1. Assemble the application components and the Business Objects components in a Web Application Archive (WAR) file. J2EE web applications on page 12 discusses how to assemble the WAR file. 2. Deploy the WAR file. Deploying a J2EE web application on page 40 describes how to deploy the WAR file.

8 Deploying the Web Intelligence Report Engine SDK

Introduction Business Objects products and J2EE

Deploying the Web Intelligence Report Engine SDK 9

Introduction Business Objects products and J2EE

10

Deploying the Web Intelligence Report Engine SDK

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application

chapter

Assembling a Web Application Overview

Overview
J2EE web applications are assembled and deployed in Web Archive Files (WAR). After you collect the components of your web application in the appropriate directory structure, you must create a WAR file that you can deploy on your application server. This chapter discusses:

the components that must be contained in a web application that uses the Web Intelligence SDK or BusinessObjects Enterprise SDK or RAS and

Viewers SDK. the directory structure of a web application


where to place each component in the directory structure how to generate a WAR file.

J2EE web applications


A J2EE web application is a collection of JSP pages, classes, and other application components that can be deployed on an application server. A web application that uses the Web Intelligence SDK or Business Objects Enterprise SDK contains:

the application components These include JSP pages, HTML pages, classes and libraries. application configuration files These files describe the web application and its configuration parameters. Generally these files, such as the deployment descriptor, are standard J2EE components. Some application servers also require specific configuration files. For more information on these, refer to the documentation provided with your application server.

Business Objects components These include classes and libraries as well as applets and other components from Business Objects.

Assembling the application in a WAR file


To deploy a custom Web Intelligence application, you must archive the components in a WAR file. A WAR file is an archive file with the extension .war, in which you can bundle together the components of a web application. WAR files are defined in the Java Servlet API 2.2 specification.

12

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application J2EE web applications

To assemble all the components in a WAR file, you must: 1. Create a directory structure for the application. WAR files require a specific directory structure. For information on the directory structure, see Defining the web application directory structure on page 19. 2. 3. Add the application components in the directory structure. Add the Business Objects components. The sectionAdding the Business Objects components on page 13 discusses how to add the Business Objects components. 4. Generate a WAR file containing the directory structure and the components. Generating a WAR file on page 28 describes how to generate a WAR file.

Adding the Business Objects components


To add the Business Objects components to the application, you can do one of the following:

copy them manually from your Business Objects installation to the directory structure of the application For information on manually coping the components, see Assembling the components on page 21.

customize one of the sample Ant scripts provided with the SDK samples For information on using a sample Ant script, see Customizing and running a sample Ant script on page 29. As well as adding the Business Objects components, the sample Ant script generate the WAR file.

The Business Objects components that you must add are described in Which Business Objects components does my web application need? on page 13.

Which Business Objects components does my web application need?


A web application that uses the Web Intelligence Report Engine SDK or Business Objects Enterprise SDK and RAS and Viewers SDK must contain certain Business Objects components as well as the standard J2EE components. You can also include or customize other Business Objects components in a custom application.

Deploying the Web Intelligence Report Engine SDK 13

Assembling a Web Application J2EE web applications

The components required by the application depend on whether you are using the Web Intelligence Report Engine SDK or Business Objects Enterprise SDK and RAS and Viewers SDK. The following table lists the components and configuration files required by a web application that uses one or more of Web Intelligence Report Engine SDK or BusinessObjects Enterprise SDK or RAS and Viewers SDK. It also lists optional components available in your Business Objects installation that you can include in a custom application. Component File name Required/Optional REBean BOE RAS SDK SDK + V SDK BusinessObjects Enterprise SDK Main files for the BusinessObjects Enterprise SDK cecore.jar celib.jar ceplugins.jar cereports.jar cesession.jar ceutils.jar cexsd.jar Serialization.jar req req

Components CorbaIDL.jar required to use the bus405.jar ORB. Jakarta log4j properties file This is the configuration file for the log4j package discussed on page 15. Configuration file reader. log4j.properties.

req

req

req

Business Objects and third party configuration files opt

boconfig.jar

req

14

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application J2EE web applications

Component

File name

Required/Optional REBean BOE RAS SDK SDK + V SDK

Business Objects and third party components log4j.jar Apache logging library. This is a logging package for debugging applications. The Jakarta log4j system is part of the Jakarta project. See http:// Jakarta.apache.or g/log4j Required if wilog.jar is used. XML and XSL xalan.jar tools xercesImpl.jar These are third xml-api.jars party components for using XML and XSL that are included in the Business Objects installation. Web Intelligence components webi.jar Web Intelligence Report Engine SDK This contains the REBean package. req opt

req

Deploying the Web Intelligence Report Engine SDK 15

Assembling a Web Application J2EE web applications

Component

File name

Required/Optional REBean BOE RAS SDK SDK + V SDK

Web Intelligence cdzlet.jar servlets This contains the gateway between the Web Intelligence applet and its server. It is required only if the Java Report Panel is used. Web Intelligence ThinCadenza.jar Java Report Panel This is used if your web application creates and edits Web Intelligence reports. Note that you can also create and edit documents using the REBean package rather than using the Java Report Panel. For more information, see the Customizing Web Intelligence with REBean guide. Web Intelligence HTML cascading style sheets These files are required for the Web Intelligence HTML viewer. file_name.css

opt

opt

req

16

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application J2EE web applications

Component

File name

Required/Optional REBean BOE RAS SDK SDK + V SDK

Default settings for defaultConfig.xml the Web defaultHelp.properties Intelligence Java defaultSkin.properties report panel. Required only for the Java Report Panel. Default settings for defaultConfig.xml Web Intelligence report creation when using the Web Intelligence Report Engine SDK. JavaScript files bomenuIE.js used to provide bomenuNS.js DHTML popup menu functionality. browserDetection.js drillcontext.js drillcontextDom.js message.js image files for the file_name.gif Web Intelligence HTML viewer. These are required for all applications unless they view documents in PDF or Excel format only. Debug, trace and helper tools Web Intelligence logging utility library jtools.jar wilog.jar

opt

opt

req

req

req opt

RAS and Viewers SDK files

Deploying the Web Intelligence Report Engine SDK 17

Assembling a Web Application J2EE web applications

Component

File name

Required/Optional REBean BOE RAS SDK SDK + V SDK

RAS and Viewers SDK

MetafileRenderer.jar rasapp.jar rascore.jar ReportPrinter.jar ReportTemplate.jar CRDBJavabeansServer.jar CRDBJavaServer.jar CRDBJavaServerCommon.jar CRDBJDBCServer.jar CRDBXMLServer.jar CRDB_JavaServer.ini webireporting.jar webireporting-jsf.jar WebReportWizard.jar crlov.jar crlovexternal.jar crlovmanifest.jar dsws-bicatalog.jar dsws-common.jar dswsreportengine.jar dsws-session.jar

opt

Web Services files Web Services consumers library

How do the Business Objects components fit together?


The Business Objects components provide Web Intelligence, Crystal Reports and BusinessObjects Enterprise functionality and support utilities to the application. They also enable the applicaton to access the Business Objects cluster. The deployed web application uses the data in the Business Objects configuration files to access the Business Objects cluster.

Web Intelligence Report Engine SDK applications


The figure below shows where the Business Objects components fit in a custom Web Intelligence application deployment. It also illustrates how the components relate to the Business Objects deployment.

18

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Defining the web application directory structure

Application Server BusinessObjects Enterprise SDK Web Server RAS and Viewers SDK Web Intelligence SDK REBean Business Objects Enterprise Services WIReportServer CMS, Page Server/Cache Server, Event Server, Program Job Server, Report Job Server, FRS Repository Databases

Web Intelligence servlets Browser trace and configuration utilities XML and XSL tools

Java 2 SDK

Defining the web application directory structure


Before you assemble the application components, you must define the directory structure for the application. To do so: 1. 2. Create a root directory with an appropriate name for the application In the root directory, create the following directory structure.

Deploying the Web Intelligence Report Engine SDK 19

Assembling a Web Application Defining the web application directory structure

application_name
classes META-INF WEB-INF classes lib webiApplet AppletConfig

The table below describes the directories and discusses which components each directory must contain. Directory root directory (/application_name) Description This is the root directory of the web application, known as document root. It contains all the public files that can be served to clients. These include the JSP pages, HTML pages, image files and other static web resources. This directory should have an appropriate name for the web application. contains servlet and utility classes that are accessible to clients contains the manifest file, manifest.mf As with WEB-INF, the files located in this directory are considered as private files and are not served to clients.

/application_name/classes

/application_name/META-INF

20

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Assembling the components

Directory /application_name/WEB-INF

Description

contains all resources related to the application that are not in the document root of the application Files located in this directory are considered as private files and are not served to clients. This is where your web application deployment descriptor, web.xml is located. contains servlet and utility /application_name/WEB-INF/classes classes that are used by the web application but cannot be downloaded by clients, and configuration files for the Web Intelligence Report Engine SDK contains JAR files that are used /application_name/WEB-INF/lib by the web application but cannot be downloaded by clients For example, this is where you place Web Intelligence SDK JAR files. contains the JAR file used for the Web Intelligence Java Report Panel contains configuration files for the Web Intelligence Java Report Panel

/application_name/WebiApplet

/application_name/WebiApplet/ AppletConfig

Assembling the components


The rest of this guide is concerned with the Business Objects Enterprise SDK and Web Intelligence Report Engine SDK and associated REBean samples. After you create the directory structure, you must place the application components in the appropriate directories.

Deploying the Web Intelligence Report Engine SDK 21

Assembling a Web Application Assembling the components

This section explains where in the directory structure you must place each component. It also lists the source for each component. A component may be created by a developer or copied from an existing Business Objects product or web application. For a description of each component, see Which Business Objects components does my web application need? on page 13. Note: You can add Business Objects components to a WAR file by customizing one of the sample Ant scripts. In this case, you do not need to copy the Business Objects components into the directory structure. See Generating a WAR file on page 28.

The document root directory


You must add the application components to be accessed by the client in the document root directory. The following table lists the standard J2EE and Business Objects components that must be stored in the document root directory or an appropriate subdirectory as well as the source of each component. Component JSP files HTML files image files other static resources Note: If your application server is configured to run with a web server, you can deploy static resource files on the web server while deploying the rest of the application on the application server. See Static resource files on page 28. File name *.jsp *.html *.gif *.jpg Source created by the application developer or copied from one of the WAR files in $INSTALLDIR\Tomcat\ webapps\ businessobjects\enterprise11\ desktoplaunch\viewers\cdz

22

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Assembling the components

Component

File name

Source $INSTALLDIR\Tomcat\ webapps\ businessobjects\enterprise11 \desktoplaunch\viewers\cdz\ style\skin_default $INSTALLDIR\Tomcat\ webapps\ businessobjects\enterprise11 \desktoplaunch\viewers\cdz

Web Intelligence *.css HTML cascading style sheets These files must be accessible to the JSP pages that are using them. Web Intelligence HTML generation scripts These scripts must be accessible to the JSP pages that are using them. These script files are required for applications that view Web Intelligence documents. bomenuIE.js bomenuNS.js browserDetection.js drillcontext.js drillcontextDom.js message.js

$INSTALLDIR\Tomcat\ webapps\ businessobjects\enterprise11 \desktoplaunch\viewers\cdz\ language\xx where xx is the message language $INSTALLDIR\Tomcat\ webapps\ businessobjects\enterprise11 \desktoplaunch\viewers\cdz\ images

image files for Web *.gif Intelligence HTML generation The images directory should be in the directory where the JSP pages that are using it are stored. Note: You must not rename the Web Intelligence images directory when you copy it to an application.

Deploying the Web Intelligence Report Engine SDK 23

Assembling a Web Application Assembling the components

The /WEB-INF directory


You must add private files that are not served to clients in the /WEB-INF directory. The deployment descriptor, web.xml must be stored in the /WEB-INF directory. Web.xml can be created manually, generated by your development environment, or retrieved from an existing application and modified.

Deployment descriptor
A WAR file requires at least one deployment descriptor file, web.xml. The deployment descriptor is an XML file that describes the web application and the components it contains. Some application servers also require their own additional deployment descriptors. For information, refer to your application server documentation. Example: Deployment descriptor The following text is an example of a simple web.xml file that defines an ID, a name and a description for a web application.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/ web-app_2_2.dtd"> <web-app id="web_application_ID"> <display-name>web_application_name</display-name> <description>web_application_description</description> </web-app>

The /WEB-INF/classes directory


Application components may use servlets or classes that are not served to the client. You must place servlet and utility classes used only by the application in the /WEB-INF/classes directory.

24

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Assembling the components

The following table lists the Business Objects components that must be stored in the /WEB-INF/classes directory and where to find them. Component File name Source generated when log4j is activated

Jakarta log4j properties log4j.properties. file See also the Apache logging package listed in The WebiApplet/ AppletConfig directory on page 26. Default settings for Web defaultConfig.xml Intelligence reports created using the Web Intelligence Report Engine SDK. The defaultConfig.xml file is also deployed in the /WebiApplet/ AppletConfig directory to set default settings for the Web Intelligence Java Report Panel. See The WebiApplet/ AppletConfig directory on page 26.

%Common Program Files%/Business Objects/ 3.0/java/webiApplet

The WebiApplet directory


The WebiApplet directory contains files necessary to use the Web Intelligence Java Report panel. The following table shows the files in the directory: Component Web Intelligence Java Report Panel applet File name ThinCadenza.jar Source %CommonProgramFiles%/ Business Objects/3.0/java/ webiApplet/

Note: The WEBI-INF/classes folder also contains files necessary for the Web Intelligence Java Report Panel. See The /WEB-INF/classes directory on page 24.

Deploying the Web Intelligence Report Engine SDK 25

Assembling a Web Application Assembling the components

The WebiApplet/AppletConfig directory


Applications that use the Java Report Panel must use the configuration file in the WebiApplet/AppletConfig folder for default settings for the report panel. The following table shows the files in the directory: Component Default settings for the Web Intelligence Java Report Panel. The defaultConfig.xml file is also deployed in the /WEBI-INF/classes directory to set default settings when creating Web Intelligence documents with the Web Intelligence Report Engine SDK. See The / WEB-INF/classes directory on page 24 File name
defaultConfig.xml defaultHelp.properties defaultSkin.properties

Source %CommonProgramFiles%/ Business Objects/3.0/java/ webiApplet/AppletConfig

The /WEB-INF/lib directory


Applications may contain classes or JAR files that are not served to the client. You must place JAR files used by the application in the /WEB-INF/lib directory. The following table lists the Business Objects and third party components that must be stored in the /WEB-INF/lib directory and where to find them. Component File name Source %CommonProgramFiles%\ Business Objects\3.0\java\lib

Business cecore.jar Objects celib.jar Enterprise SDK ceplugins.jar main files cereports.jar cesession.jar ceutils.jar cexsd.jar Serialization.jar ORB components CorbaIDL.jar ebus405.jar

26

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Assembling the components

Component Web Intelligence servlets Web Intelligence Report Engine SDK Web Intelligence logging utility library Configuration file reader trace and configuration utilities Web Services Consumers Library

File name cdzlet.jar

Source

webi.jar

wilog.jar

boconfig.jar witools.jar

dsws-bicatalog.jar dsws-common.jar dsws-reportengine.jar dsws-session.jar $INSTALLDIR\Tomcat\ common\endorsed

third party XML xalan.jar and XSL tools xercesImpl.jar xml-api.jar Apache logging log4j.jar library. See also the log4j properties file listed in The /WEBINF/classes directory on page 24 Debug, trace jtools.jar and helper tools

%CommonProgramFiles%\ Business Objects\3.0\java\lib

Deploying the Web Intelligence Report Engine SDK 27

Assembling a Web Application Generating a WAR file

The /META-INF directory


The META-INF directory contains a standard manifest file, manifest.mf which can contain information about the files packaged in the WAR file. The manifest file in a WAR file is the same as manifest file contained in a JAR file. Manifest.mf is generated when you create the WAR file or you can create it manually. For information, see http://java.sun.com.

Generating a WAR file


When you have created and assembled the components of your application, you must generate the WAR file that you will deploy on your application server. You can do so using one of the following methods:

an Ant script Ant is a Java and XML based build tool from Apache that uses XML as its scripting language. As Ant is Java based, its scripts are cross-platform. You can find more information about Ant at: http://jakarta.apache.org/ant/index.html

the JAR utility included in Java 2 SDK You can find more information about the JAR utility at: http://java.sun.com

a WAR generation tool included with some application servers or development environments

Static resource files


If your application server is configured to run with a web server, you can deploy static resource files on the web server. For more on static resource files, see Static resources on a web server on page 41.

28

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Customizing and running a sample Ant script

Customizing and running a sample Ant script


Sample Ant scripts are provided with the Web Intelligence Report Engine SDK samples. You can customize these scripts to assemble the components of a web application and the required Business Objects components, and then generate a WAR file that you can deploy directly on your application server. The Ant scripts assemble the:

web application files web application configuration files Business Objects components and libraries Business Objects configuration files, if necessary

Before using a custom Ant script


You must organize the application and configuration files in a J2EE web application directory structure. This includes all of the components required by the custom application except the Business Objects components and configuration files. The Ant scripts copy the Business Objects components and libraries from your installation. For a list of the Business Objects components, see Which Business Objects components does my web application need? on page 13. All the components must be assembled in a J2EE web application directory structure required for a WAR file. This is described in Defining the web application directory structure on page 19.

Source WAR file


Instead of organizing the application and configuration files in a J2EE web application directory structure, you can archive these files in this structure in a WAR file. You can then set the appropriate property to allow the sample Ant script to access the components from the WAR file rather than the directory structure. After you run the Ant script the result is a deployable WAR file containing the application components from the source WAR file, as well as the required Business Objects components.

Deploying the Web Intelligence Report Engine SDK 29

Assembling a Web Application Customizing and running a sample Ant script

This is useful if you want to deploy the application on multiple clusters. You can copy the source WAR file to each cluster and create the deployable WAR file using the customized Ant script. This means that the deployable WAR file contains the correct Business Objects components and configuration files for the cluster. Additionally, a WAR file is more portable for copying and moving. To generate the source WAR file containing the contents of the directory, you can use the JAR utility or create an Ant script.

The sample Ant scripts


You can find the sample Ant scripts with the Web Intelligence Report Engine SDK sample. Each sample Ant script consists of three files. These are:

Assemble_WebApp.xml, the Ant script. assemble_deploy.bat, a batch file that runs the script on Windows assemble_deploy, a shell script that runs the script on UNIX sampleNameAssemblyScripts.properties, includes the application parameters used by the Ant script

An additional Ant script specific to the sample might also be provided with the sample: sampleNameAssemblyScripts.xml. Before you run the Ant script you must configure the batch and properties files with the appropriate parameters for your application and environment. You can rename the batch and property files to suit your application. If you do so, ensure that you use the new file name of the properties file in the propertyfile attribute of the ant command when you configure the batch file.

Configuring the batch file


You must ensure that the script can find your Java and Ant installations using the JAVA_HOME and ANT_HOME variables. You must also ensure the batch file can find the property file and the Ant script. To configure the batch file: 1. Open sampleNameAssemblyScripts.bat in a text editor.

30

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Customizing and running a sample Ant script

2.

Ensure the JAVA_HOME and ANT_HOME variables are set. If JAVA_HOME and ANT_HOME are not set in your environment variables, you must set JAVA_HOME and ANT_HOME to the directories where you have installed Java 2 SDK and Ant. For example:
Set JAVA_HOME=C:\jdk1.4.2 Set ANT_HOME=C:\jakarta-ant-1.5.1

If you have set JAVA_HOME and ANT_HOME in your environment variables, you must comment the JAVA_HOME and ANT_HOME variables in sampleNameAssemblyScripts.bat, by typing REM before the JAVA_HOME and ANT_HOME variables. For example:
REM Set JAVA_HOME=C:\jdk1.4.2 REM Set ANT_HOME=C:\jakarta-ant-1.5.1

3.

In the ant command, ensure that the propertyfile attribute contains the name of your property file and the buildfile attribute contains the name of the Ant script. For example:
%ANT_HOME%\\bin\\ant -propertyfile

sampleNameAssemblyScripts.properties -buildfile
Assemble_WebApp.xml %1

4.

Save and close sampleNameAssemblyScripts.bat.

Configuring the properties file


In the properties file, you must specify information about the web application and your Business Objects environment. You must define the:

location of the application components Business Objects installation directory Business Objects functionality required by the web application build properties for the deployable WAR

You can define this information by setting properties in the sampleNameAssemblyScripts.properties file. There are two types of values that you can set for these properties. A value can indicate:

a directory path, a file name or a combination of both These values indicate where the Ant script can find application components or where it must generate WAR or ZIP files. The directory path can be an absolute or relative path.

Deploying the Web Intelligence Report Engine SDK 31

Assembling a Web Application Customizing and running a sample Ant script

whether a property is set or cleared These values select an option or specify which Business Objects functionality is used by the web application. In Ant scripts a property that has a value is set. This means that to set a property, you add a value, generally a Y, to the property and ensure it is not commented. To clear a property, comment it and remove any values.

Setting properties
To set properties in sampleNameAssemblyScripts.properties: 1. 2. Open sampleNameAssemblyScripts.properties in a text editor. Add an appropriate value to indicate the location of the customized application source files. You can indicate either the location of a WAR file or the root folder of the application folder structure. To indicate the location of the source WAR file, use the following syntax:
web-app.src.file=WebApplication.war web-app.src.path=../Applications/

To indicate the root folder of the application folder structure, use:


web-app.src.dir=../src

3.

Comment the properties for which you do not want to set a value or you want to clear. To comment a property, add the # character at the beginning of the line. For example:
#webi.applet.need=

4.

After you have set all the properties for your web application, save and close sampleNameAssemblyScripts.properties.

The following sections describe the properties in sampleNameAssemblyScripts.properties. Note: The sampleNameAssemblyScripts.properties file contains properties that are not described. These properties are reserved for future use. Application property You must specify that the web application is a JSP application using the web-app.type property. To do so, ensure that web-app.type is set with the value jsp, as shown below:
web-app.type=jsp

32

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Customizing and running a sample Ant script

Deployment descriptor properties The deployment descriptor, web.xml, is an XML file that describes the web application and the components it contains. In this section, you can define values for tags in the deployment descriptor. For more information on deployment descriptors, see Deployment descriptor on page 24. The following table describes the properties that you can use to create or update tags in the deployment descriptor. Property web-app.display-name web-app.description web-app.default-document web-app.virtual-directory Description creates or updates the display-name tag with the name you set creates or updates the description tag with the description you set creates or updates the welcome-list tag with the file name you set defines the virtual directory for the web application

Example: Defining the deployment descriptor properties The following example defines a name, description and default page for the web application.
# Display name of the web application. The display-name tag of the web.xml file is created or updated with this value. web-app.display-name=WebApplication # Description of the web application. The description tag of the web.xml file is created or updated with this value. web-app.description=Custom Web Intelligence application. # Default document of the web application. This value is added to the first row in the welcome-list tag of the web.xml file if it is not already set. web-app.default-document=default.html # Virtual directory of the web application. The Configuration Tool uses this information. #web-app.virtual-directory=

The commented property is indicated in bold.

Deploying the Web Intelligence Report Engine SDK 33

Assembling a Web Application Customizing and running a sample Ant script

The location of the application components You must define the location of the application components to be included in the deployable WAR file. The application components can be stored in a directory or an archive file. The following table describes the properties that you must set Source type Directory Property web-app.src.dir Description the path for the directory where the application components are located The components in this directory are included in the WAR file generated by the Ant script. the name of the source WAR file The components in this WAR file are included in the WAR file generated by the Ant script. the directory path where the source WAR file is located

Archive files

web-app.src.file

web-app.src.path

Example: Defining the location of the application components The following example specifies that the application components are in the C:\Applications\WebApplication.war file.
# Directory path for source directories. #web-app.src.dir= # Directory path and file name for a source WAR file that contains the application components. web-app.src.file=ApplicationComponents.war web-app.src.path=C:\Applications

The commented properties are indicated in bold. The Business Objects installation directory You define the location of your Business Objects installation by setting the installation path in the businessobjects.path property. For example:
businessobjects.path=C:\Program Files\Business Objects \BusinessObjects Enterprise 11

The Ant script uses this information to find components that it must copy from your Business Objects installation. The Business Objects functionality used by the web application You can define which Business Objects functionality your web application requires. The Ant script includes the required components for the functionality in the WAR file.

34

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Customizing and running a sample Ant script

The following table lists the properties and the Business Objects functionality to which each one corresponds. Set the property for each feature that your web application requires. Property webi.sdk.need webi.applet.need bo.xml.need external-lib-path.list Component Web Intelligence Report Engine SDK Web Intelligence Java Report Panel third party XML and XSL tools If you do not want to use the third party XML and XSL tools provided with Business Objects, you can set the path and file name of the JAR files for your XML and XSL tools. The paths must be separated by a colon (:) on UNIX or a semicolon (;) on Windows as illustrated in the example on page 35.

Example: Defining the Business Objects functionality used by the web application The following example includes Web Intelligence Report Engine SDK, the Java Report Panel and the third party XML and XSL functionality in the web application.
# If the web application requires Web Intelligence SDK functionality, comment out the following line and add Y as the value. webi.sdk.need=Y # If the web application requires Web Intelligence Report Panel functionality, comment out the following line and add Y as the value. webi.applet.need=Y # If the web application requires the Java XML parser provided with Business Objects, comment out the following line and add Y as the value. bo.xml.need=Y # External library list. Include the path and file name for each JAR file separated by a semicolon (;). #external-lib-path.list=D:/xalan-j_2_3_1/bin/xml-apis.jar; D:/xalan-j_2_3_1/bin/xercesImpl.jar;D:/xalan-j_2_3_1/bin /xalan.jar

The commented properties are indicated in bold. The deployable WAR file build parameters After you have specified which components the deployable WAR file contains, you must define the properties for the WAR file.

Deploying the Web Intelligence Report Engine SDK 35

Assembling a Web Application Customizing and running a sample Ant script

The following table describes the properties that define how the Ant script performs the steps required to create a deployable WAR file. Step Property Description the path to the directory where the Ant script creates a temporary directory to use while assembling the web application Note: The temporary directory is deleted once the deployable WAR file is created unless you set the DEBUG property. DEBUG indicates that the Ant script must not delete the temporary folder the name of the deployable WAR file the path to the directory where the deployable WAR file is created

temporary directory temp.dir

WAR file created by the Ant script

web-app.dest.file web-app.dest.path

Example: Defining deployable WAR file build parameters The following example creates the C:\Applications\WARs\WebApplication.war file. It creates a temp directory in C:/WebApplication and deletes it once the WAR file is generated.
# Temporary directory name. WARNING: THIS IS A TEMPORARY DIRECTORY THAT IS DELETED ONCE THE WEB-APP FILE IS GENERATED. temp.dir=C:/WebApplication #DEBUG= # Directory path and file name to use when generating the WAR file. web-app.dest.file=WebApplication.war web-app.dest.path=C:\Applications\WARs\

Ant scripts for additional steps during assembly In some cases you might want to carry out additional steps during the assembly of an application. You can automate these additional steps by including a call in the Ant script to an additional Ant script tailored for this task.

36

Deploying the Web Intelligence Report Engine SDK

Assembling a Web Application Customizing and running a sample Ant script

You do this by setting the name of the additional Ant script in the external.build.file property, for example:
external.build.file=./SampleNameAssemblyScripts.xml

Running the Ant script


Once you have configured the batch and properties files, you can run the ant script. To do so: 1. 2. Navigate to the directory that contains assemble_deploy.bat. Run sampleNameAssemblyScripts.bat.

The script generates a deployable WAR file in the destination directory specified in the properties file. A BUILD SUCCESSFUL message is displayed when the file is generated. If an error message is displayed, verify that the information in your batch or properties files is correct.

Deploying the Web Intelligence Report Engine SDK 37

Assembling a Web Application Customizing and running a sample Ant script

38

Deploying the Web Intelligence Report Engine SDK

Deploying the Web Intelligence Report Engine SDK

Deploying a Web Application

chapter

Deploying a Web Application Overview

Overview
To enable users to access a custom solution you must make it available over an intranet, an extranet or the Internet. To do so you must deploy the assembled application on a web or application server. This chapter describes how to deploy a J2EE or ASP custom Web Intelligence solution on a web or application server.

Deploying a J2EE web application


Once you have assembled a J2EE web application, you must deploy it on an application server. To deploy a J2EE web application that uses Web Intelligence Report Engine SDK or the BusinessObjects Enterprise XI SDK or the RAS and Viewers SDK, the application must be archived in a WAR file as described in Chapter 2. As well as the standard J2EE application components and configuration files, the WAR must contain the Business Objects components and configuration files required by the application. These components are described in Which Business Objects components does my web application need? on page 13. You can manually deploy a web application directly on your application serverand web server for separate static resources. The following figure shows where the deployed custom application components are located in a J2EE environment.

40

Deploying the Web Intelligence Report Engine SDK

Deploying a Web Application Deploying a J2EE web application

Application Server Web Application (WAR file) Web Server Application components Configuration files Business Objects components and configuration files Business Objects Cluster Repository Databases

Java 2 SDK Browser

Static resources on a web server


If your application server is configured to run with a web server, you can deploy static resource files on the web server. The following figure shows where the deployed custom application components are located when you deploy the static resources on a web server.

Deploying the Web Intelligence Report Engine SDK 41

Deploying a Web Application Deploying a J2EE web application

Web Server

Application Server Web Application (WAR file)

HTML files Image files Other Static resources

Dynamic application components Configuration files Business Objects components and configuration files

Repository

Databases

Business Objects Cluster

Java 2 SDK Browser

Manually deploying a J2EE custom application


You can deploy a WAR file directly on your application server. The procedure and requirements depend on your application server. For information on how to deploy an application on your application server, see the documentation provided with the server. If your application server is configured to run with a web application and you want to deploy the static resources on the web server, you must make these components available on the web server. For information on doing so, see the documentation provided with the web server. Note: Before you manually deploy a custom application, you must have already deployed a Business Objects application, for example InfoView on the same cluster with the same application and web server configuration. This is to ensure that the application server is configured and that any Business Objects virtual directories used by the application are created.

42

Deploying the Web Intelligence Report Engine SDK

Deploying a Web Application Deploying a J2EE web application

Deploying the Web Intelligence Report Engine SDK 43

Deploying a Web Application Deploying a J2EE web application

44

Deploying the Web Intelligence Report Engine SDK

Business Objects Information Resources

appendix

Documentation and information services

Documentation and information services


Business Objects offers a full documentation set covering its products and their deployment. Additional support and services are also available to help maximize the return on your business intelligence investment. The following sections detail where to get Business Objects documentation and how to use the resources at Business Objects to meet your needs for technical support, education, and consulting.

Documentation
You can find answers to your questions on how to install, configure, deploy, and use Business Objects products from the documentation.

Whats in the documentation set?


View or download the Business Objects Documentation Roadmap, available with the product documentation at http://www.businessobjects.com/support/. The Documentation Roadmap references all Business Objects guides and lets you see at a glance what information is available, from where, and in what format.

Where is the documentation?


You can access electronic documentation at any time from the product interface, the web, or from your product CD.

Documentation from the products


Online help and guides in Adobe PDF format are available from the product Help menus. Where only online help is provided, the online help file contains the entire contents of the PDF version of the guide.

Documentation on the web


The full electronic documentation set is available to customers on the web from support web site at: http://www.businessobjects.com/support/.

Documentation on the product CD


Look in the docs directory of your product CD for versions of guides in Adobe PDF format.

46 Deploying the Web Intelligence Report Engine SDK

Customer support, consulting and training

Send us your feedback


Do you have a suggestion on how we can improve our documentation? Is there something you particularly like or have found useful? Drop us a line, and we will do our best to ensure that your suggestion is included in the next release of our documentation: documentation@businessobjects.com. Note: If your issue concerns a Business Objects product and not the documentation, please contact our Customer Support experts. For information about Customer Support visit: http://www.businessobjects.com/ support.

Customer support, consulting and training


A global network of Business Objects technology experts provides customer support, education, and consulting to ensure maximum business intelligence benefit to your business.

How can we support you?


Business Objects offers customer support plans to best suit the size and requirements of your deployment. We operate customer support centers in the following countries:

USA Australia Canada United Kingdom Japan

Online Customer Support


The Business Objects Customer Support web site contains information about Customer Support programs and services. It also has links to a wide range of technical information including knowledgebase articles, downloads, and support forums. http://www.businessobjects.com/support/

Deploying the Web Intelligence Report Engine SDK 47

Customer support, consulting and training

Looking for the best deployment solution for your company?


Business Objects consultants can accompany you from the initial analysis stage to the delivery of your deployment project. Expertise is available in relational and multidimensional databases, in connectivities, database design tools, customized embedding technology, and more. For more information, contact your local sales office, or contact us at: http://www.businessobjects.com/services/consulting/

Looking for training options?


From traditional classroom learning to targeted e-learning seminars, we can offer a training package to suit your learning needs and preferred learning style. Find more information on the Business Objects Education web site: http://www.businessobjects.com/services/training

48 Deploying the Web Intelligence Report Engine SDK

Useful addresses at a glance

Useful addresses at a glance


Address Business Objects product information http://www.businessobjects.com Product documentation http://www.businessobjects.com/ support Business Objects Documentation mailbox documentation@businessobjects.com Online Customer Support http://www.businessobjects.com/ support/ Business Objects Consulting Services http://www.businessobjects.com/ services/consulting/ Business Objects Education Services http://www.businessobjects.com/ services/training Content Information about the full range of Business Objects products. Business Objects product documentation, including the Business Objects Documentation Roadmap. Send us feedback or questions about documentation. Information on Customer Support programs, as well as links to technical articles, downloads, and online forums. Information on how Business Objects can help maximize your business intelligence investment. Information on Business Objects training options and modules.

Deploying the Web Intelligence Report Engine SDK 49

Useful addresses at a glance

50 Deploying the Web Intelligence Report Engine SDK

Index
A
Ant scripts overview 28 sample scripts 29 application servers 8 bomenuNS.js 17, 23 browserDetection.js 17, 23 bus405.jar 14 cdzlet.jar 16 cecore.jar 14, 26 celib.jar 14, 26 ceplugins.jar 14, 26 cereports.jar 14, 26 cesession.jar 14, 26 ceutils.jar 14, 26 cexsd.jar 14, 26 CorbaIDL.jar 14 CRDB_JavaServer.ini 18 CRDBJavabeansServer.jar 18 CRDBJavaServerCommon.jar 18 CRDBJDBCServerCommon.jar 18 CRDBJDBCServer.jar 18 CRDBXMLServer.jar 18 crlovexternal.jar 18 crlov.jar 18 crlovmanifest.jar 18 defaultConfig.jar 26 defaultConfig.xml 17, 25 DefaultHelp.properties 26 defaultHelp.properties 17 defaultSkin.properties 17, 26 drillcontextDOM.jar 17 drillcontextDom.js 23 drillcontext.js 17, 23 dsws-bicatalog.jar 18 dsws-common.jar 18 dswsreportengine.jar 18 dsws-session.jar 18 jtools.jar 17 log4j.jar 15, 27 log4j.properties. 14, 25 manifest.mf 28 message.js 23 MetafileRenderer.jar 18

B
Business Objects consulting services 48, 49 support services 47 training services 48, 49

C
consultants, Business Objects 48 customer support 47

D
deploying J2EE web applications manually 42 static resources 41 deployment descriptor 24 documentation feedback on 47 on product CD 46 on the web 46 roadmap 46

E
education. See training

F
feedback, on documentation 47 files Assemble_War.xml 30 boconfig.jar 14 bomenuIE.js 17, 23

Deploying the Web Intelligence Report Engine SDK 51

Index

rasapp.jar 18 rascore.jar 18 ReportPrinter.jar 18 ReportTemplate.jar 18 sampleNameAssemblyScripts.bat 30, 37 sampleNameAssemblyScripts.properties 30, 31 serialization.jar 14, 26 ThinCadenza.jar 16, 25 webi.jar 15, 27 webireporting.jar 18 webireporting-jsf.jar 18 WebiReportWizard.jar 18 web.xml 24 wilog.jar 17 wiserv.jar 27 witools.jar 27 xalan.jar 15, 27 xercesImpl.jar 15, 27 xml-api.jars 27 xml-apl.jar 15

I
information resources 45, 46

J
J2EE JAR utility 28 Java 2 SDK 7 JSP 6 overview 6 J2EE web application components deployment descriptor 24 HTML generation scripts 23 HTML generation style sheets 23 image files for HTML generation 17, 23 Jakarta log4j package 15, 27 Jakarta log4j properties file 14, 25 Java Report Panel 16 trace and configuration utilities 27 Web Intelligence SDK 15, 27 Web Intelligence servlets 16, 27 XML and XSL tools 27 J2EE web application directories

/classes 20 /META-INF 20, 28 /WebiApplet 25 /WebiApplet/AppletConfig 26 /WEB-INF 21, 24 /WEB-INF/classes 21, 24 /WEB-INF/lib 21, 26 components 2228 root directory 20, 2223 J2EE web applications assembling 2128 assembling in a WAR file 13 Business Objects components 13 components 12 deploying 4042 deployment overview 68 directory structure 1921 generating WAR files 28 requirements 6 static resources 28 Web Intelligence SDK deployment 18 Java 2 Platform Enterprise Edition see J2EE Java 2 SDK 7 Java Server Pages see JSP JSP 6

O
Online Customer Support 47

R
resources 45, 46

S
sample Ant scripts application component properties 34 Assemble_War.xml 30 Business Objects functionality properties 34 35 Business Objects installation property 34 configuring the batch file 3031 configuring the properties file 31 customizing 30

52 Deploying the Web Intelligence Report Engine SDK

Index

deployment descriptor properties 33 running 37 sampleNameAssemblyScripts.bat 30 WAR file build properties 35 support customer 47 locations 47 technical 47 web site 47

T
technical support 47 training, on Business Objects products 48

W
WAR files Ant scripts 28 deploying manually 42 deployment descriptor 24 generating 28 JAR utility 28 static resources 28 web customer support 47 getting documentation via 46 useful addresses 49 web servers 8 web sites support 47 training 48

Deploying the Web Intelligence Report Engine SDK 53

Index

54 Deploying the Web Intelligence Report Engine SDK

Potrebbero piacerti anche