Beispiel #1
0
        public StorageLinkJobInfo GetJobInfo(string jobId)
        {
            jobInfo jobInfo   = _service.getJobInfo(jobId, string.Empty, 0);
            string  errorText = null;

            if (jobInfo.errInfo != null)
            {
                var sb = new StringBuilder();

                if (jobInfo.errInfo.errorMessage != null)
                {
                    sb.AppendLine("Message: " + jobInfo.errInfo.errorMessage.defaultMessage);
                }
                sb.AppendLine("File:    " + jobInfo.errInfo.errorFile);
                sb.AppendLine("Line:    " + jobInfo.errInfo.errorLine);
                sb.AppendLine("Func:    " + jobInfo.errInfo.errorFunction);

                log.Error("CSLG Exception " + sb.ToString());

                errorText = jobInfo.errInfo.errorMessage.defaultMessage;
            }

            return(new StorageLinkJobInfo(this, jobId, (int)jobInfo.progress, jobInfo.name.defaultMessage, jobInfo.description.defaultMessage, jobInfo.completedDateStamp, (StorageLinkEnums.JobState)jobInfo.jobStatus, errorText));
        }