Package com.cloudera.flume.handlers.avro

Examples of com.cloudera.flume.handlers.avro.FlumeOGEventAvroServer


        source.getLifecycleState());

    // setup a requester, to send a flume OG event
    URL url = new URL("http", "0.0.0.0", selectedPort, "/");
    Transceiver http = new HttpTransceiver(url);
    FlumeOGEventAvroServer client = SpecificRequestor.getClient(
        FlumeOGEventAvroServer.class, http);

    AvroFlumeOGEvent avroEvent =  AvroFlumeOGEvent.newBuilder().setHost("foo").
        setPriority(Priority.INFO).setNanos(0).setTimestamp(1).
        setFields(new HashMap<CharSequence, ByteBuffer> ()).
        setBody(ByteBuffer.wrap("foo".getBytes())).build();

    client.append(avroEvent);

    // check if the even has arrived in the channel through OG avro source
    Transaction transaction = channel.getTransaction();
    transaction.begin();
View Full Code Here

TOP

Related Classes of com.cloudera.flume.handlers.avro.FlumeOGEventAvroServer

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.