public void ExtcuteEffective() { try { string action = this.Request["action"]; if (string.IsNullOrEmpty(action) || !action.Equals("effective")) { this.Alert("SyncManager", "参数非法,同步数据失败,请联系管理员"); return; } bool result = new SyncManagerBLL().EffectiveSync(); if (result.Equals(true)) { this.Alert("实时同步成功"); } else { this.Alert("实时同步失败,请联系管理员"); } } catch { //XSS攻击? this.Alert("SyncManager", "操作失败,发生未知错误"); } }
private bool ExecuteSyncInterface() { bool result = new SyncManagerBLL().NewRedis(); if (result) { result = new SyncManagerBLL().EffectiveSync(); return(result); } return(result); }
public void SyncDeveloperData() { try { bool result = new SyncManagerBLL().DeveloperSync(); Response.Write(string.Format("Result:{0}", result)); } catch (Exception ex) { Response.Write("Result:false " + ex.ToString()); } }
protected void Button1_Click(object sender, EventArgs e) { bool result = new SyncManagerBLL().NewRedis(); if (result.Equals(true)) { this.Alert("缓存同步成功"); } else { this.Alert("缓存同步失败"); } }
/// <summary> /// 调用各回调接口 /// </summary> private bool ExecuteSyncInterface() { bool result = false; //调用同步开发者信息接口 //result = new SyncManagerBLL().DeveloperSync(); //调用Redis缓存 result = new SyncManagerBLL().RedisSync(); // todo: 调用实时生效接口 result = new SyncManagerBLL().EffectiveSync(); return(result); }
/// <summary> /// 同步缓存 /// </summary> /// <param name="s"></param> /// <param name="e"></param> protected void OnRsyncStart(object s, EventArgs e) { bool result = new SyncManagerBLL().NewRedis(); if (result.Equals(true)) { string msg = "缓存同步成功"; result = new SyncManagerBLL().EffectiveSync(); if (!result) { msg += ",但通知失败"; } this.Alert(msg); } else { this.Alert("缓存同步失败"); } }
/// <summary> /// 同步缓存 /// </summary> protected void Button1_Click(object sender, EventArgs e) { bool result = new SyncManagerBLL().NewRedis(); if (result.Equals(true)) { string msg = "数据生效成功"; result = new SyncManagerBLL().EffectiveSync(); if (!result) { msg += ",但通知失败"; } this.Alert(msg); } else { this.Alert("数据生效失败"); } BindData(); }