public DefaultQueueContext(IServiceProvider serviceProvider, ILogger <DefaultQueueContext> logger, IServiceScopeFactory scope, IOptions <SendGridConfig> sendgrid) : base(serviceProvider)
        {
            _logger   = logger;
            _scope    = scope;
            _sendgrid = sendgrid.Value;

            //register queue
            AddQueueProcFunc(QName_Hello, ProcFunc_Hello);

            //demo subscribe
            SubscribeEvent(QName_Hello, EventListener);
        }
示例#2
0
 public AuthMessageSender(IOptions <SendGridConfig> sendgrid, ILogger <AuthMessageSender> log)
 {
     _sendgrid = sendgrid.Value;
     _log      = log;
 }