Examples of FlumeFormatter


Examples of org.apache.flume.sink.FlumeFormatter

        BucketWriter bucketWriter = sfWriters.get(realPath);

        // we haven't seen this file yet, so open it and cache the handle
        if (bucketWriter == null) {
          HDFSWriter hdfsWriter = writerFactory.getWriter(fileType);
          FlumeFormatter formatter = HDFSFormatterFactory
              .getFormatter(writeFormat);

          WriterCallback idleCallback = null;
          if(idleTimeout != 0) {
            idleCallback = new WriterCallback() {
View Full Code Here

Examples of org.apache.flume.sink.FlumeFormatter

        BucketWriter bucketWriter = sfWriters.get(realPath);

        // we haven't seen this file yet, so open it and cache the handle
        if (bucketWriter == null) {
          HDFSWriter hdfsWriter = writerFactory.getWriter(fileType);
          FlumeFormatter formatter = HDFSFormatterFactory
              .getFormatter(writeFormat);

          bucketWriter = new BucketWriter(rollInterval, rollSize, rollCount,
              batchSize, context, realPath, codeC, compType, hdfsWriter,
              formatter, timedRollerPool, proxyTicket, sinkCounter);
View Full Code Here

Examples of org.apache.flume.sink.FlumeFormatter

        BucketWriter bw = sfWriters.get(realPath);

        // we haven't seen this file yet, so open it and cache the handle
        if (bw == null) {
          HDFSWriter writer = myWriterFactory.getWriter(fileType);
          FlumeFormatter formatter = HDFSFormatterFactory
              .getFormatter(writeFormat);
          bw = new BucketWriter(rollInterval, rollSize, rollCount, batchSize);
          bw.open(realPath, codeC, compType, writer, formatter);
          sfWriters.put(realPath, bw);
        }
View Full Code Here

Examples of org.apache.flume.sink.FlumeFormatter

        BucketWriter bw = sfWriters.get(realPath);

        // we haven't seen this file yet, so open it and cache the handle
        if (bw == null) {
          HDFSWriter writer = myWriterFactory.getWriter(fileType);
          FlumeFormatter formatter = HDFSFormatterFactory
              .getFormatter(writeFormat);
          bw = new BucketWriter(rollInterval, rollSize, rollCount, batchSize);
          bw.open(realPath, codeC, compType, writer, formatter);
          sfWriters.put(realPath, bw);
        }
View Full Code Here

Examples of org.apache.flume.sink.FlumeFormatter

    Path path = new Path(fileURI);
    FileSystem fs = path.getFileSystem(conf); // get FS with our conf cached
    CompressionCodecFactory factory = new CompressionCodecFactory(conf);

    HDFSCompressedDataStream writer = new HDFSCompressedDataStream();
    FlumeFormatter fmt = new HDFSTextFormatter();
    writer.open(fileURI, factory.getCodec(new Path(fileURI)),
        SequenceFile.CompressionType.BLOCK, fmt);
    String body = "yarf!";
    Event evt = EventBuilder.withBody(body, Charsets.UTF_8);
    writer.append(evt, fmt);
View Full Code Here

Examples of org.apache.flume.sink.FlumeFormatter

        // we haven't seen this file yet, so open it and cache the handle
        if (bucketWriter == null) {

          HDFSWriter hdfsWriter = writerFactory.getWriter(fileType);
          FlumeFormatter formatter = HDFSFormatterFactory
              .getFormatter(writeFormat);

          bucketWriter = new BucketWriter(rollInterval, rollSize, rollCount,
              batchSize, context, realPath, codeC, compType, hdfsWriter,
              formatter);
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.