Package org.apache.flume

Examples of org.apache.flume.Channel.start()


      true, false);
    Configurables.configure(sink, ctx);
    Channel channel = new MemoryChannel();
    Configurables.configure(channel, ctx);
    sink.setChannel(channel);
    channel.start();
    sink.start();
    Transaction tx = channel.getTransaction();
    tx.begin();
    for(int i = 0; i < 3; i++){
      Event e = EventBuilder.withBody(Bytes.toBytes(valBase + "-" + i));
View Full Code Here


    Context channelCtx = new Context();
    channelCtx.put("capacity", String.valueOf(1000L));
    channelCtx.put("transactionCapacity", String.valueOf(1000L));
    Configurables.configure(channel, channelCtx);
    sink.setChannel(channel);
    channel.start();
    return channel;
  }

  private void putEvents(Channel channel, Iterable<Event> events) {
    Transaction tx = channel.getTransaction();
View Full Code Here

    Context context = new Context();
    Configurables.configure(s1, context);
    Configurables.configure(s2, context);
    Configurables.configure(s3, context);
    Configurables.configure(ch, context);
    ch.start();
    List<Sink> sinks = new LinkedList<Sink>();
    sinks.add(s1);
    sinks.add(s2);
    sinks.add(s3);
    SinkGroup group = new SinkGroup(sinks);
View Full Code Here

    Context context = new Context();
    Configurables.configure(s1, context);
    Configurables.configure(s2, context);
    Configurables.configure(s3, context);
    Configurables.configure(ch, context);
    ch.start();
    List<Sink> sinks = new LinkedList<Sink>();
    sinks.add(s1);
    sinks.add(s2);
    sinks.add(s3);
    SinkGroup group = new SinkGroup(sinks);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.