Ubik Batch Server Advanced features

From UbikWiki

(Difference between revisions)
(a page with features fully detailled)
Current revision (10:09, 11 April 2009) (edit) (undo)
 

(8 intermediate revisions not shown.)

Line 1:

Line 1:

 +
[[Category:Ubik Batch Server]]
 +
= Features =
= Features =
 +
== Cold deployment ==
 +
=== What is it ===
 +
This feature enables the (re)deployment at '''Server Startup''' of one or more BARs:
 +
* If BAR is already deployed the new version is deployed
 +
* If BAR is not deployed, it is deployed. If file called “<BAR_ID>-binding.xml” is present it is used to customize Pools binding otherwise default mapping is used
 +
 +
=== What it does exactly ===
 +
At Startup, the Batch Server will do the following:
 +
 +
* If BAR with another version exists, it will be undeployed
 +
* <nowiki>If file <BAR_ID>-binding.xml exists in </nowiki>batches-cold-deploy folder it will be used
 +
* <nowiki>If file <BAR_ID>-binding.xml does not exist in </nowiki>batches-cold-deploy but exists batches-deploy it will be used
 +
* Otherwise a default binding that maps logical to same physical name will be created
 +
* The BAR will be deployed
 +
* If it succeeds:
 +
# It will appear in deployed BARs on BatchAdmin application
 +
# Success will appear in Deployment History on BatchAdmin application
 +
* If it fails:
-
==Development Mode==
+
# old BAR (if there was one) will be undeployed
-
=== Explanation: ===
+
# New BAR will not be deployed and moved to batches-deploy-failure <nowiki>and a file called <BAR File Name>.failure will be written that will contains the Failure</nowiki>
-
When development mode is enabled, Batch Server can automatically create the database and needed SQL tables by itself, so users don't have to create the database.
+
# Failure will appear in Deployment History on BatchAdmin application
-
=== How to: ===
+
=== How To ===
 +
To do this:
 +
* <nowiki>Put the bar in folder “<INSTALL_DIRECTORY>\</nowiki>batches-cold-deploy”
 +
* <nowiki>Put a file called “<BAR_ID>-binding.xml” where BAR_ID is the <display-name > in bar.xml to customize JNDI Mapping (see next paragraph)</nowiki>
-
To enable the development mode in your batch server you just have to add the following line in your config.properties (see [[Ubik_Batch_Server_Administration_Guide|installation guide]]):
+
=== JNDI Mapping Customization ===
 +
<nowiki>If you have to customize the mapping of JNDI resources (Pools), example map jdbc/masterdatas to jdbc/masterdatas_beta, you must put in the folder “<INSTALL_DIRECTORY>\</nowiki>batches-cold-deploy<nowiki>” a file called “<BAR_ID>-binding.xml” where BAR_ID is the <display-name > in bar.xml.</nowiki>
-
config.propertie:
+
Example:
-
...
+
If you BAR_ID is “STCOM_BATCH”, you will put a file called STCOM_BATCH-binding.xml that contains:
-
DEVELOPMENT_MODE=true
+
<source lang="xml" >
 +
<?xml version="1.0" encoding="UTF-8"?>
 +
<!DOCTYPE bar-resources
 +
PUBLIC "-//Ubik-Ingenierie //DTD BAR Binding Resource Configuration 1.0//EN"
 +
"http://www.ubik-ingenierie.com/consolebatch/config/bar-binding.dtd">
 +
<bar-resources>
 +
<bar-resource nameinbar="jdbc/masterdatas" boundname="jdbc/masterdatas_vbeta" />
 +
<bar-resource nameinbar="jdbc/stcom" boundname="jdbc/stcom" />
 +
</bar-resources></source>
-
This feature only works with an HSQLDB database, so you have to configure your datasource.xml like this:
 
-
Datasource.xml:
 
-
...
 
-
<ResourceParams name="jdbc/console">
 
-
<parameter>
 
-
<name>username</name>
 
-
<value>sa</value>
 
-
</parameter>
 
-
<parameter>
 
-
<name>isPasswordEncrypted</name>
 
-
<value>false</value>
 
-
</parameter>
 
-
<parameter>
 
-
<name>driverClassName</name>
 
-
<value>org.hsqldb.jdbcDriver</value>
 
-
</parameter>
 
-
<parameter>
 
-
<name>url</name>
 
-
<value><![CDATA[jdbc:hsqldb:file:C:\jdbc\hsql\console\consoleHSQL2]]></value>
 
-
</parameter>
 
-
<parameter>
 
-
<name>validationQuery</name>
 
-
<value><![CDATA[select 1 from INFORMATION_SCHEMA.SYSTEM_USERS]]></value>
 
-
</parameter>
 
-
<parameter>
 
-
<name>testOnBorrow</name>
 
-
<value>true</value>
 
-
</parameter>
 
-
...
 
-
Note: the jdbc url parameter is like this: jdbc:hsqldb:file:$DIRECTORY/$DATABASE_NAME
 
-
You juste have to ensure that $DIRECTORY is readable because the HSQL database will be created in it.
+
== SNMP Alert System==
 +
