How to pass an argument to mq process script (or run it background in unix)
Example:
If we would like define a process which invokes the "luke.sh" script
and would like also passes the argument "lightsaber" to luke.
=== process definition ===
DEFINE PROCESS(P1) +
DESCR ('MQ test process script') +
APPLTYPE(UNIX) +
APPLICID('/tmp/luke.sh') +
USERDATA(' ') +
ENVRDATA('lightsaber')
=== process definition ===
You must put the argument in the 'ENVRDATA' but not 'USERDATA'.
*** tip:
You can also put "&" in the ENVRDATA for the UNIX script running in the background.
DEFINE PROCESS
https://www.ibm.com/support/knowledgecenter/en/SSFKSJ_7.5.0/com.ibm.mq.ref.adm.doc/q085670_.htm
****On UNIX systems, ENVRDATA can be set to the ampersand character (&) to make the
started application run in the background.
沒有留言:
張貼留言