EPM Integration Agent를 사용하여 쓰기 되돌림하는 경우 AftExport
를 사용하여 테이블에 데이터를 삽입한 후 사후 처리 정리를 수행합니다.
다음 스크립트 예제는 쓰기 되돌림 후에 실행되는 외부 API를 호출하는 방법을 보여줍니다.
이 예제의 AftExport
이벤트는 다음을 수행합니다.
agentContextParams
맵의 콘텐츠를 인쇄합니다.EPM_APP_DATA_HOME\logs
의 프로세스 로그에 기록됩니다.EPM_APP_DATA_HOME\logs
의 프로세스 로그에 기록됩니다.EPM Integration Agent 컨텍스트 함수에 대한 자세한 내용은 EPM Integration Agent 컨텍스트 함수를 참조하십시오.
이 스크립트는 예제로만 제공되며 결함이 없다고 보증되지 않으므로 사용자는 스크립트와 관련된 질문 또는 이슈에 대해 오라클 고객지원센터에 서비스 요청을 제출할 수 없습니다.
import sys ''' After export custom script. This script will be called after the writeback finishes execution. ''' #print "Begin: AftExport.py" #print 'Event Type is: ' + event ''' Print the contents of the agentContextParams map which is an unmodifiable map. ''' #print 'JOBTYPE: ' + agentContext["JOBTYPE"] #print 'EPM_APP_DATA_HOME: ' + agentContext["EPM_APP_DATA_HOME"] #print 'WRITEBACK_DATA_FILE: ' + agentContext["WRITEBACK_DATA_FILE"] #print 'JOBID: ' + str(agentContext["JOBID"]) #print 'INTEGRATION: ' + agentContext["INTEGRATION"] #print 'LOCATION: ' + agentContext["LOCATION"] #print 'SOURCE_APPLICATION: ' + agentContext["SOURCE_APPLICATION"] #print 'TARGET_APPLICATION: ' + agentContext["TARGET_APPLICATION"] ''' Log an info message to the agent process log. This entry will be logged only to the process log in EPM_APP_DATA_HOME\logs folder and not to epmagent.log. The log entry will be created at INFO log level. ''' #agentAPI.logInfo("SAMPLE: INFO log message from script") ''' Log an severe message to the agent process log. This entry will be logged into the process log in EPM_APP_DATA_HOME\logs folder and also into epmagent.log. The log entry will be created at SEVERE log level. ''' #agentAPI.logError("SAMPLE: SEVERE log message from script") ''' Return false in case of error, which will throw an exception in the agent. ''' returnValue = 'true' #print "End: AftExport.py"