Package com.cloudera.flume.handlers.rolling

Examples of com.cloudera.flume.handlers.rolling.ProcessTagger


      };

      FlumeNode node = FlumeNode.getInstance();
      EventSinkDecorator<EventSink> deco = new NaiveFileWALDeco(
          LogicalNodeContext.testingContext(), snk, node.getWalManager(),
          new TimeTrigger(new ProcessTagger(), 1000), node.getAckChecker()
              .getAgentAckQueuer(), 1000);

      deco.open();
      deco.append(e);
      deco.close();
View Full Code Here


      Context ctx = new ReportTestingContext();
      EventSink cntsnk = new CompositeSink(ctx, "counter(\"total\")");
      // use the same wal, but different counter.
      final EventSink snk = new NaiveFileWALDeco(ctx, cntsnk, wal,
          new TimeTrigger(new ProcessTagger(), 1000000),
          new AckListener.Empty(), 1000000);
      snk.open();

      for (int i = 0; i < threads; i++) {
        new Thread() {
View Full Code Here

    when(msrc.next()).thenReturn(e1).thenReturn(e2).thenReturn(e3).thenReturn(
        null);

    DiskFailoverDeco snk = new DiskFailoverDeco(msnk, LogicalNodeContext
        .testingContext(), FlumeNode.getInstance().getDFOManager(),
        new TimeTrigger(new ProcessTagger(), 60000), 300000);
    snk.open();
    try {
      EventUtil.dumpAll(msrc, snk);
      snk.close();
    } catch (IOException ioe) {
View Full Code Here

        Preconditions.checkArgument(dfonode != null,
            "Context does not have a logical node name");
        DiskFailoverManager dfoman = node.getAddDFOManager(dfonode);

        return new DiskFailoverDeco(null, context, dfoman, new TimeTrigger(
            new ProcessTagger(), delayMillis), checkmillis);
      }
    };
  }
View Full Code Here

    // putting in large ridiculous constant
    NaiveFileWALManager wal = new NaiveFileWALManager(dir);
    wal.open();

    // get a sink write to it and then be done with it.
    Tagger t = new ProcessTagger();
    EventSink sink = wal.newWritingSink(t);
    sink.open();
    sink.append(new EventImpl("foo".getBytes()));
    assertEquals(1, wal.getWritingTags().size());
View Full Code Here

    Context ctx = new ReportTestingContext();
    EventSink cntsnk = new CompositeSink(ctx, "counter(\"total\")");
    // use the same wal, but different counter.
    final EventSink snk = new NaiveFileWALDeco<EventSink>(ctx, cntsnk, wal,
        new TimeTrigger(new ProcessTagger(), 1000000), new AckListener.Empty(),
        1000000);
    snk.open();

    for (int i = 0; i < threads; i++) {
      new Thread() {
View Full Code Here

            Context ctx = new ReportTestingContext();
            EventSink snk = new CompositeSink(ctx, "counter(\"total." + idx
                + "\")");
            // use the same wal, but different counter.
            snk = new NaiveFileWALDeco<EventSink>(ctx, snk, wal,
                new TimeTrigger(new ProcessTagger(), 1000000),
                new AckListener.Empty(), 1000000);
            src.open();
            snk.open();

            start.await();
View Full Code Here

            EventSink snk = new CompositeSink(ctx, "counter(\"total." + idx
                + "\")");
            // use the same wal, but different counter.

            snk = new NaiveFileWALDeco<EventSink>(ctx, snk, wal,
                new TimeTrigger(new ProcessTagger(), 1000000),
                new AckListener.Empty(), 1000000);

            start.await();

            // allow for contention on the open call.
View Full Code Here

      };

      FlumeNode node = FlumeNode.getInstance();
      EventSinkDecorator<EventSink> deco = new NaiveFileWALDeco<EventSink>(
          new Context(), snk, node.getWalManager(), new TimeTrigger(
              new ProcessTagger(), 1000), node.getAckChecker()
              .getAgentAckQueuer(), 1000);

      deco.open();
      deco.append(e);
      deco.close();
View Full Code Here

    // putting in large ridiculous constant
    NaiveFileWALManager wal = new NaiveFileWALManager(dir);
    wal.open();

    // get a sink write to it and then be done with it.
    Tagger t = new ProcessTagger();
    EventSink sink = wal.newWritingSink(t);
    sink.open();
    sink.append(new EventImpl("foo".getBytes()));
    assertEquals(1, wal.getWritingTags().size());
View Full Code Here

TOP

Related Classes of com.cloudera.flume.handlers.rolling.ProcessTagger

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.