Exemplo n.º 1
0
        public EmailProvider(StatelessServiceContext context)
            : base(context)
        {
            var nodeContext = FabricRuntime.GetNodeContext();

            this.configuration     = new ServiceConfiguration(nodeContext, context.CodePackageActivationContext);
            this.storeFactory      = new EmailStoreFactory(configuration.DefaultConnectionString);
            this.billingAgent      = new BillingAgent();
            this.metricManager     = new MetricManager(configuration);
            this.credentialManager = new CredentialManager(this.storeFactory);

            this.reportManager = new ReportManager(
                nodeContext.NodeName,
                this.storeFactory,
                this.configuration,
                this.billingAgent,
                this.metricManager,
                this.credentialManager);

            this.engine = new EmailEngine(
                this.storeFactory,
                this.configuration,
                this.metricManager,
                this.credentialManager);
        }
Exemplo n.º 2
0
 static EmailManager()
 {
     EmailEngine = ContainerManager.Resolve <IEmailEngine>();
     if (EmailEngine == null)
     {
         EmailEngine = new NetEmailEngine();
     }
 }
Exemplo n.º 3
0
        public OperationController(
            IEmailStoreFactory factory,
            IEmailEngine engine,
            ServiceConfiguration configuration,
            IReportManager reportManager,
            ICredentialManager credentialManager,
            MetricManager metricManager)
        {
            this.store         = factory.GetStore();
            this.engine        = engine;
            this.configuration = configuration;

            this.reportManager     = reportManager;
            this.credentialManager = credentialManager;
            this.metricManager     = metricManager;

            this.random       = new Random();
            this.proxyFactory = new ServiceProxyFactory((c) =>
            {
                return(new FabricTransportServiceRemotingClientFactory(
                           serializationProvider: new ServiceRemotingJsonSerializationProvider()));
            });
        }
 public AuthController(IUserEngine userEngine, IEmailEngine emailEngine)
 {
     _userEngine  = userEngine;
     _emailEngine = emailEngine;
 }
Exemplo n.º 5
0
 public EmailController(IEmailEngine emailEngine)
 {
     _emailEngine = emailEngine;
 }
Exemplo n.º 6
0
 public UserController(ISubscriptionEngine subscriptionEngine, IEmailEngine emailEngine)
 {
     _subscriptionEngine = subscriptionEngine;
     _emailEngine        = emailEngine;
 }
Exemplo n.º 7
0
 public EmailSender(IEmailBodyBuilder emailBodyBuilder, IEmailEngine emailEngine)
 {
     this.emailEngine      = emailEngine;
     this.emailBodyBuilder = emailBodyBuilder;
 }
Exemplo n.º 8
0
 public EmailService(IEmailEngine emailEngine)
 {
     this.emailEngine = emailEngine;
 }
Exemplo n.º 9
0
 public WelcomeMailerConsumer(IEmailEngine emailEngine)
 {
     _emailEngine = emailEngine;
 }