WebLogic Server (WLS) 7.0
Pet Store Sample Application
HP NonStop Server Platform Guide for WebLogic Server—525779-001
6-7
Running Pet Store in Another Location
BEA’s standard mechanism for creating a private copy of Pet Store is the Configuration
Wizard, dmwiz.sh. To run this wizard on the NonStop server, see the BEA
documentation on running the Wizard in Console mode.
Another way to run a private copy of Pet Store is to copy existing sample files and
change values in them.
1. Create your own directories samples/server, that is, directory server
containing directory samples. For example:
ksh [146] MYSAMPLES=~/mywls/samples/server
ksh [147] mkdir -p $MYSAMPLES/src $MYSAMPLES/stage
2. Copy three directories from the installed WebLogic Server samples to the directory
you just created. For example:
ksh [148] export WL_HOME=/usr/bea/weblogic700
ksh [149] cd $WL_HOME/samples/server
ksh [150] cp -rp config $MYSAMPLES
ksh [151] cp -rp src/petstore $MYSAMPLES/src
ksh [152] cp -rp stage/common stage/petstore $MYSAMPLES/stage
3. Remove files that might be left over after Pet Store was run in the installed
WebLogic Server location. These files might interfere with the operation of your
private copy of Pet Store. The cleanPetStore.sh script is supplied to do this.
For example:
ksh [153] cd $MYSAMPLES/config/petstore
ksh [154] . ./cleanPetStore.sh
4. Set and export shell variables with values for your private copy of Pet Store and
run the alterPetStore.sh script, which changes files to use these values. For
example:
ksh [155] export NEW_SAMPLES_HOME=~/mywls/samples
ksh [156] export NEW_PORT=20001
ksh [157] export NEW_SPORT=20002
ksh [158] export NEW_XARES=mystore
ksh [159] cd $MYSAMPLES/config
ksh [160] petstore/alterPetStore.sh */*
NEW_SAMPLES_HOME=/h/user/mywls/samples
NEW_PORT=20001
NEW_SPORT=20002
NEW_XARES=mystore
Old string = /usr/bea/weblogic700/samples
New string = /h/user/mywls/samples
Changing examples/config.xml
Changing examples/pointbase.ini
Changing examples/setExamplesEnv.sh
Changing examples/startExamplesServer.sh
Changing petstore/config.xml
Changing petstore/config.xml_BEA
Changing petstore/config.xml_HPNS
Changing petstore/pointbase.ini