DevPortal

What are the Various Deployment Settings?


Table of Contents


What are the Various Deployment Settings?

The Deploy Tool allows for run-time configuration of deployment properties. Configuration changes can be done either globally or for each application. Deployment settings done globally are modified in the Deploy Service (that is, the changes are made in the deploy-config.xml) and are valid across all deployments. These changes are persistent. Alternatively, deployment changes done at application level are only applied for the current deployment.

What are the Various Global Configuration Settings?

The following properties can be made to change globally:

Global properties can be set by clicking on the Settings icon on the Toolbar of the Deploy Tool.

How do I Customize Archives?

Changes made at the archive level are specific for the current application considered for deployment. However, these changes are not persisted. The following properties can be set:

Archive specific deployment properties can be set by clicking Deployment Properties in the Explore panel of the application archive.

Note: Deployment changes made at the Archive level take precedence over the Deployment Settings.

How do I Specify Deployment Settings in Pramati Deployment Descriptor?

Another way to specify archive specific deployment properties is to add an entry in the pramati-j2ee-server.xml file. A sample deployment property can be set as below:

<deployment-properties app-versioning="true" delete-previous-versions="true" forced-deployment="true">
  <jsp-files pre-compilation="true"/>
  <ejb-files retain-generated-code="true"/>
  <validation>
	<dtd-validation on-prepare="false" on-start="false"/>
	<app-validation on-prepare="true" on-start="true"/>
  <validation>
  <deployment-failure retain-files="true"/>
</deployment-properties>

How do I set EJB Properties Using Deploy Tool?

The Deploy Tool allows setting of various properties for Enterprise Java Beans at the archive level. Changes made here are made in Pramati’s deployment descriptors: pramati-or-map.xml and pramati-j2ee-server.xml. These properties are:

When an archive is opened using the Deploy Tool, the Explore panel on the left displays various components in the application archives. Clicking the EJB jar node expands the tree and lists all the beans created in this archive.

How do I set Properties for Stateful Session Beans?

For a stateful session bean, the Deploy Tool displays the following information on the right hand panel.

General

The General tab displays the following information:

Bean Information: This section contains general information about:

Deployment Information: The deployment information contains the following:

Bean Description: A general description about the bean. The bean description can be specified here.

Method Information

This tab displays a list of methods that can be selected to alter a beans state.

How do I set Properties for Stateless Session Beans?

For a stateless session bean, the Deploy Tool displays the following information on the right panel:

Bean Information: This section contains general information about:

Deployment Information: The deployment information contains the following:

Bean Description: A general description about the bean. The bean description can be specified here.

How do I set Properties for Entity Beans (Container Managed)?

For a Container Managed Entity Bean, the Deploy Tool displays the following information on the right panel, in the form of tabs.

General

The General tab displays the following information:

Bean Information: This section contains general information about:

Deployment Information: The deployment information contains the following:

Bean Description: A general description about the bean. The bean description can be specified here.

Concurrency

The Concurrency tab contains information about the concurrency policy that needs to be assigned to the selected CMP.

CMF Fields

The CMF Fields tab contains information about the O-R mapping for a particular CMP bean. For a given datasource, the associated schema is displayed in the drop-down list, and the Container Managed Fields table contains the mapping for the CMP field and the corresponding column name in the table.

Finder Queries

The Finder Queries tab contains mapping for a finder method to a corresponding query label. New queries can be created by clicking New at the lower right hand of the window. Clicking New displays a query wizard using which you can interactively create a query without having to manually code it.

Read Writing SQL Queries for EJBs -- add link for more details about the Query Wizard.

How do I set Properties for Message Driven Beans?

For a message driven bean, clicking on the Bean Properties on the explore panel on the left, displays the following tabs on the right hand panel:

General

The General tab displays all information pertaining to a particular MDB.

Bean Information: This section contains general information about:

MDBProperties

The MDBProperties tab displays the following information:

Connector Properties: This section displays the following connector properties:

A table displaying the various properties, Java types, and their values. You can select and modify these values.

How do I Migrate Local JNDI Names?

In previous service packs of Pramati Server 4.1, for beans that have local home references, the container generated a local JNDI name and bound local home with this name in Naming Service.

If there was a local reference to this bean in pramati-j2ee-server.xml corresponding to this local-ref mapping, the link-name tag used to have the remote JNDI name. The container internally used to resolve this to the actual local JNDI name before it bound the reference.

From Pramati Server 4.1 service pack 5, this assumption is removed from the container. It is now mandatory for local-reference mappings to be present in the pramati-j2ee-server.xml. Absence of local home references leaves a task remaining alert at the lower right-hand corner of the Deploy Tool. Pramati Deploy Tool now has a migration utility that does this for older archives.

How do I use Deploy Tool Logs?

Pramati Server Deploy Tool logs messages that are generated while deploying applications. These messages can be helpful while debugging or troubleshooting. By default, the log level for Deploy Tool is ‘severe’. The logs can be viewed by selecting View > View Logs from the Deploy Tool menu.

When Deploy Tool is used locally, the logs are generated in the <install_dir>/server/nodes/<node_name>/logs directory, with a name DeployTool.log. If the Deploy Tool is used for deploying application on a remote machine, the Deploy Tool logs are generated in the <current_directory>/Temp/DeployTool/logs directory.

Custom tracing can be provided to the Deploy Tool. This is mainly used in cases when you want to know specifically the path taken by the Deploy Tool at the time of deploying the application.

For example, you can specify logging information to be displayed when the Deploy Tool invokes specific packages of the Server. Again, this is mainly used for debugging purposes. A template of the trace properties can be found at <install_dir>/server/templates/consoletrace.props.

The path to the trace properties file has to be provided at the time of starting the Deploy Tool, with the following command: j2eeadmin>deploytool -tracefile path/to/consoletrace.props

The following is a sample consoletrace.props:

handlers = first
handler.first.type = file
handler.first.details = trace.log
handler.first.loglevel = all
handler.first.contexttype.packages = .,false;web,true;
web.servlet.core.DefaultHttpTask, and packages ejb, & services.naming

Trace properties are explained in the table below:

Table 1: Trace properties explained

PropertyDescription
handlersThis is just a place holder for the different handlers that are set up. All handlers that are listed specified as a comma separated list. There can be a number of handlers available doing various types of tracing according to individual settings, all of them working simultaneously.
handler.custome_handler.typeTracing can happen either to a user specified file (file) or to the console (console).
handler.custom_handler.detailsIf the handler.type had been set to file, then the filename should be specified here.
handler.custom_handler.isAbsolutePathSet this to true if the path given above is an absolute path, and false otherwise.
handler.custom_handler.appendIfFileExistsThis can be either true or false. If true, trace methods are appended at the end of the file, if it exists. If set to false, the trace file is overwritten.
handler.custom_handler.loglevelLoglevels can be specified here. The following log levels are available: event, debug, off, info, user, finer, severe, warning, all.
handler.custom_handler.contexttype.packagesAll relevant trace methods that occur in a given package are logged in the trace file. The connotation used is: <package name>, <true/false>; <packagename1>, true/false. Where package name is the name of the package to be traced (a ‘.’ (dot) denotes all packages), true/false is a boolean value associated with the package. The trace is generated if it is true. If set to false the package is ignored.
enable.debugSet this to true if debug messages should appear while tracing. Valid values are true or false.

© Pramati Technologies 2007 Runs on Pramati Server | Feedback | Legal