internal override void Run(string[] tokens) { using (var conn = new Symmetry.Interop.Orchestrade.ClientProxy("msuat", "orchestra", "orchestra".ConvertToSecureString())) { try { SLog.log.Debug("Attempting to connect to orchestrade..."); conn.Open(); SLog.log.Debug("...connection to orchestrade successfully opened"); //GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-01", "235959", "All:MLP", "Symmetry"); //GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-01", "235959", "All:SMF&MLP", "Symmetry"); GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-06", "235959", "_SYM_FGHK:Today's Trades", "Symmetry"); //GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-03", "235959", "All:MLP", "Symmetry"); //GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-03", "235959", "TEST", "Symmetry"); //GetRiskReportFXExposure.GetRiskReportAndSaveData(conn, "2015-01-02", "235959", "All:SMF&MLP", "Symmetry"); } catch (Exception ex_) { SLog.log.Error("Error opening connection to orchestrade", ex_); } } }
public void Run(String[] args) { if ((args != null) && (args[5] != null) && (args[5].Equals("msprod") || args[5].Equals("msuat") || args[5].Equals("mstest"))) { using (var conn = new Symmetry.Interop.Orchestrade.ClientProxy(args[5], "orchestra", "orchestra".ConvertToSecureString())) { try { SLog.log.Debug("Attempting to connect to orchestrade..."); conn.Open(); SLog.log.Debug("...connection to orchestrade successfully opened"); if ((args!=null) && (args.Length > 5)) { GetRiskReportAndSaveData(conn, args[1], args[2], args[3], args[4]); } else { throw new Exception("Expect 5 arguments in Input. dailymlpfxrecdata {ValuationDate} {runTime} {strFilter} {setupName} {env}. E.g. dailymlpfxrecdata msuat 2015-01-01 235959 \"All:SMF&MLP\" Symmetry msuat"); } } catch (Exception ex_) { SLog.log.Error("Error opening connection to orchestrade", ex_); } } } else { SLog.log.Error("Please check the OT environment you choosed."); } }
internal override void Run(string[] tokens) { if (tokens.Length != 5) { SLog.log.InfoFormat(Usage); return; } var runDate = DateTime.ParseExact(tokens[1], "yyyy-MM-dd", CultureInfo.InvariantCulture); var env = tokens[2]; var user = tokens[3]; var pw = tokens[4].ConvertToSecureString(); using (var conn = new Symmetry.Interop.Orchestrade.ClientProxy(env, user, pw)) { try { SLog.log.Debug("Attempting to connect to orchestrade..."); conn.Open(); SLog.log.Debug("...connection to orchestrade successfully opened"); GetOtStrategyMapping.GetOtStrategyMapAndSaveData(conn, runDate.Year*10000 + runDate.Month*100 + runDate.Day); //runDate to int } catch (Exception ex) { SLog.log.Error("Error opening connection to orchestrade", ex); } } }
public void Run(DateTime runDate, string env, string user, SecureString pw) { using (var conn = new Symmetry.Interop.Orchestrade.ClientProxy(env, user, pw)) { try { SLog.log.Debug("Attempting to connect to orchestrade..."); conn.Open(); SLog.log.Debug("...connection to orchestrade successfully opened"); GetOtStrategyMapAndSaveData(conn, runDate.Year*10000 + runDate.Month * 100 + runDate.Day ); //runDate to int } catch (Exception ex_) { SLog.log.Error("Error opening connection to orchestrade", ex_); } } }
internal override void Run(string[] tokens) { if (tokens.Length != 4) { SLog.log.InfoFormat(Usage); return; } using (var conn = new Symmetry.Interop.Orchestrade.ClientProxy(tokens[1], tokens[2], tokens[3].ConvertToSecureString())) { try { SLog.log.Debug("Attempting to connect to orchestrade..."); conn.Open(); SLog.log.Debug("...connection to orchestrade successfully opened"); } catch (Exception ex_) { SLog.log.Error("Error opening connection to orchestrade", ex_); } } }