public void Rollback() { Console.WriteLine("Pozvan je RollBack na DMSu"); newTree = null; DMSService.Instance.Tree = oldTree; ITransactionCallback callback = OperationContext.Current.GetCallbackChannel <ITransactionCallback>(); callback.CallbackRollback("Something went wrong on DMS"); }
public void Rollback() { Console.WriteLine("Pozvan je RollBack na NMSu"); GenericDataAccess.NewNetworkModel = null; GenericDataAccess.NetworkModel = GenericDataAccess.OldNetworkModel; ResourceIterator.NetworkModel = GenericDataAccess.OldNetworkModel; ITransactionCallback callback = OperationContext.Current.GetCallbackChannel <ITransactionCallback>(); callback.CallbackRollback("Something went wrong on NMS"); }
/// <summary> /// Returning to old config file, initialize database again (deserializng from file) /// </summary> public void Rollback() { Console.WriteLine("Pozvan je Rollback na SCADA"); ITransactionCallback callback = OperationContext.Current.GetCallbackChannel <ITransactionCallback>(); ScadaModelParser parser = new ScadaModelParser(); //parser.SwapConfigs(newConfigFile, currentConfigFile); parser.DeserializeScadaModel(); // returning to old state (changed in apply delta) callback.CallbackRollback("Something went wrong on SCADA"); }