<%@ page contentType="text/html; charset=euc-kr" %>

<%@ page import="java.io.*" %>
<%@ page import="java.util.*" %>

<%@ page import="org.kldp.ebmsh.message.packaging.EbxmlMessage" %>
<%@ page import="org.kldp.ebmsh.message.util.Serializer" %>

<%@ page import="org.kldp.ebmsh.config.EbmsConstants" %>

<%@ page import="org.kldp.ebmsh.application.NonBlockingApplicationProcesser" %>

<%@ page import="org.kldp.ebmsh.tracker.Tracker" %>

<jsp:directive.page import="org.kldp.ebmsh.moniter.permission.PermissionManager"/>

<%@ include file="/authorize/loginCheck.jsp" %>

<%@ include file="/setup/setupCheck.jsp" %>

<%
	String messageId = request.getParameter("messageId");
	String messagePath = request.getParameter("messagePath");
	
	FileInputStream fin = new FileInputStream(EbmsConstants.messagePath + new File(messagePath));
	EbxmlMessage msg = Serializer.deserialize(fin);

	fin.close();

	Tracker.tracking(messageId, new Date(), "사용자가 재처리를 실행했습니다", "사용자가 재처리를 실행했습니다");

	new NonBlockingApplicationProcesser().process(msg);
%>

<script language="JavaScript">
	alert('메시지 재처리를 요청했습니다');
	
	history.go(-1);
</script>