CentraSite Documentation : CentraSite Administrator’s Guide : Suite Usage Aspects : Using CentraSite with ARIS : Activating the Lifecycle Models and Design/Change-Time Policies That ARIS Uses : Activating the ARIS-Related LCMs and Policies in CentraSite : Creating a Script File for Activating the ARIS LCM and Policies
Creating a Script File for Activating the ARIS LCM and Policies
The ActivatePoliciesForARIS utility is a Java class whose main() method executes when you execute ActivatePoliciesForARIS from the command line. To ensure that the CLASSPATH and other environment variables are set properly when you execute this utility, you must create a script file that calls ActivatePoliciesForARIS as described below.
Creating a Script File for Windows (a .bat File)
Create a script file that looks as follows, if CentraSite is running under Windows.
@echo off
set JAVAEXE=fullPathToJava.exeset REDIST=CentraSiteHomeDirectory\redist
set ARISPATH=CentraSiteHomeDirectory\rts\aris
set BASEDIR=%~dp0
cd /d %REDIST%
 
REM build CLASSPATH with all files from jar directory
set LOCAL_CLASSPATH=
for %%I in (".\*.jar") do call
"CentraSiteHomeDirectory\bin\cfg\lcp.cmd" %%I
 
set BASEDIR=%~dp0
cd /d %ARISPATH%
set ARIS_CLASSPATH=
for %%I in ("%ARISPATH%\*.jar") do call
"CentraSiteHomeDirectory\bin\cfg\lcp.cmd" %%I
 
set LOCAL_CLASSPATH=%LOCAL_CLASSPATH%;%ARIS_CLASSPATH%
cd /d %REDIST%
 
%JAVAEXE%
-cp %LOCAL_CLASSPATH% com.centrasite.aris.util.ActivatePoliciesForARIS %*
cd /d %BASEDIR%
Example
@echo off
REM
REM Run ARIS LCM and Policy Activator
REM
set JAVAEXE=D:\Fix7\CentraSiteGE7\jdk1.5.0_12\bin\java
set REDIST=C:\SoftwareAG\CentraSite\redist
set ARISPATH=C:\SoftwareAG\CentraSite\rts\aris
set BASEDIR=%~dp0
cd /d %REDIST%
 
REM build CLASSPATH with all files from jar directory
set LOCAL_CLASSPATH=
for %%I in (".\*.jar")
do call "C:\SoftwareAG\CentraSite\bin\cfg\lcp.cmd" %%I
 
set BASEDIR=%~dp0
cd /d %ARISPATH%
set ARIS_CLASSPATH=
for %%I in ("%ARISPATH%\*.jar") do call
"C:\SoftwareAG\CentraSite\bin\cfg\lcp.cmd" %%I
 
set LOCAL_CLASSPATH=%LOCAL_CLASSPATH%;%ARIS_CLASSPATH%
cd /d %REDIST%
 
%JAVAEXE% -cp %LOCAL_CLASSPATH%
com.centrasite.aris.util.ActivatePoliciesForARIS %*
cd /d %BASEDIR%
Creating a Script File for Unix (C-Shell Script)
Create a script file that looks as follows if CentraSite is running under Unix.
set javaexe="fullPathToJava.exe"
set redist="CentraSiteHomeDirectory/redist"
set arispath="CentraSiteHomeDirectory/aris"
set mainjar="CentraSiteARISIntegration.jar"
set delim='\:'
cd "$redist"
set cl=""
foreach j ( `ls *.jar` )
if ($cl != "") set cl=${cl}${delim}
set cl=${cl}${j}
end
set delim='\:'
cd "$arispath"
set acl=""
foreach j ( `ls *.jar` )
if ($acl != "")
set acl=${acl}${delim}
set acl=${acl}${j}
end
setenv CLASSPATH ${mainjar}${delim}${cl}${acl}
cd "$redist"
$javaexe com.centrasite.aris.util.ActivatePoliciesForARIS $*
Example
#!/bin/csh
#
# Run ARIS LCM and Policy Activator
#
set javaexe="/.../softwareag/cjp/v16/bin/java"
set redist="/.../softwareag/CentraSite/redist"
set arispath="/.../softwareag/CentraSite/rts/aris"
set mainjar="CentraSiteARISIntegration.jar" set delim='\:'
# build CLASSPATH with all files from jar directory
cd "$redist"
set cl=""
foreach j ( `ls *.jar` )
if ($cl != "") set cl=${cl}${delim}
set cl=${cl}${j}
end
set delim='\:'
cd "$arispath"
set acl=""
foreach j ( `ls *.jar` )
if ($acl != "") set acl=${acl}${delim}
set acl=${acl}${j}
end
setenv CLASSPATH ${mainjar}${delim}${cl}${acl}
cd "$redist"
$javaexe com.centrasite.aris.util.ActivatePoliciesForARIS $*
Copyright © 2005-2015 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback