示例#1
0
 public void CheckcallbackArg(Apache.Geode.Client.EntryEvent <Object, Object> ev)
 {
     if (!isWriterInvoke)
     {
         isWriterInvoke = true;
     }
     if (m_callbackArg != null)
     {
         Apache.Geode.Client.ISerializable callbkArg = (Apache.Geode.Client.ISerializable)ev.CallbackArgument;
         if (m_callbackArg.Equals(callbkArg))
         {
             isCallbackCalled = true;
         }
     }
 }
示例#2
0
        public override void AfterUpdate(Apache.Geode.Client.EntryEvent <Object, Object> ev)
        {
            m_updates++;
            m_lastKey   = (Apache.Geode.Client.ICacheableKey)ev.Key;
            m_lastValue = (Apache.Geode.Client.ISerializable)ev.NewValue;
            CheckcallbackArg(ev);

            string keyString = m_lastKey.ToString();

            WriteLog("TallyListener update - key = \"{0}\", value = \"{1}\"",
                     keyString, m_lastValue.ToString());

            if ((!m_ignoreTimeout) && (keyString.IndexOf("timeout") >= 0))
            {
                WriteLog("TallyListener: Sleeping 10 seconds to force a timeout.");
                Thread.Sleep(10000); // this should give the client cause to timeout...
                WriteLog("TallyListener: done sleeping..");
            }
        }
示例#3
0
 public void SetCallBackArg(Apache.Geode.Client.ISerializable callbackArg)
 {
     m_callbackArg = callbackArg;
 }