Exemple #1
0
        public static void RunAMSInline(DateTime from, DateTime to, bool isRun2Now = true)
        {
            LogHelper.InlineInfoLog(string.Format("开始RunAMSInline,From:{0},To:{1}", from.ToString("yyyy-MM-dd HH:mm:ss.ffffff"), to.ToString("yyyy-MM-dd HH:mm:ss.ffffff")));
            AMSInline inline = new AMSInline
            {
                StartTime = from,
                EndTime   = to,
                IsRun2Now = isRun2Now
            };
            InlineFileOperator fileOperator = new InlineFileOperator(inline);

            try
            {
                fileOperator.OperateFiles();
                SshOper ssh = new SshOper();
                LogHelper.InlineInfoLog("AMSInline\t" + ssh.GetResault("sh ~/eda/inline.sh"));
            }
            catch (NoQueryDataException ne)
            {
                LogHelper.InlineInfoLog(ne.Message);
            }
            catch (Exception e)
            {
                LogHelper.ErrorLog("AMSInline", e);
            }
            LogHelper.InlineInfoLog("RunAMSInline执行完毕");
        }
Exemple #2
0
        public static void RunInlineTest(DateTime from, DateTime to, bool isRun2Now = true)
        {
            LogHelper.InlineInfoLog(string.Format("开始RunInlineTest,From:{0},To:{1}", from.ToString("yyyy-MM-dd HH:mm:ss.ffffff"), to.ToString("yyyy-MM-dd HH:mm:ss.ffffff")));
            AMSInline inline = new AMSInline
            {
                StartTime = from,
                EndTime   = to,
                IsRun2Now = isRun2Now
            };
            InlineFileOperator fileOperator = new InlineFileOperator(inline);

            fileOperator.OperateFiles();
            // SshOper ssh = new SshOper();
        }
Exemple #3
0
        public static void RunAMSInline()
        {
            LogHelper.InlineInfoLog("开始RunAMSInline");
            AMSInline          inline       = new AMSInline();
            InlineFileOperator fileOperator = new InlineFileOperator(inline);

            try
            {
                fileOperator.OperateFiles();
                SshOper ssh = new SshOper();
                LogHelper.InlineInfoLog("AMSInline\t" + ssh.GetResault("sh ~/eda/inline.sh"));
            }
            catch (NoQueryDataException ne)
            {
                LogHelper.InlineInfoLog(ne.Message);
            }
            catch (Exception e)
            {
                LogHelper.ErrorLog("AMSInline", e);
            }
            LogHelper.InlineInfoLog("RunAMSInline执行完毕");
        }