Package org.masukomi.aspirin.core.config

Examples of org.masukomi.aspirin.core.config.Configuration


public class DefunctModuleTest extends TestCase {

  public void testAspirin(String[] args) throws Exception {
    // 1. Configure aspirin
    Configuration config = AspirinInternal.getConfiguration();
    config.setDeliveryAttemptCount(3);
    config.setDeliveryAttemptDelay(5);
    config.setDeliveryDebug(true);
    config.setDeliveryThreadsActiveMax(3);
    config.setDeliveryThreadsIdleMax(3);
    config.setDeliveryTimeout(100000); // 100 seconds
    config.setEncoding("UTF-8");
    config.setHostname("localhost");
    config.setLoggerName("MailService");
    config.setLoggerPrefix("MailService");
    config.setPostmasterEmail(null);
    FileMailStore fms = new FileMailStore();
    fms.setRootDir(new File("D:\\temp"));
    fms.setSubDirCount(10);
    config.setMailStore(fms);
   
    MBeanServer mbS = ManagementFactory.getPlatformMBeanServer();
    mbS.registerMBean(config, new ObjectName("org.masukomi.aspirin:type=Configuration"));

//    @SuppressWarnings("unused")
View Full Code Here

TOP

Related Classes of org.masukomi.aspirin.core.config.Configuration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.