Changeset 1087
- Timestamp:
- 10/15/14 14:35:29 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libIGCM/libIGCM_debug/libIGCM_debug.ksh
r1086 r1087 188 188 189 189 if [ X${initBigBro} = Xtrue ] ; then 190 #echo $(date +"%Y-%m-%dT%H:%M:%S.%N%z") > ${SUBMIT_DIR}/mail.txt 190 191 mailx -s "[TEMPORARY AMQP CHANNEL]" -a ${SUBMIT_DIR}/config.card.base64 ${mail_recipient} < ${buffer} # send buffer 191 192 rm -f $buffer ; touch ${buffer} # clear buffer … … 193 194 initBigBro=false 194 195 elif ( [ ${send_messages} -eq 1 ] || [ X${FlushAMQP} = XTRUE ] ) ; then 196 #echo $(date +"%Y-%m-%dT%H:%M:%S.%N%z") >> ${SUBMIT_DIR}/mail.txt 195 197 mailx -s "[TEMPORARY AMQP CHANNEL]" ${mail_recipient} < ${buffer} # send buffer 196 198 rm -f $buffer ; touch ${buffer} # clear buffer … … 247 249 fi 248 250 249 status=$?250 251 if [ ${status} -gt 0 ] ; then 251 252 IGCM_debug_Print 2 "IGCM_debug_Push/PopStack/ActivateBigBro : command sendAMQPMsg failed error code ${status}" … … 572 573 simuid=$(uuidgen) 573 574 IGCM_card_WriteOption ${SUBMIT_DIR}/run.card Configuration simuid ${simuid} 574 575 575 # Standard fields for the first message 576 576 genericSimulationID=$( echo "\"msgApplication\":\"monitoring\",\"msgProducer\":\"libigcm\",\"activity\":\"IPSL\",\"name\":\"${config_UserChoices_JobName}\",\"cumulPeriod\":\"${CumulPeriod}\",\"experiment\":\"${config_UserChoices_ExperimentName}\",\"space\":\"${config_UserChoices_SpaceName}\",\"model\":\"${config_UserChoices_TagName}\",\"startDate\":\"${config_UserChoices_DateBegin}\",\"endDate\":\"${config_UserChoices_DateEnd}\",\"login\":\"${LOGIN}\",\"centre\":\"${CENTER}\",\"machine\":\"${MASTER}\",\"simuid\":\"${simuid}\",\"jobuid\":\"${jobuid}\"" ) 577 # RabbitMQ message body with specific fields associated message codes treated here 578 Body=$( echo "{${genericSimulationID},\"msgCode\":\"${code}\",\"msgUID\":\"$(uuidgen)\",\"msgTimestamp\":\"$( date +"%Y-%m-%dT%H:%M:%S.%N%z" )\"}" ) 579 # Fill the rabbitMQ queue (the config.card in use will be sent) 580 IGCM_debug_sendAMQP activate 577 581 else 578 582 # RabbitMQ message code "A NEW JOB IS RUNNING PART OF A SIMULATION" 579 583 code=1000 580 #581 584 # retrieve this simulation's unique id 582 585 IGCM_card_DefineVariableFromOption ${SUBMIT_DIR}/run.card Configuration simuid 583 586 simuid=${run_Configuration_simuid} 584 585 587 # Using standard fields for message others than the first one. Still subject to change 586 588 genericSimulationID=$( echo "\"msgApplication\":\"monitoring\",\"msgProducer\":\"libigcm\",\"cumulPeriod\":\"${CumulPeriod}\",\"simuid\":\"${simuid}\",\"jobuid\":\"${jobuid}\"" ) 587 fi 588 589 # RabbitMQ message body with specific fields associated message codes treated here 590 Body=$( echo "{${genericSimulationID},\"msgCode\":\"${code}\",\"msgUID\":\"$(uuidgen)\",\"msgTimestamp\":\"$( date +"%Y-%m-%dT%H:%M:%S.%N%z" )\"}" ) 591 592 # Fill the rabbitMQ queue (the config.card in use will be sent) 593 IGCM_debug_sendAMQP activate 589 # RabbitMQ message body with specific fields associated message codes treated here 590 Body=$( echo "{${genericSimulationID},\"msgCode\":\"${code}\",\"msgUID\":\"$(uuidgen)\",\"msgTimestamp\":\"$( date +"%Y-%m-%dT%H:%M:%S.%N%z" )\"}" ) 591 # Fill the rabbitMQ queue 592 IGCM_debug_sendAMQP 593 fi 594 594 595 595 # NOT VERY NICE BUT ... IT WORKS
Note: See TracChangeset
for help on using the changeset viewer.