Version 5.1.0.0 ships a new Alert implementation system based on SNMP traps.
 +
To configure it, add an SNMP (Simple network management protocol) extension in extension-manager.xml file.
-
...
+
=== Example configuration ===:
-
starting naming service
+
<source lang="xml">
-
naming service started
+
<extension className="com.ubikingenierie.console.snmp.SnmpConfiguratorExtension" >
-
starting connector ...
+
<set-property property="enterpriseOID" value=".1.3.6.1.4.1.107.118"></set-property>
-
connector started ...
+
<set-property property="targetSnmpHost" value="127.0.0.1"></set-property>
-
server started ...
+
<set-property property="targetSnmpPort" value="162"></set-property>
-
Development mode actived...
+
<set-property property="errorOid" value=".1.3.6.1.4.1.107.191.1.43"></set-property>
-
Starting database creation script for development mode...
+
<set-property property="errorCode" value="31"></set-property>
-
Database creation succeded for development mode
+
<set-property property="errorSeverity" value="72"></set-property>
-
...
+
<set-property property="warningOid" value=".1.3.6.1.4.1.107.191.1.44"></set-property>
 +
<set-property property="warningCode" value="32"></set-property>
 +
<set-property property="warningSeverity" value="74"></set-property>
 +
<set-property property="messagePrefix" value="TST"></set-property>
 +
<set-property property="textMessageMaxLength" value="250"></set-property>
 +
<set-property property="additionalInfoMaxLength" value="250"></set-property>
 +
</extension>
 +
</source>

Current revision


Contents

Features

Cold deployment

What is it

This feature enables the (re)deployment at Server Startup of one or more BARs:

  • If BAR is already deployed the new version is deployed
  • If BAR is not deployed, it is deployed. If file called “<BAR_ID>-binding.xml” is present it is used to customize Pools binding otherwise default mapping is used

What it does exactly

At Startup, the Batch Server will do the following:

  • If BAR with another version exists, it will be undeployed
  • If file <BAR_ID>-binding.xml exists in batches-cold-deploy folder it will be used
  • If file <BAR_ID>-binding.xml does not exist in batches-cold-deploy but exists batches-deploy it will be used
  • Otherwise a default binding that maps logical to same physical name will be created
  • The BAR will be deployed
  • If it succeeds:
  1. It will appear in deployed BARs on BatchAdmin application
  2. Success will appear in Deployment History on BatchAdmin application
  • If it fails:
  1. old BAR (if there was one) will be undeployed
  2. New BAR will not be deployed and moved to batches-deploy-failure and a file called <BAR File Name>.failure will be written that will contains the Failure
  3. Failure will appear in Deployment History on BatchAdmin application

How To

To do this:

  • Put the bar in folder “<INSTALL_DIRECTORY>\batches-cold-deploy”
  • Put a file called “<BAR_ID>-binding.xml” where BAR_ID is the <display-name > in bar.xml to customize JNDI Mapping (see next paragraph)

JNDI Mapping Customization

If you have to customize the mapping of JNDI resources (Pools), example map jdbc/masterdatas to jdbc/masterdatas_beta, you must put in the folder “<INSTALL_DIRECTORY>\batches-cold-deploy” a file called “<BAR_ID>-binding.xml” where BAR_ID is the <display-name > in bar.xml.

Example: If you BAR_ID is “STCOM_BATCH”, you will put a file called STCOM_BATCH-binding.xml that contains:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE bar-resources 
     PUBLIC "-//Ubik-Ingenierie //DTD BAR Binding Resource Configuration 1.0//EN" 
     "http://www.ubik-ingenierie.com/consolebatch/config/bar-binding.dtd">
<bar-resources>
<bar-resource nameinbar="jdbc/masterdatas" boundname="jdbc/masterdatas_vbeta" />
<bar-resource nameinbar="jdbc/stcom" boundname="jdbc/stcom" />
</bar-resources>



SNMP Alert System

Version 5.1.0.0 ships a new Alert implementation system based on SNMP traps. To configure it, add an SNMP (Simple network management protocol) extension in extension-manager.xml file.

=== Example configuration ===:

<extension className="com.ubikingenierie.console.snmp.SnmpConfiguratorExtension" >
      <set-property property="enterpriseOID" value=".1.3.6.1.4.1.107.118"></set-property>
      <set-property property="targetSnmpHost" value="127.0.0.1"></set-property>
      <set-property property="targetSnmpPort" value="162"></set-property>
      <set-property property="errorOid" value=".1.3.6.1.4.1.107.191.1.43"></set-property>
      <set-property property="errorCode" value="31"></set-property>
      <set-property property="errorSeverity" value="72"></set-property>
      <set-property property="warningOid" value=".1.3.6.1.4.1.107.191.1.44"></set-property>
      <set-property property="warningCode" value="32"></set-property>
      <set-property property="warningSeverity" value="74"></set-property>
      <set-property property="messagePrefix" value="TST"></set-property>
      <set-property property="textMessageMaxLength" value="250"></set-property>
      <set-property property="additionalInfoMaxLength" value="250"></set-property>
  </extension>
Personal tools