public boolean spooler_process_after(boolean arg0) throws Exception {
if (!arg0) return arg0;
SOSConnection conn = null;
SOSSchedulerLogger log = null;
Variable_set parameters = null;
String host = null;
String remoteDir = null;
try{
parameters = spooler.create_variable_set();
if(spooler_task.params() != null) parameters.merge(spooler_task.params());
if (spooler_job.order_queue() != null)parameters.merge(spooler_task.order().params());
SOSFTPHistory.debugParams(parameters, spooler_log);
if(parameters != null && parameters.count() > 0){
if (parameters.value("ftp_result_files") == "0"){
spooler_log.debug9("no files were received");
}
else{
host = parameters.value("ftp_host");
remoteDir = parameters.value("ftp_remote_dir");
if(host != null && host.length() > 0 && remoteDir != null && remoteDir.length() > 0){
try{
String[] files = parameters.value("ftp_result_filepaths").split( ";" );
log = new SOSSchedulerLogger(spooler_log);
conn = SOSFTPHistory.getConnection(spooler, conn, parameters, log);
for (int i=0; i<files.length; i++){
fillPosition(conn,host,remoteDir,files[i]);
}