/** * Create new instance. */ public AsyncAppender() { appenders = new AppenderAttachableImpl(); // // only set for compatibility aai = appenders; dispatcher = new Thread(new Dispatcher(this, buffer, discardMap, appenders)); // It is the user's responsibility to close appenders before // exiting. dispatcher.setDaemon(true); // set the dispatcher priority to lowest possible value // dispatcher.setPriority(Thread.MIN_PRIORITY); dispatcher.setName("Dispatcher-" + dispatcher.getName()); dispatcher.start(); }
/** * Create new instance. */ public UnlimitedAsyncAppender() { appenders = new AppenderAttachableImpl(); // // only set for compatibility aai = appenders; dispatcher = new Dispatcher(this, buffer, discardMap, appenders); dispatcherThread = new Thread(dispatcher, "asynclog-thread"); // It is the user's responsibility to close appenders before // exiting. dispatcherThread.setDaemon(true); // set the dispatcher priority to lowest possible value dispatcherThread.setPriority(Thread.MIN_PRIORITY); // dispatcher.setName("UnlimitedAsyncAppender-Dispatcher-" + dispatcher.getName()); dispatcherThread.start(); }
/** * Create new instance. */ public AsyncAppender() { appenders = new AppenderAttachableImpl(); // // only set for compatibility aai = appenders; dispatcher = new Thread(new Dispatcher(this, buffer, discardMap, appenders)); // It is the user's responsibility to close appenders before // exiting. dispatcher.setDaemon(true); // set the dispatcher priority to lowest possible value // dispatcher.setPriority(Thread.MIN_PRIORITY); dispatcher.setName("AsyncAppender-Dispatcher-" + dispatcher.getName()); dispatcher.start(); }
/** * Create new instance of dispatcher. * * @param parent parent AsyncAppender, may not be null. * @param buffer event buffer, may not be null. * @param discardMap discard map, may not be null. * @param appenders appenders, may not be null. */ public Dispatcher( final AsyncAppender parent, final List buffer, final Map discardMap, final AppenderAttachableImpl appenders) { this.parent = parent; this.buffer = buffer; this.appenders = appenders; this.discardMap = discardMap; }
public RewriteAppender() { appenders = new AppenderAttachableImpl(); }
/** * Create new instance of dispatcher. * * @param parent * parent UnlimitedAsyncAppender, may not be null. * @param buffer * event buffer, may not be null. * @param discardMap * discard map, may not be null. * @param appenders * appenders, may not be null. */ public Dispatcher(final UnlimitedAsyncAppender parent, final List buffer, final Map discardMap, final AppenderAttachableImpl appenders) { running = true; this.parent = parent; this.buffer = buffer; this.appenders = appenders; this.discardMap = discardMap; }
/** * Create new instance of dispatcher. * * @param parent * parent AsyncAppender, may not be null. * @param buffer * event buffer, may not be null. * @param discardMap * discard map, may not be null. * @param appenders * appenders, may not be null. */ public FoundationLoggingDispatcher(final AsyncAppender parent, final List<LoggingEvent> buffer, final Map<String, DiscardSummary> discardMap, final AppenderAttachableImpl appenders) { this.parent = parent; this.buffer = buffer; this.appenders = appenders; this.discardMap = discardMap; }