public Tuple <RemoteResult, SelectSearchResult> SelectQuery(SelectDescription description) { return(SendFunc <Tuple <RemoteResult, SelectSearchResult>, ICommonNetReceiverWriterForCollector>( api => api.SelectQuery(description), e => new Tuple <RemoteResult, SelectSearchResult>(new ServerNotAvailable(Server), null), NetLogHelper.GetLog(description))); }
public RemoteResult SendSync(NetCommand command) { return(SendFunc <RemoteResult, ICommonNetReceiverForDb>( api => api.SendSync(command), e => new ServerNotAvailable(Server), NetLogHelper.GetLog(command))); }
public RemoteResult ProcessSync(InnerData data) { return(SendFunc <RemoteResult, ICommonNetReceiverWriterForWrite>( api => api.ProcessSync(data), e => new ServerNotAvailable(Server), NetLogHelper.GetLog(data))); }
public UserTransaction GetTransaction(UserTransaction transaction) { return(SendFunc <UserTransaction, ICommonNetReceiverForProxy>( api => api.GetTransaction(transaction), e => null, NetLogHelper.GetLog(transaction))); }
public RemoteResult TransactionAnswerResult(Transaction transaction) { return(SendFunc <RemoteResult, ICommonNetReceiverForDb>( api => { api.TransactionAnswer(transaction); return new SuccessResult(); }, e => new ServerNotAvailable(Server), NetLogHelper.GetLog(transaction))); }
public RemoteResult SendASyncWithResult(NetCommand command) { return(SendFunc <RemoteResult, ICommonCommunicationNet>( api => { api.SendASync(command); return new SuccessResult(); }, e => new ServerNotAvailable(Server), NetLogHelper.GetLog(command))); }
public RemoteResult RollbackData(InnerData data) { return(SendFunc <RemoteResult, ICommonNetReceiverWriterForWrite>( api => { api.Rollback(data); return new SuccessResult(); }, e => new ServerNotAvailable(Server), NetLogHelper.GetLog(data))); }
public InnerData ReadOperation(InnerData data, out RemoteResult result) { RemoteResult res = null; var ret = SendFunc <InnerData, ICommonNetReceiverWriterForWrite>( api => { var r = api.ReadOperation(data); res = new SuccessResult(); return(r); }, e => { res = new ServerNotAvailable(Server); return(null); }, NetLogHelper.GetLog(data)); result = res; return(ret); }
public RemoteResult ProcessData(InnerData data) { return(SendFunc <RemoteResult, ICommonNetReceiverForProxy>( api => { api.Process(data); data.Transaction.PerfTimer.Complete(); PerfCounters.ProxyCounters.Instance.AllProcessPerSec.OperationFinished(); if (data.Transaction.OperationType == OperationType.Sync) { PerfCounters.ProxyCounters.Instance.SyncProcessPerSec.OperationFinished(); } else { PerfCounters.ProxyCounters.Instance.AsyncProcessPerSec.OperationFinished(); } return new SuccessResult(); }, e => new ServerNotAvailable(Server), NetLogHelper.GetLog(data))); }