Composing the classpath via for loop in STDENV DD is a script run by
/bin/sh and therefore the term "${APP_HOME}"/*.jar is implicitly evaluated
to the correct file names by the shell.
In contrast, just giving the classpath as a variable value does not
evaluate to the files referenced by "*". It just appends the asterisk
symbol to the variable's value -- which does not help you unless your
classes are all contained in the one file named "*" (asterisk symbol as
file name works in z/OS Unix.....however it is something you sure do not
want.).
Cheers
Michael
Von: Andrew Rowley <[email protected]>
An: [email protected],
Datum: 26.04.2017 13:04
Betreff: JZOS Java CLASSPATH
Gesendet von: IBM Mainframe Discussion List <[email protected]>
The JCL supplied with the JZOS batch launcher has a section to add jars
to the classpath:
# Add Application required jars to end of CLASSPATH
for i in "${APP_HOME}"/*.jar; do
CLASSPATH="$CLASSPATH":"$i"
done
My understanding is you should be able to use a wildcard instead and the
JVM will add all files ending with jar or JAR to the classpath,
e.g. CLASSPATH="$CLASSPATH":"${APP_HOME}"/*
but it doesn't seem to work. The classes are not found. If I display the
classpath from within the program I can see the directory including the
wildcard. If I copy and paste that entry and use it in "ls" it lists the
jars.
What an I missing? Does the z/OS JVM support the wildcard syntax (under
JZOS)?
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
_________________________
_________________________
____________________
This email has been scanned by the Symantec Email Security.cloud service.
For more information please visit http://www.symanteccloud.com
_________________________
_________________________
____________________
Basler Sachversicherungs-AG
Amtsgericht Bad Homburg v.d.H., HRB 9357 | USt-ID-Nr. DE 276021973
Basler Straße 4, 61345 Bad Homburg v.d.H.
Vorstand: Dr. Jürg Schiltknecht - Vorsitzender, Markus Jost, Ralf Stankat,
Dr. Alexander Tourneau, Julia Wiens
Aufsichtsratsvorsitzender: Peter Zutter
Basler Lebensversicherungs-AG |
Amtsgericht Hamburg, HRB 4659 | Ust-ID-Nr. DE 276021973
Ludwig-Erhard-Straße 22, 20459 Hamburg
Vorstand: Dr. Jürg Schiltknecht - Vorsitzender, Markus Jost, Ralf Stankat,
Dr. Alexander Tourneau, Julia Wiens
Aufsichtsratsvorsitzender: Peter Zutter
Basler Versicherung AG Direktion für Deutschland |
Amtsgericht Bad Homburg v.d.H., HRB 1228 | USt-ID-Nr. DE 281452875
Basler Straße 4, 61345 Bad Homburg v.d.H.
Hauptbevollmächtigter für Deutschland: Dr. Jürg Schiltknecht
Basler Leben AG Direktion für Deutschland |
Amtsgericht Bad Homburg v.d.H., HRB 1229 | Ust-ID-Nr. DE 281452875
Basler Straße 4, 61345 Bad Homburg v.d.H.
Hauptbevollmächtigter für Deutschland: Dr. Jürg Schiltknecht
______________________________________________________________________
This email has been scanned by the Symantec Email Security.cloud service.
For more information please visit http://www.symanteccloud.com
______________________________________________________________________
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN