
public abstract class GlueJobStatusCheck extends Object
»ç¿ë¿¹#1String JobKey = ... ;//sample1.job001 GlueJobDefinition jobDefinition = ...; //new GlueJobDefinition( "-1", JobKey ); String serverAddress = ...; //http://192.168.41.141:8805 GlueJobEventSender sender = ...;// GlueStaticContext.getBeanFactory().getBeanObject( "jobEventSender", GlueJobEventSender.class ); String historyId = sender.sendJobEvent( def, serverAddress + "/scheduler" ); String status = GlueJobStatusCheck.getJobStatus(serverAddress, historyId, JobKey ); »ç¿ë¿¹#2String JobKey = ... ;//sample1.job001 String serverAddress = ...; //http://192.168.41.141:8805 String ids = GlueJobStatusCheck.getJobHistoryIdsByJobKey(serverAddress, JobKey ); String[] historyIds = ids.split( "," ); for( String historyId : historyIds ){ String status = GlueJobStatusCheck.getJobStatus(serverAddress, historyId, JobKey ); } 
HttpClient, 
PostMethod| Constructor and Description | 
|---|
GlueJobStatusCheck()  | 
| Modifier and Type | Method and Description | 
|---|---|
static String | 
getJobHistoryIdsByJobKey(String url,
                        String jobKey)  | 
static String | 
getJobHistoryIdsByJobKey(String url,
                        String jobKey,
                        String ip)  | 
static String | 
getJobHistoryIdsByJobKey(String url,
                        String jobKey,
                        String ip,
                        int retryCount)  | 
static String | 
getJobStatus(String url,
            String requestId,
            String jobKey)  | 
static String | 
getJobStatus(String url,
            String requestId,
            String jobKey,
            String ip)  | 
static String | 
getJobStatus(String url,
            String requestId,
            String jobKey,
            String ip,
            int retryCount)  | 
public GlueJobStatusCheck()
public static String getJobStatus(String url, String requestId, String jobKey)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓrequestId - Job History ID. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ. requestId °¡ À¯È¿ÇÑÁö üũÇϴµ¥ »ç¿ëµÊ.public static String getJobStatus(String url, String requestId, String jobKey, String ip)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓ.requestId - Job History ID. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ. requestId °¡ À¯È¿ÇÑÁö üũÇϴµ¥ »ç¿ëµÊ.ip - LocalHost ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.public static String getJobStatus(String url, String requestId, String jobKey, String ip, int retryCount)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓ.requestId - Job History ID. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ. requestId °¡ À¯È¿ÇÑÁö üũÇϴµ¥ »ç¿ëµÊ.ip - LocalHost ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.retryCount - HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà ½ÇÆÐ½Ã Àç½Ãµµ Ƚ¼öÀÓ.public static String getJobHistoryIdsByJobKey(String url, String jobKey)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.public static String getJobHistoryIdsByJobKey(String url, String jobKey, String ip)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.ip - LocalHost ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.public static String getJobHistoryIdsByJobKey(String url, String jobKey, String ip, int retryCount)
url - GlueJobScheduler Server ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà URLÀÓ.jobKey - JobKey. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.ip - LocalHost ÁÖ¼Ò. ³»ºÎÀûÀ¸·Î NameValuePair À¸·Î »ý¼ºµÇ¼ setRequestBody()·Î Àü´ÞµÊ.retryCount - HttpClient ¸¦ ÅëÇØ PostMethod ½ÇÇà ½ÇÆÐ½Ã Àç½Ãµµ Ƚ¼öÀÓ.Copyright © 2017–2021 POSCO ICT. All rights reserved.