void IMessageBus.RegisterAllSubscribersInAssemblies(params Assembly[] assemblies)
        {
            var bus = this as IAsyncMessageBus;

            foreach (var assembly in assemblies)
            {
                foreach (var subscriberType in assembly.GetTypes().Where(t => TypeUtils.IsAsyncSubscriber(t)))
                {
                    bus.RegisterSubscriber(subscriberType);
                }
            }
        }
        void IMessageBus.RegisterSubscriber(Type subscriberType)
        {
            if (!TypeUtils.IsAsyncSubscriber(subscriberType))
            {
                throw new EventSourcingException(
                          "类型‘{0}’不是一个有效的异步消息订阅者,订阅者必须至少具有一个标记了AsyncHandler特性的方法。",
                          subscriberType.FullName);
            }

            _messageHandlerMetaDataManager.RegisterMetaDatasFromType(
                subscriberType,
                (handler, attribute) => new HandlerMetaData {
                Handler = handler, SubscriberType = subscriberType
            });
        }