Example #1
0
        public void Close()
        {
            using (var @lock = m_lockScope.Writer(Timeout))
            {
                if ([email protected])
                {
                    throw new TimeoutException("Close has timed out");
                }

                m_subscribers.Clear();
            }

            if (g_traceInfo.IsVerboseEnabled)
            {
                TraceHelper.TraceVerbose(g_traceInfo, "{0} - Closed", Name);
            }
        }
Example #2
0
        public override bool Return(T item)
        {
            using (var @lock = m_lockScope.Writer(m_timeout))
            {
                if ([email protected])
                {
                    if (g_traceInfo.IsWarningEnabled)
                    {
                        TraceHelper.TraceWarning(g_traceInfo, "{0} - Return timed out", Name);
                    }

                    return(false);
                }

                return(base.Return(item));
            }
        }
Example #3
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                using (var @lock = m_lockScope.Writer(Timeout))
                {
                    if ([email protected])
                    {
                        throw new TimeoutException();
                    }

                    foreach (AbstractTopic topic in m_catalog.Values)
                    {
                        topic.Dispose();
                    }

                    m_catalog.Clear();
                }
            }
        }