假设workflow里有两个action节点,shell和hive,hive需要用到shell节点里的值,shell脚本如下
#!/bin/sh day=`date '+%Y%m%d%H'` echo "day:$day"
hive节点需传入day这个参数。需要用到shell节点里<capture-output/>这个属性,如下
${jobTracker} ${nameNode} mapred.job.queue.name ${queueName} ${shell} ${shell}#${shell} ${jobTracker} ${nameNode} ${apps_hdfs_home}/common/conf/hive-site.xml day=${wf:actionData('shell-118a')['day']}