├── flume-ng-sinks ├── flume-ng-morphline-solr-sink │ ├── src │ │ └── test │ │ │ ├── resources │ │ │ ├── test-documents │ │ │ │ ├── testPPM.ppm │ │ │ │ ├── cars.csv.gz │ │ │ │ ├── testAIFF.aif │ │ │ │ ├── testBMP.bmp │ │ │ │ ├── testFLAC.oga │ │ │ │ ├── testFLV.flv │ │ │ │ ├── testGIF.gif │ │ │ │ ├── testJAR.jar │ │ │ │ ├── testMP4.m4a │ │ │ │ ├── testPDF.pdf │ │ │ │ ├── testPNG.png │ │ │ │ ├── testPSD.psd │ │ │ │ ├── testTIFF.tif │ │ │ │ ├── testWAR.war │ │ │ │ ├── testWAV.wav │ │ │ │ ├── testWMA.wma │ │ │ │ ├── testWMF.wmf │ │ │ │ ├── testWMV.wmv │ │ │ │ ├── NullHeader.docx │ │ │ │ ├── testEXCEL.xls │ │ │ │ ├── testEXCEL.xlsx │ │ │ │ ├── testFLAC.flac │ │ │ │ ├── testKeynote.key │ │ │ │ ├── testMP3i18n.mp3 │ │ │ │ ├── testPages.pages │ │ │ │ ├── testVISIO.vsd │ │ │ │ ├── testVORBIS.ogg │ │ │ │ ├── testWINMAIL.dat │ │ │ │ ├── test-documents.7z │ │ │ │ ├── test-outlook.msg │ │ │ │ ├── testJPEG_EXIF.jpg │ │ │ │ ├── testTrueType.ttf │ │ │ │ ├── test-documents.cpio │ │ │ │ ├── test-documents.tar │ │ │ │ ├── test-documents.tbz2 │ │ │ │ ├── test-documents.tgz │ │ │ │ ├── test-documents.zip │ │ │ │ ├── test-zip-of-zip.zip │ │ │ │ ├── testJPEG_EXIF.jpg.gz │ │ │ │ ├── testNumbers.numbers │ │ │ │ ├── testPPT_various.ppt │ │ │ │ ├── testPPT_various.pptx │ │ │ │ ├── testWORD_various.doc │ │ │ │ ├── testWindows-x86-32.exe │ │ │ │ ├── testJPEG_EXIF.jpg.tar.gz │ │ │ │ ├── sample-statuses-20120906-141433.bz2 │ │ │ │ ├── sample-statuses-20120906-141433.gz │ │ │ │ ├── sample-statuses-20120906-141433.avro │ │ │ │ ├── cars.csv │ │ │ │ ├── cars.ssv │ │ │ │ ├── cars.tsv │ │ │ │ ├── multiline-sessions.log │ │ │ │ ├── sample-statuses-20120906-141433-medium.avro │ │ │ │ ├── non-length-delimited-20130430-234145-tweets.json.gz │ │ │ │ ├── sample-statuses-20120906-141433-subschema.avsc │ │ │ │ ├── testSVG.svg │ │ │ │ ├── boilerplate.html │ │ │ │ ├── testRDF.rdf │ │ │ │ ├── sample-statuses-20120906-141433.avsc │ │ │ │ ├── rsstest.rss │ │ │ │ └── testDITA.dita │ │ │ ├── solr │ │ │ │ └── collection1 │ │ │ │ │ └── conf │ │ │ │ │ ├── lang │ │ │ │ │ ├── hyphenations_ga.txt │ │ │ │ │ ├── contractions_ga.txt │ │ │ │ │ ├── contractions_ca.txt │ │ │ │ │ ├── contractions_fr.txt │ │ │ │ │ ├── stemdict_nl.txt │ │ │ │ │ ├── contractions_it.txt │ │ │ │ │ ├── stopwords_hy.txt │ │ │ │ │ ├── stopwords_el.txt │ │ │ │ │ ├── stopwords_ga.txt │ │ │ │ │ ├── stopwords_eu.txt │ │ │ │ │ ├── userdict_ja.txt │ │ │ │ │ ├── stopwords_en.txt │ │ │ │ │ ├── stopwords_th.txt │ │ │ │ │ └── stopwords_ar.txt │ │ │ │ │ ├── stopwords.txt │ │ │ │ │ ├── protwords.txt │ │ │ │ │ ├── synonyms.txt │ │ │ │ │ └── elevate.xml │ │ │ ├── test-morphlines │ │ │ │ ├── noOperation.conf │ │ │ │ └── readClob.conf │ │ │ ├── custom-mimetypes.xml │ │ │ └── log4j.properties │ │ │ └── java │ │ │ └── org │ │ │ └── apache │ │ │ └── flume │ │ │ └── sink │ │ │ └── solr │ │ │ └── morphline │ │ │ └── TestEnvironment.java │ └── README.md ├── flume-ng-jdbc-sink │ └── src │ │ ├── test │ │ ├── resources │ │ │ └── log4j.properties │ │ └── java │ │ │ └── org │ │ │ └── apache │ │ │ └── flume │ │ │ └── sink │ │ │ └── jdbc │ │ │ └── TestJDBCSinkCreation.java │ │ └── main │ │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── sink │ │ └── jdbc │ │ ├── CustomParameter.java │ │ ├── BodyParameter.java │ │ ├── HeaderParameter.java │ │ └── ByteArrayBodyParameter.java ├── flume-ng-elasticsearch-sink │ └── src │ │ └── test │ │ └── resources │ │ └── log4j.properties └── flume-hdfs-sink │ └── src │ ├── test │ ├── resources │ │ └── log4j.properties │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── sink │ │ └── hdfs │ │ └── HDFSBadDataStream.java │ └── main │ └── java │ └── org │ └── apache │ └── flume │ └── sink │ └── hdfs │ └── SequenceFileSerializerType.java ├── flume-ng-core └── src │ ├── test │ ├── resources │ │ ├── server.p12 │ │ ├── jettykeystore │ │ ├── truststore.jks │ │ ├── TestResettableFileInputStream_1.avro │ │ ├── test_command.txt │ │ ├── TestResettableFileInputStream_1.truncated.avro │ │ ├── syslog_event.avsc │ │ └── log4j.properties │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ ├── interceptor │ │ └── TestRegexExtractorInterceptorPassThroughSerializer.java │ │ ├── serialization │ │ └── TransientPositionTracker.java │ │ ├── event │ │ └── TestEventHelper.java │ │ └── instrumentation │ │ └── util │ │ └── JMXTestUtils.java │ └── main │ ├── avro │ └── TransferStateFileMeta.avsc │ └── java │ └── org │ └── apache │ └── flume │ ├── conf │ └── ConfigurableComponent.java │ ├── Clock.java │ ├── serialization │ ├── Seekable.java │ ├── LengthMeasurable.java │ ├── DecodeErrorPolicy.java │ ├── PositionTracker.java │ ├── RemoteMarkable.java │ ├── AvroEventSerializerConfigurationConstants.java │ ├── EventDeserializerType.java │ └── EventSerializerType.java │ ├── formatter │ └── output │ │ ├── EventFormatter.java │ │ └── TextDelimitedOutputFormatter.java │ ├── ChannelFactory.java │ ├── SinkFactory.java │ ├── SystemClock.java │ ├── SourceFactory.java │ ├── instrumentation │ ├── SinkProcessorCounter.java │ ├── ChannelProcessorCounter.java │ ├── MonitorService.java │ ├── MonitoringType.java │ ├── ChannelCounterMBean.java │ └── SourceCounterMBean.java │ ├── EventDrivenSource.java │ ├── annotations │ ├── Disposable.java │ └── Recyclable.java │ ├── lifecycle │ ├── LifecycleState.java │ └── LifecycleException.java │ ├── Constants.java │ ├── NamedComponent.java │ ├── tools │ ├── PlatformDetect.java │ └── GetJavaProperty.java │ ├── interceptor │ ├── RegexExtractorInterceptorSerializer.java │ ├── RegexExtractorInterceptorPassThroughSerializer.java │ └── InterceptorType.java │ ├── source │ ├── AbstractEventDrivenSource.java │ ├── http │ │ ├── HTTPBadRequestException.java │ │ └── HTTPSourceConfigurationConstants.java │ └── NetcatSourceConfigurationConstants.java │ ├── ChannelException.java │ └── client │ └── avro │ └── ReliableEventReader.java ├── flume-ng-doc ├── sphinx │ └── images │ │ ├── flume-logo.png │ │ ├── DevGuide_image00.png │ │ ├── DevGuide_image01.png │ │ ├── UserGuide_image00.png │ │ ├── UserGuide_image01.png │ │ ├── UserGuide_image02.png │ │ └── UserGuide_image03.png └── site.xml ├── flume-ng-clients ├── flume-ng-log4jappender │ └── src │ │ └── test │ │ └── resources │ │ ├── myrecord.avsc │ │ ├── flume-log4jtest.properties │ │ ├── flume-loadbalancinglog4jtest.properties │ │ ├── flume-log4jtest-avro-reflect.properties │ │ ├── flume-log4jtest-avro-generic.properties │ │ ├── flume-loadbalancing-backoff-log4jtest.properties │ │ └── flume-loadbalancing-rnd-log4jtest.properties └── pom.xml ├── flume-ng-channels ├── flume-file-channel │ └── src │ │ ├── test │ │ ├── resources │ │ │ ├── ibm-test.keystore │ │ │ ├── sun-test.keystore │ │ │ ├── fileformat-v2-log-1.gz │ │ │ ├── fileformat-v2-log-2.gz │ │ │ ├── fileformat-v2-log-3.gz │ │ │ ├── fileformat-v2-checkpoint.gz │ │ │ ├── fileformat-v2-pre-FLUME-1432-log-1.gz │ │ │ ├── fileformat-v2-pre-FLUME-1432-log-2.gz │ │ │ ├── fileformat-v2-pre-FLUME-1432-log-3.gz │ │ │ ├── fileformat-v2-pre-FLUME-1432-checkpoint.gz │ │ │ └── log4j.properties │ │ └── java │ │ │ └── org │ │ │ └── apache │ │ │ └── flume │ │ │ └── channel │ │ │ └── file │ │ │ ├── TestWriteOrderOracle.java │ │ │ └── TestTransactionIDOracle.java │ │ └── main │ │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── channel │ │ └── file │ │ ├── Pair.java │ │ ├── encryption │ │ ├── KeyProvider.java │ │ ├── CipherProviderType.java │ │ └── KeyProviderType.java │ │ ├── NoopRecordException.java │ │ ├── CorruptEventException.java │ │ ├── LogFileRetryableIOException.java │ │ ├── BadCheckpointException.java │ │ ├── WriteOrderOracle.java │ │ └── TransactionIDOracle.java └── flume-jdbc-channel │ └── src │ ├── test │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── channel │ │ └── jdbc │ │ ├── TestJdbcChannelProvider.java │ │ └── TestJdbcChannelProviderNoFK.java │ └── main │ └── java │ └── org │ └── apache │ └── flume │ └── channel │ └── jdbc │ ├── JdbcChannelException.java │ └── impl │ └── JdbcTransactionFactory.java ├── NOTICE ├── .gitignore ├── flume-ng-sdk └── src │ ├── main │ ├── thrift │ │ ├── aslv2 │ │ └── flume.thrift │ ├── avro │ │ └── flume.avdl │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ ├── FlumeException.java │ │ └── EventDeliveryException.java │ └── test │ └── resources │ └── log4j.properties ├── flume-ng-sources ├── flume-scribe-source │ └── src │ │ └── main │ │ └── thrift │ │ ├── aslv2 │ │ └── scribe-source.thrift ├── flume-jms-source │ └── src │ │ └── main │ │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── source │ │ └── jms │ │ ├── JMSDestinationType.java │ │ ├── InitialContextFactory.java │ │ └── JMSMessageConsumerFactory.java └── flume-twitter-source │ └── src │ └── test │ └── resources │ └── log4j.properties ├── flume-ng-legacy-sources ├── flume-thrift-source │ └── src │ │ ├── main │ │ ├── thrift │ │ │ └── aslv2 │ │ └── java │ │ │ └── README │ │ └── test │ │ └── resources │ │ └── log4j.properties └── flume-avro-source │ └── src │ └── main │ └── avro │ └── flumeCompatibility.avdl ├── flume-tools └── src │ └── main │ └── java │ └── org │ └── apache │ └── flume │ └── tools │ ├── FlumeTool.java │ └── FlumeToolType.java ├── flume-ng-node └── src │ ├── main │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── node │ │ └── ConfigurationProvider.java │ └── test │ └── resources │ └── log4j.properties ├── flume-ng-tests └── src │ ├── test │ └── resources │ │ ├── log4j.properties │ │ └── rpc-client-test.properties │ └── main │ └── java │ └── org │ └── apache │ └── flume │ └── Dummy.java ├── flume-ng-embedded-agent └── src │ ├── test │ └── resources │ │ └── log4j.properties │ └── main │ └── java │ └── org │ └── apache │ └── flume │ └── agent │ └── embedded │ └── package-info.java ├── conf └── flume-env.sh.template ├── flume-ng-configuration └── src │ ├── main │ └── java │ │ └── org │ │ └── apache │ │ └── flume │ │ └── conf │ │ └── ConfigurationException.java │ └── test │ └── java │ └── org │ └── apache │ └── flume │ └── conf │ └── source │ └── TestSourceConfiguration.java └── RELEASE-NOTES /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPPM.ppm: -------------------------------------------------------------------------------- 1 | P3 2 | 1 1 3 | 255 4 | 0 0 0 -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/server.p12: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-core/src/test/resources/server.p12 -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/flume-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/flume-logo.png -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/myrecord.avsc: -------------------------------------------------------------------------------- 1 | {"type":"record","name":"myrecord","fields":[{"name":"message","type":"string"}]} -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/jettykeystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-core/src/test/resources/jettykeystore -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/truststore.jks: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-core/src/test/resources/truststore.jks -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/DevGuide_image00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/DevGuide_image00.png -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/DevGuide_image01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/DevGuide_image01.png -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/UserGuide_image00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/UserGuide_image00.png -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/UserGuide_image01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/UserGuide_image01.png -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/UserGuide_image02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/UserGuide_image02.png -------------------------------------------------------------------------------- /flume-ng-doc/sphinx/images/UserGuide_image03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-doc/sphinx/images/UserGuide_image03.png -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/TestResettableFileInputStream_1.avro: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-core/src/test/resources/TestResettableFileInputStream_1.avro -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/ibm-test.keystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/ibm-test.keystore -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/sun-test.keystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/sun-test.keystore -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/test_command.txt: -------------------------------------------------------------------------------- 1 | echo "'1'"; echo "\"2\""; echo "\\3"; echo "\4" 2 | for i in {1..5}; do echo $i; done 3 | for i in `seq 5`; do echo $i; done | awk ' { print $1 + 1 } ' 4 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-1.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-1.gz -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-2.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-2.gz -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-3.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-log-3.gz -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/TestResettableFileInputStream_1.truncated.avro: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-core/src/test/resources/TestResettableFileInputStream_1.truncated.avro -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-checkpoint.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-checkpoint.gz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/cars.csv.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/cars.csv.gz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testAIFF.aif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testAIFF.aif -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testBMP.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testBMP.bmp -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLAC.oga: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLAC.oga -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLV.flv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLV.flv -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testGIF.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testGIF.gif -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJAR.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJAR.jar -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testMP4.m4a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testMP4.m4a -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPDF.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPDF.pdf -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPNG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPNG.png -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPSD.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPSD.psd -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testTIFF.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testTIFF.tif -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWAR.war: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWAR.war -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWAV.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWAV.wav -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMA.wma: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMA.wma -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMF.wmf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMF.wmf -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMV.wmv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWMV.wmv -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-1.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-1.gz -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-2.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-2.gz -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-3.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-log-3.gz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/NullHeader.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/NullHeader.docx -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testEXCEL.xls: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testEXCEL.xls -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testEXCEL.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testEXCEL.xlsx -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLAC.flac: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testFLAC.flac -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testKeynote.key: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testKeynote.key -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testMP3i18n.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testMP3i18n.mp3 -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPages.pages: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPages.pages -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testVISIO.vsd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testVISIO.vsd -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testVORBIS.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testVORBIS.ogg -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWINMAIL.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWINMAIL.dat -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.7z: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.7z -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-outlook.msg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-outlook.msg -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testTrueType.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testTrueType.ttf -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-checkpoint.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-channels/flume-file-channel/src/test/resources/fileformat-v2-pre-FLUME-1432-checkpoint.gz -------------------------------------------------------------------------------- /flume-ng-core/src/main/avro/TransferStateFileMeta.avsc: -------------------------------------------------------------------------------- 1 | { 2 | "namespace": "org.apache.flume.serialization", 3 | "type": "record", 4 | "name": "TransferStateFileMeta", 5 | "fields": [ 6 | {"name": "offset", "type": "long"} 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/hyphenations_ga.txt: -------------------------------------------------------------------------------- 1 | # Set of Irish hyphenations for StopFilter 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | h 4 | n 5 | t 6 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.cpio: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.cpio -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tar -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tbz2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tbz2 -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tgz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.tgz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-documents.zip -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-zip-of-zip.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/test-zip-of-zip.zip -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg.gz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testNumbers.numbers: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testNumbers.numbers -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPPT_various.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPPT_various.ppt -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPPT_various.pptx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testPPT_various.pptx -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWORD_various.doc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWORD_various.doc -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/contractions_ga.txt: -------------------------------------------------------------------------------- 1 | # Set of Irish contractions for ElisionFilter 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | d 4 | m 5 | b 6 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWindows-x86-32.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testWindows-x86-32.exe -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testJPEG_EXIF.jpg.tar.gz -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/contractions_ca.txt: -------------------------------------------------------------------------------- 1 | # Set of Catalan contractions for ElisionFilter 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | d 4 | l 5 | m 6 | n 7 | s 8 | t 9 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.bz2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.bz2 -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.gz -------------------------------------------------------------------------------- /NOTICE: -------------------------------------------------------------------------------- 1 | Apache Flume 2 | Copyright 2012 The Apache Software Foundation 3 | 4 | This product includes software developed at 5 | The Apache Software Foundation (http://www.apache.org/). 6 | 7 | Portions of this software were developed at 8 | Cloudera, Inc. (http://www.cloudera.com/). 9 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.avro: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.avro -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/contractions_fr.txt: -------------------------------------------------------------------------------- 1 | # Set of French contractions for ElisionFilter 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | l 4 | m 5 | t 6 | qu 7 | n 8 | s 9 | j 10 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stemdict_nl.txt: -------------------------------------------------------------------------------- 1 | # Set of overrides for the dutch stemmer 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | fiets fiets 4 | bromfiets bromfiets 5 | ei eier 6 | kind kinder 7 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/cars.csv: -------------------------------------------------------------------------------- 1 | Age,Color,Extras,Type,Used 2 | 2,blue,GPS,"Gas, with electric","" 3 | 10,green,"Labeled ""Vintage, 1913""",,yes 4 | 100,red,"Labeled ""Vintage 1913""",yes 5 | 5,orange,none,"This is a 6 | multi, line text",no -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/cars.ssv: -------------------------------------------------------------------------------- 1 | Age Color Extras Type Used 2 | 2 blue GPS "Gas, with electric" "" 3 | 10 green "Labeled ""Vintage, 1913""" yes 4 | 100 red "Labeled ""Vintage 1913""" yes 5 | 5 orange none "This is a 6 | multi, line text" no -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/cars.tsv: -------------------------------------------------------------------------------- 1 | Age Color Extras Type Used 2 | 2 blue GPS "Gas with electric" "" 3 | 10 green "Labeled ""Vintage 1913""" yes 4 | 100 red "Labeled ""Vintage 1913""" yes 5 | 5 orange none "This is a 6 | multi line text" no -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/multiline-sessions.log: -------------------------------------------------------------------------------- 1 | Started GET /foo 2 | Foo Started GET as HTML 3 | Completed 401 Unauthorized in 0ms 4 | 5 | 6 | Started GET /bar 7 | Bar as HTML 8 | Completed 200 OK in 339ms 9 | Started GET /baz 10 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433-medium.avro: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433-medium.avro -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/non-length-delimited-20130430-234145-tweets.json.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germinator/flume-jdbc/HEAD/flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/non-length-delimited-20130430-234145-tweets.json.gz -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Lines that start with '#' are comments. 2 | *~ 3 | *.diff 4 | *# 5 | .classpath 6 | .project 7 | .settings 8 | bin/flume-env.sh 9 | conf/flume-site.xml 10 | bin/.settings 11 | .eclipse 12 | pmd_report.html 13 | */bin 14 | target 15 | patchprocess 16 | derby.log 17 | .idea 18 | *.iml 19 | nb-configuration.xml 20 | .DS_Store 21 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433-subschema.avsc: -------------------------------------------------------------------------------- 1 | { 2 | "type" : "record", 3 | "name" : "Doc", 4 | "doc" : "adoc", 5 | "fields" : [ { 6 | "name" : "id", 7 | "type" : "string" 8 | }, { 9 | "name" : "text", 10 | "type" : [ "string", "null" ] 11 | } ] 12 | } 13 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/syslog_event.avsc: -------------------------------------------------------------------------------- 1 | { "type": "record", "name": "SyslogEvent", "namespace": "org.apache.flume.test", 2 | "fields": [ 3 | { "name": "facility", "type": "int" }, 4 | { "name": "severity", "type": "int" }, 5 | { "name": "timestamp", "type": "long" }, 6 | { "name": "hostname", "type": "string" }, 7 | { "name": "message", "type": "string" } 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testSVG.svg: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | Test SVG image 6 | 7 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/contractions_it.txt: -------------------------------------------------------------------------------- 1 | # Set of Italian contractions for ElisionFilter 2 | # TODO: load this as a resource from the analyzer and sync it in build.xml 3 | c 4 | l 5 | all 6 | dall 7 | dell 8 | nell 9 | sull 10 | coll 11 | pell 12 | gl 13 | agl 14 | dagl 15 | degl 16 | negl 17 | sugl 18 | un 19 | m 20 | t 21 | s 22 | v 23 | d 24 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_hy.txt: -------------------------------------------------------------------------------- 1 | # example set of Armenian stopwords. 2 | այդ 3 | այլ 4 | այն 5 | այս 6 | դու 7 | դուք 8 | եմ 9 | են 10 | ենք 11 | ես 12 | եք 13 | է 14 | էի 15 | էին 16 | էինք 17 | էիր 18 | էիք 19 | էր 20 | ըստ 21 | թ 22 | ի 23 | ին 24 | իսկ 25 | իր 26 | կամ 27 | համար 28 | հետ 29 | հետո 30 | մենք 31 | մեջ 32 | մի 33 | ն 34 | նա 35 | նաև 36 | նրա 37 | նրանք 38 | որ 39 | որը 40 | որոնք 41 | որպես 42 | ու 43 | ում 44 | պիտի 45 | վրա 46 | և 47 | -------------------------------------------------------------------------------- /flume-ng-sdk/src/main/thrift/aslv2: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/stopwords.txt: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-scribe-source/src/main/thrift/aslv2: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | -------------------------------------------------------------------------------- /flume-ng-legacy-sources/flume-thrift-source/src/main/thrift/aslv2: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_el.txt: -------------------------------------------------------------------------------- 1 | # Lucene Greek Stopwords list 2 | # Note: by default this file is used after GreekLowerCaseFilter, 3 | # so when modifying this file use 'σ' instead of 'ς' 4 | ο 5 | η 6 | το 7 | οι 8 | τα 9 | του 10 | τησ 11 | των 12 | τον 13 | την 14 | και 15 | κι 16 | κ 17 | ειμαι 18 | εισαι 19 | ειναι 20 | ειμαστε 21 | ειστε 22 | στο 23 | στον 24 | στη 25 | στην 26 | μα 27 | αλλα 28 | απο 29 | για 30 | προσ 31 | με 32 | σε 33 | ωσ 34 | παρα 35 | αντι 36 | κατα 37 | μετα 38 | θα 39 | να 40 | δε 41 | δεν 42 | μη 43 | μην 44 | επι 45 | ενω 46 | εαν 47 | αν 48 | τοτε 49 | που 50 | πωσ 51 | ποιοσ 52 | ποια 53 | ποιο 54 | ποιοι 55 | ποιεσ 56 | ποιων 57 | ποιουσ 58 | αυτοσ 59 | αυτη 60 | αυτο 61 | αυτοι 62 | αυτων 63 | αυτουσ 64 | αυτεσ 65 | αυτα 66 | εκεινοσ 67 | εκεινη 68 | εκεινο 69 | εκεινοι 70 | εκεινεσ 71 | εκεινα 72 | εκεινων 73 | εκεινουσ 74 | οπωσ 75 | ομωσ 76 | ισωσ 77 | οσο 78 | οτι 79 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/protwords.txt: -------------------------------------------------------------------------------- 1 | # The ASF licenses this file to You under the Apache License, Version 2.0 2 | # (the "License"); you may not use this file except in compliance with 3 | # the License. You may obtain a copy of the License at 4 | # 5 | # http://www.apache.org/licenses/LICENSE-2.0 6 | # 7 | # Unless required by applicable law or agreed to in writing, software 8 | # distributed under the License is distributed on an "AS IS" BASIS, 9 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 10 | # See the License for the specific language governing permissions and 11 | # limitations under the License. 12 | 13 | #----------------------------------------------------------------------- 14 | # Use a protected word file to protect against the stemmer reducing two 15 | # unrelated words to the same base word. 16 | 17 | # Some non-words that normally won't be encountered, 18 | # just to test that they won't be stemmed. 19 | dontstems 20 | zwhacky 21 | 22 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-jms-source/src/main/java/org/apache/flume/source/jms/JMSDestinationType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.source.jms; 20 | 21 | public enum JMSDestinationType { 22 | QUEUE(), TOPIC(), 23 | } -------------------------------------------------------------------------------- /flume-tools/src/main/java/org/apache/flume/tools/FlumeTool.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.tools; 20 | 21 | public interface FlumeTool { 22 | 23 | public void run(String[] args) throws Exception; 24 | } 25 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/conf/ConfigurableComponent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one or more 3 | * contributor license agreements. See the NOTICE file distributed with this 4 | * work for additional information regarding copyright ownership. The ASF 5 | * licenses this file to you under the Apache License, Version 2.0 (the 6 | * "License"); you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14 | * License for the specific language governing permissions and limitations under 15 | * the License. 16 | */ 17 | 18 | package org.apache.flume.conf; 19 | 20 | public interface ConfigurableComponent { 21 | 22 | public void configure(ComponentConfiguration conf); 23 | 24 | } 25 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/Clock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume; 20 | 21 | /** 22 | * Facade for System.currentTimeMillis for Testing 23 | */ 24 | public interface Clock { 25 | 26 | public long currentTimeMillis(); 27 | 28 | } 29 | -------------------------------------------------------------------------------- /flume-ng-node/src/main/java/org/apache/flume/node/ConfigurationProvider.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.node; 21 | 22 | 23 | public interface ConfigurationProvider { 24 | 25 | 26 | public MaterializedConfiguration getConfiguration(); 27 | 28 | 29 | } 30 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/boilerplate.html: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | Title 8 | 9 | 10 | 11 | 12 | 13 | 21 | 22 |
14 | 15 | 16 | 17 | 18 | 19 |
boilerplatetext
20 |
23 | 24 |

This is the real meat of the page, 25 | and represents the text we want. 26 | It has lots of juicy content. 27 | 28 | We assume that it won't get filtered out. 29 | And that all of the lines will be in the 30 | output. 31 |

32 | 33 |

34 | Here's another paragraph of text. 35 | This is the end of the text. 36 |

37 | 38 |

footer

39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-log4jtest.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.Log4jAppender 18 | log4j.appender.out2.Port = 25430 19 | log4j.appender.out2.Hostname = localhost 20 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-loadbalancinglog4jtest.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.LoadBalancingLog4jAppender 18 | log4j.appender.out2.Hosts = localhost:25430 localhost:25431 19 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/Seekable.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.serialization; 19 | 20 | import java.io.IOException; 21 | 22 | public interface Seekable { 23 | void seek(long position) throws IOException; 24 | long tell() throws IOException; 25 | } 26 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/formatter/output/EventFormatter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.formatter.output; 21 | 22 | import org.apache.flume.Event; 23 | 24 | @Deprecated 25 | public interface EventFormatter { 26 | 27 | public byte[] format(Event event); 28 | 29 | } 30 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-morphlines/noOperation.conf: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | morphlines : [ 19 | { 20 | id : morphline1 21 | importCommands : ["com.cloudera.**"] 22 | 23 | commands : [ 24 | { logDebug { format : "output record: {}", args : ["@{}"] } } 25 | ] 26 | } 27 | ] 28 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootLogger = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | -------------------------------------------------------------------------------- /flume-ng-node/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootCategory = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | -------------------------------------------------------------------------------- /flume-ng-sdk/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootLogger = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | -------------------------------------------------------------------------------- /flume-ng-tests/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | 19 | log4j.rootLogger = INFO, out 20 | 21 | log4j.appender.out = org.apache.log4j.ConsoleAppender 22 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 23 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 24 | 25 | log4j.logger.org.apache.flume = DEBUG 26 | -------------------------------------------------------------------------------- /flume-ng-embedded-agent/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootLogger = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/LengthMeasurable.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.serialization; 19 | 20 | import java.io.IOException; 21 | 22 | public interface LengthMeasurable { 23 | 24 | /** returns the total length of the stream or file */ 25 | long length() throws IOException; 26 | 27 | } 28 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootLogger = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/ChannelFactory.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume; 19 | 20 | 21 | public interface ChannelFactory { 22 | 23 | public Channel create(String name, String type) throws FlumeException; 24 | 25 | public Class getClass(String type) 26 | throws FlumeException; 27 | 28 | } 29 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | 19 | log4j.rootLogger = INFO, out 20 | 21 | log4j.appender.out = org.apache.log4j.ConsoleAppender 22 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 23 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 24 | 25 | log4j.logger.org.apache.flume = DEBUG 26 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/SinkFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume; 21 | 22 | 23 | public interface SinkFactory { 24 | 25 | public Sink create(String name, String type) 26 | throws FlumeException; 27 | 28 | public Class getClass(String type) 29 | throws FlumeException; 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-embedded-agent/src/main/java/org/apache/flume/agent/embedded/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | /** 20 | * This package provides Flume users the ability to embed simple agents 21 | * in applications. For specific and up to date information, please see 22 | * the Flume Developer Guide. 23 | */ 24 | package org.apache.flume.agent.embedded; 25 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/SystemClock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume; 20 | 21 | /** 22 | * Default implementation of Clock which uses System 23 | */ 24 | public class SystemClock implements Clock { 25 | 26 | public long currentTimeMillis() { 27 | return System.currentTimeMillis(); 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-legacy-sources/flume-thrift-source/src/main/java/README: -------------------------------------------------------------------------------- 1 | # 2 | # Licensed to the Apache Software Foundation (ASF) under one 3 | # or more contributor license agreements. See the NOTICE file 4 | # distributed with this work for additional information 5 | # regarding copyright ownership. The ASF licenses this file 6 | # to you under the Apache License, Version 2.0 (the 7 | # "License"); you may not use this file except in compliance 8 | # with the License. You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, 13 | # software distributed under the License is distributed on an 14 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | # KIND, either express or implied. See the License for the 16 | # specific language governing permissions and limitations 17 | # under the License. 18 | # 19 | 20 | The com directory contains generated java source from thrift. This 21 | is to support backward compatibility with 0.9.x flume. The 1.0 version 22 | of Flume doesn't use thrift so in order to avoid depenancy on thrift 23 | compiler, the generated sources are checked into the source tree. 24 | -------------------------------------------------------------------------------- /flume-ng-legacy-sources/flume-thrift-source/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | 19 | log4j.rootLogger = DEBUG, out 20 | 21 | log4j.appender.out = org.apache.log4j.ConsoleAppender 22 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 23 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 24 | 25 | log4j.logger.org.apache.flume = DEBUG 26 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-elasticsearch-sink/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | 19 | log4j.rootLogger = DEBUG, out 20 | 21 | log4j.appender.out = org.apache.log4j.ConsoleAppender 22 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 23 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 24 | 25 | log4j.logger.org.apache.flume = DEBUG 26 | -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-log4jtest-avro-reflect.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.Log4jAppender 18 | log4j.appender.out2.Port = 25430 19 | log4j.appender.out2.Hostname = localhost 20 | log4j.appender.out2.AvroReflectionEnabled = true 21 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/SourceFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume; 21 | 22 | 23 | public interface SourceFactory { 24 | 25 | public Source create(String sourceName, String type) 26 | throws FlumeException; 27 | 28 | public Class getClass(String type) 29 | throws FlumeException; 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/SinkProcessorCounter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation; 20 | 21 | public class SinkProcessorCounter extends MonitoredCounterGroup { 22 | 23 | protected SinkProcessorCounter(String name) { 24 | super(MonitoredCounterGroup.Type.SINK_PROCESSOR, name); 25 | } 26 | 27 | } 28 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testRDF.rdf: -------------------------------------------------------------------------------- 1 | 2 | 18 | 20 | 23 | 24 | -------------------------------------------------------------------------------- /flume-ng-tests/src/main/java/org/apache/flume/Dummy.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | 19 | package org.apache.flume; 20 | 21 | /** 22 | * Placeholder class so the git mirror does not leave out the src/main/java dir 23 | */ 24 | public class Dummy { 25 | 26 | public Dummy() { 27 | throw new UnsupportedOperationException("Dummy class meant for use"); 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-scribe-source/src/main/thrift/scribe-source.thrift: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | 21 | namespace java org.apache.flume.source.scribe 22 | 23 | enum ResultCode { 24 | OK,TRY_LATER 25 | } 26 | 27 | struct LogEntry { 28 | 1: string category, 29 | 2: string message 30 | } 31 | 32 | service Scribe { 33 | ResultCode Log(1: list messages); 34 | } -------------------------------------------------------------------------------- /flume-ng-tests/src/test/resources/rpc-client-test.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | rpccagent.sources = src1 19 | rpccagent.channels = ch1 20 | 21 | rpccagent.sources.src1.type = avro 22 | rpccagent.sources.src1.bind = 127.0.0.1 23 | rpccagent.sources.src1.port = 12121 24 | rpccagent.sources.src1.channels = ch1 25 | 26 | rpccagent.channels.ch1.type = memory 27 | rpccagent.channels.ch1.capacity = 100 28 | -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-log4jtest-avro-generic.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.Log4jAppender 18 | log4j.appender.out2.Port = 25430 19 | log4j.appender.out2.Hostname = localhost 20 | log4j.appender.out2.AvroSchemaUrl = file:///tmp/myrecord.avsc 21 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/ChannelProcessorCounter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation; 20 | 21 | public class ChannelProcessorCounter extends MonitoredCounterGroup { 22 | 23 | protected ChannelProcessorCounter(String name) { 24 | super(MonitoredCounterGroup.Type.CHANNEL_PROCESSOR, name); 25 | } 26 | 27 | } 28 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/main/java/org/apache/flume/sink/jdbc/CustomParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.jdbc; 20 | 21 | /** 22 | * A subclass of parameter used to identify custom parameters. 23 | */ 24 | public abstract class CustomParameter extends Parameter { 25 | 26 | public CustomParameter(final int id) { 27 | super(id); 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_ga.txt: -------------------------------------------------------------------------------- 1 | 2 | a 3 | ach 4 | ag 5 | agus 6 | an 7 | aon 8 | ar 9 | arna 10 | as 11 | b' 12 | ba 13 | beirt 14 | bhúr 15 | caoga 16 | ceathair 17 | ceathrar 18 | chomh 19 | chtó 20 | chuig 21 | chun 22 | cois 23 | céad 24 | cúig 25 | cúigear 26 | d' 27 | daichead 28 | dar 29 | de 30 | deich 31 | deichniúr 32 | den 33 | dhá 34 | do 35 | don 36 | dtí 37 | dá 38 | dár 39 | dó 40 | faoi 41 | faoin 42 | faoina 43 | faoinár 44 | fara 45 | fiche 46 | gach 47 | gan 48 | go 49 | gur 50 | haon 51 | hocht 52 | i 53 | iad 54 | idir 55 | in 56 | ina 57 | ins 58 | inár 59 | is 60 | le 61 | leis 62 | lena 63 | lenár 64 | m' 65 | mar 66 | mo 67 | mé 68 | na 69 | nach 70 | naoi 71 | naonúr 72 | ná 73 | ní 74 | níor 75 | nó 76 | nócha 77 | ocht 78 | ochtar 79 | os 80 | roimh 81 | sa 82 | seacht 83 | seachtar 84 | seachtó 85 | seasca 86 | seisear 87 | siad 88 | sibh 89 | sinn 90 | sna 91 | sé 92 | sí 93 | tar 94 | thar 95 | thú 96 | triúr 97 | trí 98 | trína 99 | trínár 100 | tríocha 101 | tú 102 | um 103 | ár 104 | é 105 | éis 106 | í 107 | ó 108 | ón 109 | óna 110 | ónár 111 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/EventDrivenSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume; 21 | 22 | /** 23 | * A {@link Source} that does not need an external driver to poll for 24 | * {@linkplain Event events} to ingest; it provides its own event-driven 25 | * mechanism to invoke event processing. 26 | */ 27 | public interface EventDrivenSource extends Source { 28 | 29 | } 30 | -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-loadbalancing-backoff-log4jtest.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.LoadBalancingLog4jAppender 18 | log4j.appender.out2.Hosts = localhost:25430 localhost:25431 localhost:25432 19 | log4j.appender.out2.Selector = ROUND_ROBIN 20 | log4j.appender.out2.MaxBackoff = 30000 21 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-sinks/flume-hdfs-sink/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | log4j.rootLogger = INFO, out 19 | 20 | log4j.appender.out = org.apache.log4j.ConsoleAppender 21 | log4j.appender.out.layout = org.apache.log4j.PatternLayout 22 | log4j.appender.out.layout.ConversionPattern = %d (%t) [%p - %l] %m%n 23 | 24 | log4j.logger.org.apache.flume = DEBUG 25 | log4j.logger.org.apache.hadoop = WARN 26 | log4j.logger.org.mortbay = WARN 27 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-jdbc-channel/src/test/java/org/apache/flume/channel/jdbc/TestJdbcChannelProvider.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.channel.jdbc; 19 | 20 | import org.apache.flume.Context; 21 | 22 | public class TestJdbcChannelProvider extends BaseJdbcChannelProviderTest { 23 | 24 | @Override 25 | protected void configureChannel(Context context) { 26 | // using default configuration 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/annotations/Disposable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.annotations; 21 | import java.lang.annotation.Target; 22 | import java.lang.annotation.Retention; 23 | import static java.lang.annotation.RetentionPolicy.RUNTIME; 24 | import static java.lang.annotation.ElementType.TYPE; 25 | 26 | @Target({ TYPE }) @Retention(RUNTIME) 27 | public @interface Disposable {} 28 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/annotations/Recyclable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.annotations; 21 | import java.lang.annotation.Target; 22 | import java.lang.annotation.Retention; 23 | import static java.lang.annotation.RetentionPolicy.RUNTIME; 24 | import static java.lang.annotation.ElementType.TYPE; 25 | 26 | @Target({ TYPE }) @Retention(RUNTIME) 27 | public @interface Recyclable {} 28 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_eu.txt: -------------------------------------------------------------------------------- 1 | # example set of basque stopwords 2 | al 3 | anitz 4 | arabera 5 | asko 6 | baina 7 | bat 8 | batean 9 | batek 10 | bati 11 | batzuei 12 | batzuek 13 | batzuetan 14 | batzuk 15 | bera 16 | beraiek 17 | berau 18 | berauek 19 | bere 20 | berori 21 | beroriek 22 | beste 23 | bezala 24 | da 25 | dago 26 | dira 27 | ditu 28 | du 29 | dute 30 | edo 31 | egin 32 | ere 33 | eta 34 | eurak 35 | ez 36 | gainera 37 | gu 38 | gutxi 39 | guzti 40 | haiei 41 | haiek 42 | haietan 43 | hainbeste 44 | hala 45 | han 46 | handik 47 | hango 48 | hara 49 | hari 50 | hark 51 | hartan 52 | hau 53 | hauei 54 | hauek 55 | hauetan 56 | hemen 57 | hemendik 58 | hemengo 59 | hi 60 | hona 61 | honek 62 | honela 63 | honetan 64 | honi 65 | hor 66 | hori 67 | horiei 68 | horiek 69 | horietan 70 | horko 71 | horra 72 | horrek 73 | horrela 74 | horretan 75 | horri 76 | hortik 77 | hura 78 | izan 79 | ni 80 | noiz 81 | nola 82 | non 83 | nondik 84 | nongo 85 | nor 86 | nora 87 | ze 88 | zein 89 | zen 90 | zenbait 91 | zenbat 92 | zer 93 | zergatik 94 | ziren 95 | zituen 96 | zu 97 | zuek 98 | zuen 99 | zuten 100 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-morphlines/readClob.conf: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | morphlines : [ 19 | { 20 | id : morphline1 21 | importCommands : ["com.cloudera.**", "org.apache.solr.**"] 22 | 23 | commands : [ 24 | { 25 | readClob { 26 | charset : UTF-8 27 | } 28 | } 29 | { logDebug { format : "output record: {}", args : ["@{}"] } } 30 | ] 31 | } 32 | ] 33 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/DecodeErrorPolicy.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.serialization; 21 | 22 | import org.apache.flume.annotations.InterfaceAudience; 23 | import org.apache.flume.annotations.InterfaceStability; 24 | 25 | @InterfaceAudience.Private 26 | @InterfaceStability.Evolving 27 | public enum DecodeErrorPolicy { 28 | FAIL, 29 | REPLACE, 30 | IGNORE 31 | } 32 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/userdict_ja.txt: -------------------------------------------------------------------------------- 1 | # 2 | # This is a sample user dictionary for Kuromoji (JapaneseTokenizer) 3 | # 4 | # Add entries to this file in order to override the statistical model in terms 5 | # of segmentation, readings and part-of-speech tags. Notice that entries do 6 | # not have weights since they are always used when found. This is by-design 7 | # in order to maximize ease-of-use. 8 | # 9 | # Entries are defined using the following CSV format: 10 | # , ... , ... , 11 | # 12 | # Notice that a single half-width space separates tokens and readings, and 13 | # that the number tokens and readings must match exactly. 14 | # 15 | # Also notice that multiple entries with the same is undefined. 16 | # 17 | # Whitespace only lines are ignored. Comments are not allowed on entry lines. 18 | # 19 | 20 | # Custom segmentation for kanji compounds 21 | 日本経済新聞,日本 経済 新聞,ニホン ケイザイ シンブン,カスタム名詞 22 | 関西国際空港,関西 国際 空港,カンサイ コクサイ クウコウ,カスタム名詞 23 | 24 | # Custom segmentation for compound katakana 25 | トートバッグ,トート バッグ,トート バッグ,かずカナ名詞 26 | ショルダーバッグ,ショルダー バッグ,ショルダー バッグ,かずカナ名詞 27 | 28 | # Custom reading for former sumo wrestler 29 | 朝青龍,朝青龍,アサショウリュウ,カスタム人名 30 | -------------------------------------------------------------------------------- /flume-ng-sdk/src/main/avro/flume.avdl: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | @namespace("org.apache.flume.source.avro") 21 | 22 | protocol AvroSourceProtocol { 23 | 24 | enum Status { 25 | OK, FAILED, UNKNOWN 26 | } 27 | 28 | record AvroFlumeEvent { 29 | map headers; 30 | bytes body; 31 | } 32 | 33 | Status append( AvroFlumeEvent event ); 34 | 35 | Status appendBatch( array events ); 36 | 37 | } 38 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/main/java/org/apache/flume/sink/jdbc/BodyParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.jdbc; 20 | 21 | /** 22 | * A subclass of parameter used to identify parameters that read from the event 23 | * body (and not a header). 24 | */ 25 | public abstract class BodyParameter extends Parameter { 26 | 27 | public BodyParameter(final int id) { 28 | super(id); 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/lifecycle/LifecycleState.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.lifecycle; 21 | 22 | public enum LifecycleState { 23 | IDLE, START, STOP, ERROR; 24 | 25 | public static final LifecycleState[] START_OR_ERROR = new LifecycleState[] { 26 | START, ERROR }; 27 | public static final LifecycleState[] STOP_OR_ERROR = new LifecycleState[] { 28 | STOP, ERROR }; 29 | 30 | } 31 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/README.md: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | 18 | # Flume Morphline Solr Sink 19 | 20 | This module contains a Flume Morphline Solr Sink that extracts search documents from Flume events, transforms them and loads them in Near Real Time into Apache Solr, typically a SolrCloud. This sink is intended to be used alongside the HdfsSink. It is designed to process not just structured data, but also arbitrary raw data, including data from many heterogeneous data sources. 21 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-jdbc-channel/src/test/java/org/apache/flume/channel/jdbc/TestJdbcChannelProviderNoFK.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.channel.jdbc; 19 | 20 | import org.apache.flume.Context; 21 | 22 | public class TestJdbcChannelProviderNoFK extends BaseJdbcChannelProviderTest { 23 | 24 | @Override 25 | protected void configureChannel(Context context) { 26 | context.put(ConfigurationConstants.CONFIG_CREATE_FK, "false"); 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /flume-ng-clients/flume-ng-log4jappender/src/test/resources/flume-loadbalancing-rnd-log4jtest.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.appender.out2 = org.apache.flume.clients.log4jappender.LoadBalancingLog4jAppender 18 | log4j.appender.out2.Hosts = localhost:25430 localhost:25431 localhost:25432 localhost:25433 localhost:25434 localhost:25435 localhost:25436 localhost:25437 localhost:25438 localhost:25439 19 | log4j.appender.out2.Selector = RANDOM 20 | log4j.logger.org.apache.flume.clients.log4jappender = DEBUG,out2 -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/synonyms.txt: -------------------------------------------------------------------------------- 1 | # The ASF licenses this file to You under the Apache License, Version 2.0 2 | # (the "License"); you may not use this file except in compliance with 3 | # the License. You may obtain a copy of the License at 4 | # 5 | # http://www.apache.org/licenses/LICENSE-2.0 6 | # 7 | # Unless required by applicable law or agreed to in writing, software 8 | # distributed under the License is distributed on an "AS IS" BASIS, 9 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 10 | # See the License for the specific language governing permissions and 11 | # limitations under the License. 12 | 13 | #----------------------------------------------------------------------- 14 | #some test synonym mappings unlikely to appear in real input text 15 | aaafoo => aaabar 16 | bbbfoo => bbbfoo bbbbar 17 | cccfoo => cccbar cccbaz 18 | fooaaa,baraaa,bazaaa 19 | 20 | # Some synonym groups specific to this example 21 | GB,gib,gigabyte,gigabytes 22 | MB,mib,megabyte,megabytes 23 | Television, Televisions, TV, TVs 24 | #notice we use "gib" instead of "GiB" so any WordDelimiterFilter coming 25 | #after us won't split it into two words. 26 | 27 | # Synonym mappings can be used for spelling correction too 28 | pixima => pixma 29 | 30 | -------------------------------------------------------------------------------- /flume-ng-sdk/src/main/thrift/flume.thrift: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | namespace java org.apache.flume.thrift 21 | 22 | struct ThriftFlumeEvent { 23 | 1: required map headers, 24 | 2: required binary body, 25 | } 26 | 27 | enum Status { 28 | OK, 29 | FAILED, 30 | ERROR, 31 | UNKNOWN 32 | } 33 | 34 | service ThriftSourceProtocol { 35 | Status append(1: ThriftFlumeEvent event), 36 | Status appendBatch(1: list events), 37 | } 38 | 39 | -------------------------------------------------------------------------------- /conf/flume-env.sh.template: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, software 12 | # distributed under the License is distributed on an "AS IS" BASIS, 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | # See the License for the specific language governing permissions and 15 | # limitations under the License. 16 | 17 | # If this file is placed at FLUME_CONF_DIR/flume-env.sh, it will be sourced 18 | # during Flume startup. 19 | 20 | # Enviroment variables can be set here. 21 | 22 | #JAVA_HOME=/usr/lib/jvm/java-6-sun 23 | 24 | # Give Flume more memory and pre-allocate, enable remote monitoring via JMX 25 | #JAVA_OPTS="-Xms100m -Xmx200m -Dcom.sun.management.jmxremote" 26 | 27 | # Note that the Flume conf directory is always included in the classpath. 28 | #FLUME_CLASSPATH="" 29 | 30 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-jms-source/src/main/java/org/apache/flume/source/jms/InitialContextFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.source.jms; 19 | 20 | import java.util.Properties; 21 | 22 | import javax.naming.InitialContext; 23 | import javax.naming.NamingException; 24 | 25 | 26 | public class InitialContextFactory { 27 | 28 | public InitialContext create(Properties properties) throws NamingException { 29 | return new InitialContext(properties); 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/formatter/output/TextDelimitedOutputFormatter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.formatter.output; 21 | 22 | import org.apache.flume.Event; 23 | 24 | @Deprecated 25 | public class TextDelimitedOutputFormatter implements EventFormatter { 26 | 27 | @Override 28 | public byte[] format(Event event) { 29 | String body = event.getBody().length > 0 ? new String(event.getBody()) : ""; 30 | 31 | return (body + "\n").getBytes(); 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/Pair.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | class Pair { 22 | 23 | private final L left; 24 | private final R right; 25 | Pair(L l, R r) { 26 | left = l; 27 | right = r; 28 | } 29 | L getLeft() { 30 | return left; 31 | } 32 | R getRight() { 33 | return right; 34 | } 35 | static Pair of(L left, R right) { 36 | return new Pair(left, right); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/encryption/KeyProvider.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file.encryption; 20 | 21 | import java.security.Key; 22 | 23 | import org.apache.flume.Context; 24 | 25 | public abstract class KeyProvider { 26 | 27 | /** 28 | * Returns a non-null Key 29 | */ 30 | public abstract Key getKey(String alias); 31 | 32 | public interface Builder { 33 | public abstract KeyProvider build(Context context); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/main/java/org/apache/flume/sink/jdbc/HeaderParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.jdbc; 20 | 21 | /** 22 | * A subclass of parameter used to identify parameters that read from a header 23 | * (and not the body). 24 | */ 25 | public abstract class HeaderParameter extends Parameter { 26 | 27 | protected String header; 28 | 29 | public HeaderParameter(final int id, final String header) { 30 | super(id); 31 | this.header = header; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /flume-ng-doc/site.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | org.apache.maven.skins 21 | maven-fluido-skin 22 | 1.0 23 | 24 | 25 | 26 | 27 | 28 | 29 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /flume-ng-legacy-sources/flume-avro-source/src/main/avro/flumeCompatibility.avdl: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | /* Avro protocol for Flume 0.9.x compatibility */ 21 | @namespace("com.cloudera.flume.handlers.avro") 22 | protocol FlumeOGEventAvroServer{ 23 | enum Priority { FATAL, ERROR, WARN, 24 | INFO, DEBUG, TRACE} 25 | 26 | record AvroFlumeOGEvent { 27 | long timestamp; 28 | Priority priority; 29 | bytes body; 30 | long nanos; 31 | string host; 32 | map fields; 33 | } 34 | 35 | void append( AvroFlumeOGEvent evt ) ; 36 | } -------------------------------------------------------------------------------- /flume-ng-sdk/src/main/java/org/apache/flume/FlumeException.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume; 19 | 20 | /** 21 | * Base class of all flume exceptions. 22 | */ 23 | public class FlumeException extends RuntimeException { 24 | 25 | private static final long serialVersionUID = 1L; 26 | 27 | public FlumeException(String msg) { 28 | super(msg); 29 | } 30 | 31 | public FlumeException(String msg, Throwable th) { 32 | super(msg, th); 33 | } 34 | 35 | public FlumeException(Throwable th) { 36 | super(th); 37 | } 38 | 39 | } 40 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/NoopRecordException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | public class NoopRecordException extends Exception { 22 | private static final long serialVersionUID = -7394180633208889738L; 23 | 24 | public NoopRecordException() { 25 | super(); 26 | } 27 | 28 | public NoopRecordException(String msg) { 29 | super(msg); 30 | } 31 | 32 | public NoopRecordException(String msg, Throwable th) { 33 | super(msg, th); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/CorruptEventException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | 22 | public class CorruptEventException extends Exception { 23 | 24 | private static final long serialVersionUID = -2986946303540798416L; 25 | public CorruptEventException() { 26 | super(); 27 | } 28 | 29 | public CorruptEventException(String msg) { 30 | super(msg); 31 | } 32 | 33 | public CorruptEventException(String msg, Throwable th) { 34 | super(msg, th); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/java/org/apache/flume/channel/file/TestWriteOrderOracle.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | import junit.framework.Assert; 22 | 23 | import org.junit.Test; 24 | 25 | public class TestWriteOrderOracle { 26 | 27 | 28 | @Test 29 | public void testSetSeed() { 30 | long current = WriteOrderOracle.next(); 31 | current += Integer.MAX_VALUE; 32 | WriteOrderOracle.setSeed(current); 33 | Assert.assertTrue(WriteOrderOracle.next() > System.currentTimeMillis()); 34 | } 35 | 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/Constants.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume; 20 | 21 | public final class Constants { 22 | 23 | /** 24 | * Disables the fail-fast startup behavior. This would be used in the 25 | * scenario where the agent is expected to start, but the config 26 | * file be populated at a later point in time. 27 | */ 28 | public static final String SYSPROP_CALLED_FROM_SERVICE 29 | = "flume.called.from.service"; 30 | 31 | private Constants() { 32 | // disable explicit object creation 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_en.txt: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | # a couple of test stopwords to test that the words are really being 17 | # configured from this file: 18 | stopworda 19 | stopwordb 20 | 21 | # Standard english stop words taken from Lucene's StopAnalyzer 22 | a 23 | an 24 | and 25 | are 26 | as 27 | at 28 | be 29 | but 30 | by 31 | for 32 | if 33 | in 34 | into 35 | is 36 | it 37 | no 38 | not 39 | of 40 | on 41 | or 42 | such 43 | that 44 | the 45 | their 46 | then 47 | there 48 | these 49 | they 50 | this 51 | to 52 | was 53 | will 54 | with 55 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/NamedComponent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume; 20 | 21 | import org.apache.flume.annotations.InterfaceAudience; 22 | import org.apache.flume.annotations.InterfaceStability; 23 | 24 | /** 25 | * Enables a component to be tagged with a name so that it can be referred 26 | * to uniquely within the configuration system. 27 | */ 28 | @InterfaceAudience.Public 29 | @InterfaceStability.Stable 30 | public interface NamedComponent { 31 | 32 | public void setName(String name); 33 | 34 | public String getName(); 35 | 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/test/java/org/apache/flume/channel/file/TestTransactionIDOracle.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | import junit.framework.Assert; 22 | 23 | import org.junit.Test; 24 | 25 | public class TestTransactionIDOracle { 26 | 27 | 28 | @Test 29 | public void testSetSeed() { 30 | long current = TransactionIDOracle.next(); 31 | current += Integer.MAX_VALUE; 32 | TransactionIDOracle.setSeed(current); 33 | Assert.assertTrue(TransactionIDOracle.next() > System.currentTimeMillis()); 34 | } 35 | 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/tools/PlatformDetect.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.tools; 19 | 20 | /** 21 | * Utilities for platform & operating system detection 22 | */ 23 | public class PlatformDetect { 24 | 25 | /** 26 | * Detects whether we are running under Microsoft Windows. 27 | * @return true if and only if we are running on a Windows system. 28 | */ 29 | public static boolean isWindows() { 30 | String os = System.getProperty("os.name"); 31 | boolean isWin = (os.toLowerCase().indexOf("win") >= 0); 32 | return isWin; 33 | } 34 | 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/java/org/apache/flume/sink/solr/morphline/TestEnvironment.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one or more 3 | * contributor license agreements. See the NOTICE file distributed with 4 | * this work for additional information regarding copyright ownership. 5 | * The ASF licenses this file to You under the Apache License, Version 2.0 6 | * (the "License"); you may not use this file except in compliance with 7 | * the License. You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | package org.apache.flume.sink.solr.morphline; 18 | 19 | import java.net.UnknownHostException; 20 | 21 | import org.junit.Test; 22 | 23 | import com.cloudera.cdk.morphline.solr.EnvironmentTest; 24 | 25 | /** Print and verify some info about the environment in which the unit tests are running */ 26 | public class TestEnvironment extends EnvironmentTest { 27 | 28 | @Test 29 | public void testEnvironment() throws UnknownHostException { 30 | super.testEnvironment(); 31 | } 32 | 33 | } 34 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/LogFileRetryableIOException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | import java.io.IOException; 22 | 23 | public class LogFileRetryableIOException extends IOException { 24 | private static final long serialVersionUID = -2747112999806160431L; 25 | public LogFileRetryableIOException() { 26 | super(); 27 | } 28 | public LogFileRetryableIOException(String msg) { 29 | super(msg); 30 | } 31 | public LogFileRetryableIOException(String msg, Throwable t) { 32 | super(msg, t); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/MonitorService.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation; 20 | 21 | import org.apache.flume.conf.Configurable; 22 | 23 | /** 24 | * Interface that any monitoring service should implement. If the monitor 25 | * service is to be started up when Flume starts, it should implement this 26 | * and the class name should be passed in during startup, with any additional 27 | * context it requires. 28 | */ 29 | public interface MonitorService extends Configurable { 30 | 31 | public void start(); 32 | 33 | public void stop(); 34 | 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/encryption/CipherProviderType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file.encryption; 20 | 21 | 22 | public enum CipherProviderType { 23 | AESCTRNOPADDING(AESCTRNoPaddingProvider.class), 24 | OTHER(null); 25 | 26 | private final Class providerClass; 27 | 28 | CipherProviderType(Class providerClass) { 29 | this.providerClass = providerClass; 30 | } 31 | 32 | public Class getProviderClass() { 33 | return providerClass; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/lifecycle/LifecycleException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.lifecycle; 21 | 22 | public class LifecycleException extends Exception { 23 | 24 | private static final long serialVersionUID = 4689000562519155240L; 25 | 26 | public LifecycleException() { 27 | super(); 28 | } 29 | 30 | public LifecycleException(String message) { 31 | super(message); 32 | } 33 | 34 | public LifecycleException(String message, Throwable t) { 35 | super(message, t); 36 | } 37 | 38 | public LifecycleException(Throwable t) { 39 | super(t); 40 | } 41 | 42 | } 43 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/tools/GetJavaProperty.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.tools; 19 | 20 | /** 21 | * A generic way for querying Java properties. 22 | */ 23 | public class GetJavaProperty { 24 | public static void main(String args[]) { 25 | if (args.length == 0) { 26 | for (Object prop : System.getProperties().keySet()) { 27 | System.out.println(prop + "=" + System.getProperty((String)prop, "")); 28 | } 29 | } else { 30 | for (String prop : args) { 31 | System.out.println(prop + "=" + System.getProperty(prop, "")); 32 | } 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-configuration/src/main/java/org/apache/flume/conf/ConfigurationException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.conf; 20 | 21 | import org.apache.flume.FlumeException; 22 | 23 | public class ConfigurationException extends FlumeException { 24 | 25 | /** 26 | * 27 | */ 28 | private static final long serialVersionUID = 1L; 29 | 30 | public ConfigurationException(String arg0) { 31 | super(arg0); 32 | } 33 | 34 | public ConfigurationException(Throwable arg0) { 35 | super(arg0); 36 | } 37 | 38 | public ConfigurationException(String arg0, Throwable arg1) { 39 | super(arg0, arg1); 40 | } 41 | 42 | } 43 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/encryption/KeyProviderType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file.encryption; 20 | 21 | 22 | public enum KeyProviderType { 23 | JCEKSFILE(JCEFileKeyProvider.Builder.class), 24 | OTHER(null); 25 | 26 | private final Class keyProviderClass; 27 | 28 | KeyProviderType(Class keyStoreProviderClass) { 29 | this.keyProviderClass = keyStoreProviderClass; 30 | } 31 | 32 | public Class getBuilderClass() { 33 | return keyProviderClass; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_th.txt: -------------------------------------------------------------------------------- 1 | # Thai stopwords from: 2 | # "Opinion Detection in Thai Political News Columns 3 | # Based on Subjectivity Analysis" 4 | # Khampol Sukhum, Supot Nitsuwat, and Choochart Haruechaiyasak 5 | ไว้ 6 | ไม่ 7 | ไป 8 | ได้ 9 | ให้ 10 | ใน 11 | โดย 12 | แห่ง 13 | แล้ว 14 | และ 15 | แรก 16 | แบบ 17 | แต่ 18 | เอง 19 | เห็น 20 | เลย 21 | เริ่ม 22 | เรา 23 | เมื่อ 24 | เพื่อ 25 | เพราะ 26 | เป็นการ 27 | เป็น 28 | เปิดเผย 29 | เปิด 30 | เนื่องจาก 31 | เดียวกัน 32 | เดียว 33 | เช่น 34 | เฉพาะ 35 | เคย 36 | เข้า 37 | เขา 38 | อีก 39 | อาจ 40 | อะไร 41 | ออก 42 | อย่าง 43 | อยู่ 44 | อยาก 45 | หาก 46 | หลาย 47 | หลังจาก 48 | หลัง 49 | หรือ 50 | หนึ่ง 51 | ส่วน 52 | ส่ง 53 | สุด 54 | สําหรับ 55 | ว่า 56 | วัน 57 | ลง 58 | ร่วม 59 | ราย 60 | รับ 61 | ระหว่าง 62 | รวม 63 | ยัง 64 | มี 65 | มาก 66 | มา 67 | พร้อม 68 | พบ 69 | ผ่าน 70 | ผล 71 | บาง 72 | น่า 73 | นี้ 74 | นํา 75 | นั้น 76 | นัก 77 | นอกจาก 78 | ทุก 79 | ที่สุด 80 | ที่ 81 | ทําให้ 82 | ทํา 83 | ทาง 84 | ทั้งนี้ 85 | ทั้ง 86 | ถ้า 87 | ถูก 88 | ถึง 89 | ต้อง 90 | ต่างๆ 91 | ต่าง 92 | ต่อ 93 | ตาม 94 | ตั้งแต่ 95 | ตั้ง 96 | ด้าน 97 | ด้วย 98 | ดัง 99 | ซึ่ง 100 | ช่วง 101 | จึง 102 | จาก 103 | จัด 104 | จะ 105 | คือ 106 | ความ 107 | ครั้ง 108 | คง 109 | ขึ้น 110 | ของ 111 | ขอ 112 | ขณะ 113 | ก่อน 114 | ก็ 115 | การ 116 | กับ 117 | กัน 118 | กว่า 119 | กล่าว 120 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-jdbc-channel/src/main/java/org/apache/flume/channel/jdbc/JdbcChannelException.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.channel.jdbc; 19 | 20 | import org.apache.flume.ChannelException; 21 | 22 | public class JdbcChannelException extends ChannelException { 23 | 24 | private static final long serialVersionUID = -5566109526732929679L; 25 | 26 | public JdbcChannelException(String message) { 27 | super(message); 28 | } 29 | 30 | public JdbcChannelException(String message, Exception cause) { 31 | super(message, cause); 32 | } 33 | 34 | public JdbcChannelException(Exception cause) { 35 | super(cause); 36 | } 37 | 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/test/java/org/apache/flume/sink/jdbc/TestJDBCSinkCreation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.jdbc; 20 | 21 | import org.apache.flume.Sink; 22 | import org.apache.flume.SinkFactory; 23 | import org.apache.flume.sink.DefaultSinkFactory; 24 | import static org.junit.Assert.*; 25 | import org.junit.Test; 26 | 27 | public class TestJDBCSinkCreation { 28 | 29 | @Test 30 | public void testSinkCreation() { 31 | final SinkFactory factory = new DefaultSinkFactory(); 32 | final Sink sink = factory.create("s", "jdbc"); 33 | assertNotNull(sink); 34 | assertTrue(sink instanceof PreparedStatementJDBCSink); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/java/org/apache/flume/interceptor/TestRegexExtractorInterceptorPassThroughSerializer.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.interceptor; 19 | 20 | import junit.framework.Assert; 21 | 22 | import org.apache.flume.Context; 23 | import org.junit.Test; 24 | 25 | public class TestRegexExtractorInterceptorPassThroughSerializer { 26 | 27 | @Test 28 | public void shouldReturnSameValue() { 29 | RegexExtractorInterceptorPassThroughSerializer fixture = new RegexExtractorInterceptorPassThroughSerializer(); 30 | fixture.configure(new Context()); 31 | String input = "testing (1,2,3,4)"; 32 | Assert.assertEquals(input, fixture.serialize(input)); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /flume-ng-configuration/src/test/java/org/apache/flume/conf/source/TestSourceConfiguration.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one or more 3 | * contributor license agreements. See the NOTICE file distributed with this 4 | * work for additional information regarding copyright ownership. The ASF 5 | * licenses this file to you under the Apache License, Version 2.0 (the 6 | * "License"); you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14 | * License for the specific language governing permissions and limitations under 15 | * the License. 16 | */ 17 | package org.apache.flume.conf.source; 18 | 19 | import org.apache.flume.Context; 20 | import org.apache.flume.conf.ConfigurationException; 21 | import org.junit.Test; 22 | 23 | public class TestSourceConfiguration { 24 | 25 | /** 26 | * Test fails without FLUME-1847 27 | */ 28 | @Test(expected = ConfigurationException.class) 29 | public void testFLUME1847() throws Exception { 30 | Context context = new Context(); 31 | context.put("type", "something"); 32 | SourceConfiguration sourceConfig = new SourceConfiguration("src"); 33 | sourceConfig.configure(context); 34 | 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/PositionTracker.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.serialization; 19 | 20 | import org.apache.flume.annotations.InterfaceAudience; 21 | import org.apache.flume.annotations.InterfaceStability; 22 | 23 | import java.io.Closeable; 24 | import java.io.IOException; 25 | 26 | /** 27 | * Defines an interface for tracking the offset position in a target file. 28 | */ 29 | @InterfaceAudience.Private 30 | @InterfaceStability.Evolving 31 | public interface PositionTracker extends Closeable { 32 | void storePosition(long position) throws IOException; 33 | long getPosition(); 34 | String getTarget(); 35 | void close() throws IOException; 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/BadCheckpointException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | 19 | package org.apache.flume.channel.file; 20 | 21 | import org.apache.flume.FlumeException; 22 | 23 | /** 24 | * Exception thrown when the checkpoint directory contains invalid data, 25 | * probably due to the channel stopping while the checkpoint was written. 26 | */ 27 | public class BadCheckpointException extends FlumeException{ 28 | private static final long serialVersionUID = -5038652693746472779L; 29 | 30 | public BadCheckpointException(String msg) { 31 | super(msg); 32 | } 33 | public BadCheckpointException(String msg, Throwable t) { 34 | super(msg, t); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/MonitoringType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.instrumentation; 21 | 22 | /** 23 | * Enum for Monitoring types. 24 | */ 25 | public enum MonitoringType { 26 | OTHER(null), 27 | GANGLIA(org.apache.flume.instrumentation.GangliaServer.class), 28 | HTTP(org.apache.flume.instrumentation.http.HTTPMetricsServer.class); 29 | 30 | private Class monitoringClass; 31 | 32 | private MonitoringType(Class klass) { 33 | this.monitoringClass = klass; 34 | } 35 | 36 | public Class getMonitorClass(){ 37 | return this.monitoringClass; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/RemoteMarkable.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.serialization; 19 | 20 | import java.io.IOException; 21 | 22 | /** Allows for calling mark() without a seek() */ 23 | public interface RemoteMarkable { 24 | 25 | /** 26 | * Indicate that the specified position should be returned to in the case of 27 | * {@link Resettable#reset()} being called. 28 | * @throws java.io.IOException 29 | */ 30 | void markPosition(long position) throws IOException; 31 | 32 | /** 33 | * Return the saved mark position without moving the mark pointer. 34 | * @throws IOException 35 | */ 36 | long getMarkPosition() throws IOException; 37 | 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-hdfs-sink/src/main/java/org/apache/flume/sink/hdfs/SequenceFileSerializerType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.hdfs; 20 | 21 | public enum SequenceFileSerializerType { 22 | Writable(HDFSWritableSerializer.Builder.class), 23 | Text(HDFSTextSerializer.Builder.class), 24 | Other(null); 25 | 26 | private final Class builderClass; 27 | 28 | SequenceFileSerializerType( 29 | Class builderClass) { 30 | this.builderClass = builderClass; 31 | } 32 | 33 | public Class getBuilderClass() { 34 | return builderClass; 35 | } 36 | 37 | } 38 | 39 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/WriteOrderOracle.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | import java.util.concurrent.atomic.AtomicLong; 22 | 23 | public final class WriteOrderOracle { 24 | 25 | private WriteOrderOracle() {} 26 | private static final AtomicLong WRITER_ORDERER = 27 | new AtomicLong(System.currentTimeMillis()); 28 | 29 | public static void setSeed(long highest) { 30 | long previous; 31 | while(highest > (previous = WRITER_ORDERER.get())) { 32 | WRITER_ORDERER.compareAndSet(previous, highest); 33 | } 34 | } 35 | public static long next() { 36 | return WRITER_ORDERER.incrementAndGet(); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/interceptor/RegexExtractorInterceptorSerializer.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.interceptor; 19 | 20 | import org.apache.flume.conf.Configurable; 21 | import org.apache.flume.conf.ConfigurableComponent; 22 | 23 | /** 24 | * Serializer for serializing groups matched by the 25 | * {@link RegexExtractorInterceptor} 26 | */ 27 | public interface RegexExtractorInterceptorSerializer extends Configurable, 28 | ConfigurableComponent { 29 | 30 | /** 31 | * @param value 32 | * The value extracted by the {@link RegexExtractorInterceptor} 33 | * @return The serialized version of the specified value 34 | */ 35 | String serialize(String value); 36 | 37 | } 38 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/elevate.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-file-channel/src/main/java/org/apache/flume/channel/file/TransactionIDOracle.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.channel.file; 20 | 21 | import java.util.concurrent.atomic.AtomicLong; 22 | 23 | public final class TransactionIDOracle { 24 | 25 | private TransactionIDOracle() {} 26 | private static final AtomicLong TRANSACTION_ID = 27 | new AtomicLong(System.currentTimeMillis()); 28 | 29 | public static void setSeed(long highest) { 30 | long previous; 31 | while(highest > (previous = TRANSACTION_ID.get())) { 32 | TRANSACTION_ID.compareAndSet(previous, highest); 33 | } 34 | } 35 | public static long next() { 36 | return TRANSACTION_ID.incrementAndGet(); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-tools/src/main/java/org/apache/flume/tools/FlumeToolType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.tools; 20 | 21 | public enum FlumeToolType { 22 | FCINTEGRITYTOOL(FileChannelIntegrityTool.class); 23 | 24 | private final Class klass; 25 | private FlumeToolType(Class klass) { 26 | this.klass = klass; 27 | } 28 | 29 | public Class getClassInstance() { 30 | return this.klass; 31 | } 32 | 33 | public static String getNames() { 34 | StringBuilder builder = new StringBuilder(); 35 | for(FlumeToolType type: values()) { 36 | builder.append(type.name().toLowerCase() + "\n"); 37 | } 38 | return builder.toString(); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /flume-ng-clients/pom.xml: -------------------------------------------------------------------------------- 1 | 17 | 19 | 4.0.0 20 | 21 | flume-parent 22 | org.apache.flume 23 | 1.5.0-SNAPSHOT 24 | .. 25 | 26 | flume-ng-clients 27 | pom 28 | Flume NG Clients 29 | All flume NG clients will come under this module 30 | 31 | flume-ng-log4jappender 32 | 33 | 34 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/sample-statuses-20120906-141433.avsc: -------------------------------------------------------------------------------- 1 | { 2 | "type" : "record", 3 | "name" : "Doc", 4 | "doc" : "adoc", 5 | "fields" : [ { 6 | "name" : "id", 7 | "type" : "string" 8 | }, { 9 | "name" : "user_friends_count", 10 | "type" : [ "int", "null" ] 11 | }, { 12 | "name" : "user_location", 13 | "type" : [ "string", "null" ] 14 | }, { 15 | "name" : "user_description", 16 | "type" : [ "string", "null" ] 17 | }, { 18 | "name" : "user_statuses_count", 19 | "type" : [ "int", "null" ] 20 | }, { 21 | "name" : "user_followers_count", 22 | "type" : [ "int", "null" ] 23 | }, { 24 | "name" : "user_name", 25 | "type" : [ "string", "null" ] 26 | }, { 27 | "name" : "user_screen_name", 28 | "type" : [ "string", "null" ] 29 | }, { 30 | "name" : "created_at", 31 | "type" : [ "string", "null" ] 32 | }, { 33 | "name" : "text", 34 | "type" : [ "string", "null" ] 35 | }, { 36 | "name" : "retweet_count", 37 | "type" : [ "int", "null" ] 38 | }, { 39 | "name" : "retweeted", 40 | "type" : [ "boolean", "null" ] 41 | }, { 42 | "name" : "in_reply_to_user_id", 43 | "type" : [ "long", "null" ] 44 | }, { 45 | "name" : "source", 46 | "type" : [ "string", "null" ] 47 | }, { 48 | "name" : "in_reply_to_status_id", 49 | "type" : [ "long", "null" ] 50 | }, { 51 | "name" : "media_url_https", 52 | "type" : [ "string", "null" ] 53 | }, { 54 | "name" : "expanded_url", 55 | "type" : [ "string", "null" ] 56 | } ] 57 | } 58 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-jdbc-sink/src/main/java/org/apache/flume/sink/jdbc/ByteArrayBodyParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.sink.jdbc; 20 | 21 | import java.sql.PreparedStatement; 22 | 23 | import org.apache.flume.Event; 24 | 25 | /** 26 | * A parameter that puts the byte array header into a the database as. 27 | */ 28 | public class ByteArrayBodyParameter extends BodyParameter { 29 | 30 | public ByteArrayBodyParameter(final int id) { 31 | super(id); 32 | } 33 | 34 | @Override 35 | public void setValue(final PreparedStatement ps, final Event e) 36 | throws Exception { 37 | // Null bodies are not valid. They are always at least arrays of zero 38 | // length. 39 | ps.setBytes(id, e.getBody()); 40 | } 41 | 42 | } 43 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/source/AbstractEventDrivenSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.source; 20 | 21 | import org.apache.flume.EventDrivenSource; 22 | import org.apache.flume.annotations.InterfaceAudience; 23 | import org.apache.flume.annotations.InterfaceStability; 24 | 25 | /** 26 | * Base class which ensures sub-classes will inherit all the properties 27 | * of BasicSourceSemantics. Adds no additional functionality and is provided 28 | * for completeness sake. 29 | */ 30 | @InterfaceAudience.Public 31 | @InterfaceStability.Evolving 32 | public abstract class AbstractEventDrivenSource extends BasicSourceSemantics 33 | implements EventDrivenSource { 34 | 35 | public AbstractEventDrivenSource() { 36 | super(); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/interceptor/RegexExtractorInterceptorPassThroughSerializer.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.interceptor; 19 | 20 | import org.apache.flume.Context; 21 | import org.apache.flume.conf.ComponentConfiguration; 22 | 23 | /** 24 | * Serializer that simply returns the passed in value 25 | */ 26 | public class RegexExtractorInterceptorPassThroughSerializer implements 27 | RegexExtractorInterceptorSerializer { 28 | 29 | @Override 30 | public String serialize(String value) { 31 | return value; 32 | } 33 | 34 | @Override 35 | public void configure(Context context) { 36 | // NO-OP... 37 | } 38 | 39 | @Override 40 | public void configure(ComponentConfiguration conf) { 41 | // NO-OP... 42 | } 43 | 44 | } 45 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-twitter-source/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.rootLogger=WARN, A1 18 | 19 | log4j.logger.org.apache.flume.sink=INFO 20 | #log4j.logger.org.apache.flume.sink.solr=DEBUG 21 | log4j.logger.org.apache.solr=INFO 22 | #log4j.logger.org.apache.solr.hadoop=DEBUG 23 | log4j.logger.org.apache.solr.morphline=DEBUG 24 | log4j.logger.org.apache.solr.update.processor.LogUpdateProcessor=WARN 25 | log4j.logger.org.apache.solr.core.SolrCore=WARN 26 | log4j.logger.org.apache.solr.search.SolrIndexSearcher=ERROR 27 | 28 | # A1 is set to be a ConsoleAppender. 29 | log4j.appender.A1=org.apache.log4j.ConsoleAppender 30 | 31 | # A1 uses PatternLayout. 32 | log4j.appender.A1.layout=org.apache.log4j.PatternLayout 33 | log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n 34 | -------------------------------------------------------------------------------- /flume-ng-channels/flume-jdbc-channel/src/main/java/org/apache/flume/channel/jdbc/impl/JdbcTransactionFactory.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.channel.jdbc.impl; 19 | 20 | import javax.sql.DataSource; 21 | 22 | public class JdbcTransactionFactory extends ThreadLocal { 23 | 24 | private final DataSource dataSource; 25 | private final JdbcChannelProviderImpl providerImpl; 26 | 27 | protected JdbcTransactionFactory(DataSource dataSource, 28 | JdbcChannelProviderImpl providerImpl) { 29 | super(); 30 | this.dataSource = dataSource; 31 | this.providerImpl = providerImpl; 32 | } 33 | 34 | @Override 35 | protected JdbcTransactionImpl initialValue() { 36 | return new JdbcTransactionImpl(dataSource, this, providerImpl); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-sdk/src/main/java/org/apache/flume/EventDeliveryException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume; 21 | 22 | /** 23 | * An event delivery exception is raised whenever an {@link Event} fails to 24 | * reach at least one of its intended (next-hop) destinations. 25 | */ 26 | public class EventDeliveryException extends Exception { 27 | 28 | private static final long serialVersionUID = 1102327497549834945L; 29 | 30 | public EventDeliveryException() { 31 | super(); 32 | } 33 | 34 | public EventDeliveryException(String message) { 35 | super(message); 36 | } 37 | 38 | public EventDeliveryException(String message, Throwable t) { 39 | super(message, t); 40 | } 41 | 42 | public EventDeliveryException(Throwable t) { 43 | super(t); 44 | } 45 | 46 | } 47 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/AvroEventSerializerConfigurationConstants.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.serialization; 20 | 21 | import org.apache.avro.file.CodecFactory; 22 | 23 | public class AvroEventSerializerConfigurationConstants { 24 | 25 | /** 26 | * Avro sync interval, in approximate bytes 27 | */ 28 | public static final String SYNC_INTERVAL_BYTES = "syncIntervalBytes"; 29 | public static final int DEFAULT_SYNC_INTERVAL_BYTES = 2048000; // 2MB 30 | 31 | /** 32 | * Avro compression codec. For supported codecs, see Avro's 33 | * {@link CodecFactory} class. 34 | */ 35 | public static final String COMPRESSION_CODEC = "compressionCodec"; 36 | public static final String DEFAULT_COMPRESSION_CODEC = "null"; // no codec 37 | 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/source/http/HTTPBadRequestException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.source.http; 19 | 20 | import org.apache.flume.FlumeException; 21 | 22 | /** 23 | * 24 | * Exception thrown by an HTTP Handler if the request was not parsed correctly 25 | * into an event because the request was not in the expected format. 26 | * 27 | */ 28 | public class HTTPBadRequestException extends FlumeException { 29 | 30 | private static final long serialVersionUID = -3540764742069390951L; 31 | 32 | public HTTPBadRequestException(String msg) { 33 | super(msg); 34 | } 35 | 36 | public HTTPBadRequestException(String msg, Throwable th) { 37 | super(msg, th); 38 | } 39 | 40 | public HTTPBadRequestException(Throwable th) { 41 | super(th); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/source/NetcatSourceConfigurationConstants.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.source; 20 | 21 | public class NetcatSourceConfigurationConstants { 22 | 23 | /** 24 | * Hostname to bind to. 25 | */ 26 | public static final String CONFIG_HOSTNAME = "bind"; 27 | 28 | /** 29 | * Port to bind to. 30 | */ 31 | public static final String CONFIG_PORT = "port"; 32 | 33 | 34 | /** 35 | * Ack every event received with an "OK" back to the sender 36 | */ 37 | public static final String CONFIG_ACKEVENT = "ack-every-event"; 38 | 39 | /** 40 | * Maximum line length per event. 41 | */ 42 | public static final String CONFIG_MAX_LINE_LENGTH = "max-line-length"; 43 | public static final int DEFAULT_MAX_LINE_LENGTH = 512; 44 | 45 | } 46 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/rsstest.rss: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | TestChannel 21 | http://test.channel.com/ 22 | Sample RSS File for Junit test 23 | en-us 24 | 25 | 26 | Home Page of Chris Mattmann 27 | http://www-scf.usc.edu/~mattmann/ 28 | Chris Mattmann's home page 29 | 30 | 31 | Awesome Open Source Search Engine 32 | http://www.nutch.org/ 33 | Yup, that's what it is 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/test-documents/testDITA.dita: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Apache Tika 5 | Apache Tika - a content analysis toolkit. 6 | 7 | Apache Software Foundation 8 | 9 | 10 | Apache Software Foundation 11 | 12 | 13 | 14 | Metadata 15 | 16 | Tika 17 | Content 18 | 19 | 20 | Apache Tika 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 |

The Apache Tika toolkit detects and extracts metadata and structured text content from various documents using existing parser libraries. You can find the latest release on the download page. See the Getting Started guide for instructions on how to start using Tika.

30 | 31 |

Tika is a project of the Apache Software Foundation, and was formerly a subproject of Apache Lucene.

32 |
33 |
34 |
35 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/custom-mimetypes.xml: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one 2 | # or more contributor license agreements. See the NOTICE file 3 | # distributed with this work for additional information 4 | # regarding copyright ownership. The ASF licenses this file 5 | # to you under the Apache License, Version 2.0 (the 6 | # "License"); you may not use this file except in compliance 7 | # with the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, 12 | # software distributed under the License is distributed on an 13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 14 | # KIND, either express or implied. See the License for the 15 | # specific language governing permissions and limitations 16 | # under the License. 17 | log4j.rootLogger=WARN, A1 18 | 19 | log4j.logger.org.apache.flume.sink=INFO 20 | #log4j.logger.org.apache.flume.sink.solr=DEBUG 21 | log4j.logger.org.apache.solr=INFO 22 | #log4j.logger.org.apache.solr.hadoop=DEBUG 23 | log4j.logger.com.cloudera.cdk.morphline=DEBUG 24 | log4j.logger.org.apache.solr.morphline=DEBUG 25 | log4j.logger.org.apache.solr.update.processor.LogUpdateProcessor=WARN 26 | log4j.logger.org.apache.solr.core.SolrCore=WARN 27 | log4j.logger.org.apache.solr.search.SolrIndexSearcher=ERROR 28 | 29 | # A1 is set to be a ConsoleAppender. 30 | log4j.appender.A1=org.apache.log4j.ConsoleAppender 31 | 32 | # A1 uses PatternLayout. 33 | log4j.appender.A1.layout=org.apache.log4j.PatternLayout 34 | log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n 35 | -------------------------------------------------------------------------------- /flume-ng-sources/flume-jms-source/src/main/java/org/apache/flume/source/jms/JMSMessageConsumerFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.source.jms; 19 | 20 | import javax.jms.ConnectionFactory; 21 | 22 | import com.google.common.base.Optional; 23 | 24 | 25 | public class JMSMessageConsumerFactory { 26 | 27 | JMSMessageConsumer create(ConnectionFactory connectionFactory, 28 | String destinationName, JMSDestinationType destinationType, 29 | String messageSelector, int batchSize, long pollTimeout, 30 | JMSMessageConverter messageConverter, Optional userName, 31 | Optional password) { 32 | return new JMSMessageConsumer(connectionFactory, destinationName, 33 | destinationType, messageSelector, batchSize, pollTimeout, 34 | messageConverter, userName, password); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/EventDeserializerType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.serialization; 20 | 21 | import org.apache.flume.annotations.InterfaceAudience; 22 | import org.apache.flume.annotations.InterfaceStability; 23 | 24 | @InterfaceAudience.Private 25 | @InterfaceStability.Unstable 26 | public enum EventDeserializerType { 27 | LINE(LineDeserializer.Builder.class), 28 | AVRO(AvroEventDeserializer.Builder.class), 29 | OTHER(null); 30 | 31 | private final Class builderClass; 32 | 33 | EventDeserializerType(Class builderClass) { 34 | this.builderClass = builderClass; 35 | } 36 | 37 | public Class getBuilderClass() { 38 | return builderClass; 39 | } 40 | 41 | } 42 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/java/org/apache/flume/serialization/TransientPositionTracker.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.serialization; 19 | 20 | import java.io.IOException; 21 | 22 | public class TransientPositionTracker implements PositionTracker { 23 | 24 | private final String target; 25 | private long position = 0; 26 | 27 | public TransientPositionTracker(String target) { 28 | this.target = target; 29 | } 30 | 31 | @Override 32 | public void storePosition(long position) throws IOException { 33 | this.position = position; 34 | } 35 | 36 | @Override 37 | public long getPosition() { 38 | return position; 39 | } 40 | 41 | @Override 42 | public String getTarget() { 43 | return target; 44 | } 45 | 46 | @Override 47 | public void close() throws IOException { 48 | // no-op 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/ChannelException.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume; 19 | 20 | /** 21 | *

A channel exception is raised whenever a channel operation fails.

22 | */ 23 | public class ChannelException extends RuntimeException { 24 | 25 | private static final long serialVersionUID = 1L; 26 | 27 | /** 28 | * @param message the exception message 29 | */ 30 | public ChannelException(String message) { 31 | super(message); 32 | } 33 | 34 | /** 35 | * @param ex the causal exception 36 | */ 37 | public ChannelException(Throwable ex) { 38 | super(ex); 39 | } 40 | 41 | /** 42 | * @param message the exception message 43 | * @param ex the causal exception 44 | */ 45 | public ChannelException(String message, Throwable ex) { 46 | super(message, ex); 47 | } 48 | 49 | } 50 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-ng-morphline-solr-sink/src/test/resources/solr/collection1/conf/lang/stopwords_ar.txt: -------------------------------------------------------------------------------- 1 | # This file was created by Jacques Savoy and is distributed under the BSD license. 2 | # See http://members.unine.ch/jacques.savoy/clef/index.html. 3 | # Also see http://www.opensource.org/licenses/bsd-license.html 4 | # Cleaned on October 11, 2009 (not normalized, so use before normalization) 5 | # This means that when modifying this list, you might need to add some 6 | # redundant entries, for example containing forms with both أ and ا 7 | من 8 | ومن 9 | منها 10 | منه 11 | في 12 | وفي 13 | فيها 14 | فيه 15 | و 16 | ف 17 | ثم 18 | او 19 | أو 20 | ب 21 | بها 22 | به 23 | ا 24 | أ 25 | اى 26 | اي 27 | أي 28 | أى 29 | لا 30 | ولا 31 | الا 32 | ألا 33 | إلا 34 | لكن 35 | ما 36 | وما 37 | كما 38 | فما 39 | عن 40 | مع 41 | اذا 42 | إذا 43 | ان 44 | أن 45 | إن 46 | انها 47 | أنها 48 | إنها 49 | انه 50 | أنه 51 | إنه 52 | بان 53 | بأن 54 | فان 55 | فأن 56 | وان 57 | وأن 58 | وإن 59 | التى 60 | التي 61 | الذى 62 | الذي 63 | الذين 64 | الى 65 | الي 66 | إلى 67 | إلي 68 | على 69 | عليها 70 | عليه 71 | اما 72 | أما 73 | إما 74 | ايضا 75 | أيضا 76 | كل 77 | وكل 78 | لم 79 | ولم 80 | لن 81 | ولن 82 | هى 83 | هي 84 | هو 85 | وهى 86 | وهي 87 | وهو 88 | فهى 89 | فهي 90 | فهو 91 | انت 92 | أنت 93 | لك 94 | لها 95 | له 96 | هذه 97 | هذا 98 | تلك 99 | ذلك 100 | هناك 101 | كانت 102 | كان 103 | يكون 104 | تكون 105 | وكانت 106 | وكان 107 | غير 108 | بعض 109 | قد 110 | نحو 111 | بين 112 | بينما 113 | منذ 114 | ضمن 115 | حيث 116 | الان 117 | الآن 118 | خلال 119 | بعد 120 | قبل 121 | حتى 122 | عند 123 | عندما 124 | لدى 125 | جميع 126 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/java/org/apache/flume/event/TestEventHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.event; 20 | 21 | import org.junit.Assert; 22 | import org.junit.Test; 23 | 24 | public class TestEventHelper { 25 | 26 | @Test 27 | public void testPrintable() { 28 | SimpleEvent event = new SimpleEvent(); 29 | event.setBody("Some text".getBytes()); 30 | String eventDump = EventHelper.dumpEvent(event); 31 | System.out.println(eventDump); 32 | Assert.assertTrue(eventDump, eventDump.contains("Some text")); 33 | } 34 | 35 | @Test 36 | public void testNonPrintable() { 37 | SimpleEvent event = new SimpleEvent(); 38 | byte[] body = new byte[5]; 39 | event.setBody(body); 40 | String eventDump = EventHelper.dumpEvent(event); 41 | Assert.assertTrue(eventDump, eventDump.contains(".....")); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /flume-ng-core/src/test/java/org/apache/flume/instrumentation/util/JMXTestUtils.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation.util; 20 | 21 | import java.util.Map; 22 | import org.junit.Assert; 23 | 24 | /** 25 | * 26 | */ 27 | public class JMXTestUtils { 28 | 29 | public static void checkChannelCounterParams(Map attrs) { 30 | Assert.assertNotNull(attrs.get("StartTime")); 31 | Assert.assertNotNull(attrs.get("StopTime")); 32 | Assert.assertTrue(Long.parseLong(attrs.get("ChannelSize")) != 0); 33 | Assert.assertTrue(Long.parseLong(attrs.get("EventPutAttemptCount")) == 2); 34 | Assert.assertTrue(Long.parseLong(attrs.get("EventTakeAttemptCount")) == 1); 35 | Assert.assertTrue(Long.parseLong(attrs.get("EventPutSuccessCount")) == 2); 36 | Assert.assertTrue(Long.parseLong(attrs.get("EventTakeSuccessCount")) == 1); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/source/http/HTTPSourceConfigurationConstants.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | 19 | package org.apache.flume.source.http; 20 | 21 | /** 22 | * 23 | */ 24 | public class HTTPSourceConfigurationConstants { 25 | 26 | public static final String CONFIG_PORT = "port"; 27 | public static final String CONFIG_HANDLER = "handler"; 28 | public static final String CONFIG_HANDLER_PREFIX = 29 | CONFIG_HANDLER + "."; 30 | public static final String CONFIG_BIND = "bind"; 31 | 32 | public static final String DEFAULT_BIND = "0.0.0.0"; 33 | 34 | public static final String DEFAULT_HANDLER = 35 | "org.apache.flume.source.http.JSONHandler"; 36 | 37 | public static final String SSL_KEYSTORE = "keystore"; 38 | public static final String SSL_KEYSTORE_PASSWORD = "keystorePassword"; 39 | public static final String SSL_ENABLED = "enableSSL"; 40 | 41 | } 42 | -------------------------------------------------------------------------------- /RELEASE-NOTES: -------------------------------------------------------------------------------- 1 | Apache Flume 1.4.0 2 | 3 | CONTENTS 4 | 1. What is Apache Flume 5 | 2. Status of this release 6 | 3. Major changes in this Release 7 | 4. How to Get Involved 8 | 5. How to Report Issues 9 | 10 | 1. What is Apache Flume 11 | Flume is a distributed, reliable, and available service for 12 | efficiently collecting, aggregating, and moving large amounts of event 13 | data. It has a simple and flexible architecture based on streaming 14 | data flows. It is robust and fault tolerant with tunable reliability 15 | mechanisms and many failover and recovery mechanisms. Flume uses a 16 | simple, extensible data model that allows for online analytic 17 | application. 18 | 19 | 2. Status of this release 20 | Apache Flume 1.4.0 is the fourth release of Flume as an Apache top-level project 21 | (TLP). Apache Flume 1.4.0 is production-ready software. 22 | 23 | 3. Major changes in this Release 24 | For a detailed list of changes, please see the CHANGELOG file included 25 | in this distribution. 26 | 27 | Apache Flume versions 1.0.0 and greater represent a major refactoring of the 28 | Flume codebase and are not backwards compatible with the 0.9.x series of Flume 29 | releases. However, the developers of Flume strive to maintain backwards 30 | compatibility within the 1.x codeline. 31 | 32 | 4. How to Get Involved 33 | The Apache Flume project really needs and appreciates any contributions, 34 | including documentation help, source code and feedback. If you are interested 35 | in contributing, please visit: 36 | https://cwiki.apache.org/confluence/display/FLUME/How+to+Contribute 37 | 38 | 5. How to Report Issues 39 | The Apache Flume project uses JIRA for issue tracking. Please report any issues 40 | you find at http://issues.apache.org/jira/browse/FLUME 41 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/client/avro/ReliableEventReader.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | package org.apache.flume.client.avro; 19 | 20 | import org.apache.flume.annotations.InterfaceAudience; 21 | import org.apache.flume.annotations.InterfaceStability; 22 | 23 | import java.io.IOException; 24 | 25 | /** 26 | * A reliable event reader. 27 | * Clients must call commit() after each read operation, otherwise the 28 | * implementation must reset its internal buffers and return the same events 29 | * as it did previously. 30 | */ 31 | @InterfaceAudience.Private 32 | @InterfaceStability.Evolving 33 | public interface ReliableEventReader extends EventReader { 34 | 35 | /** 36 | * Indicate to the implementation that the previously-returned events have 37 | * been successfully processed and committed. 38 | * @throws IOException 39 | */ 40 | public void commit() throws IOException; 41 | 42 | } 43 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/serialization/EventSerializerType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.serialization; 20 | 21 | import org.apache.flume.annotations.InterfaceAudience; 22 | import org.apache.flume.annotations.InterfaceStability; 23 | 24 | @InterfaceAudience.Private 25 | @InterfaceStability.Unstable 26 | public enum EventSerializerType { 27 | TEXT(BodyTextEventSerializer.Builder.class), 28 | HEADER_AND_TEXT(HeaderAndBodyTextEventSerializer.Builder.class), 29 | AVRO_EVENT(FlumeEventAvroEventSerializer.Builder.class), 30 | OTHER(null); 31 | 32 | private final Class builderClass; 33 | 34 | EventSerializerType(Class builderClass) { 35 | this.builderClass = builderClass; 36 | } 37 | 38 | public Class getBuilderClass() { 39 | return builderClass; 40 | } 41 | 42 | } 43 | -------------------------------------------------------------------------------- /flume-ng-sinks/flume-hdfs-sink/src/test/java/org/apache/flume/sink/hdfs/HDFSBadDataStream.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | 20 | package org.apache.flume.sink.hdfs; 21 | 22 | import java.io.IOException; 23 | import org.apache.flume.Event; 24 | 25 | public class HDFSBadDataStream extends HDFSDataStream { 26 | public class HDFSBadSeqWriter extends HDFSSequenceFile { 27 | @Override 28 | public void append(Event e) throws IOException { 29 | 30 | if (e.getHeaders().containsKey("fault")) { 31 | throw new IOException("Injected fault"); 32 | } else if (e.getHeaders().containsKey("slow")) { 33 | long waitTime = Long.parseLong(e.getHeaders().get("slow")); 34 | try { 35 | Thread.sleep(waitTime); 36 | } catch (InterruptedException eT) { 37 | throw new IOException("append interrupted", eT); 38 | } 39 | } 40 | super.append(e); 41 | } 42 | 43 | } 44 | 45 | } 46 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/interceptor/InterceptorType.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | 19 | package org.apache.flume.interceptor; 20 | 21 | public enum InterceptorType { 22 | 23 | TIMESTAMP(org.apache.flume.interceptor.TimestampInterceptor.Builder.class), 24 | HOST(org.apache.flume.interceptor.HostInterceptor.Builder.class), 25 | STATIC(org.apache.flume.interceptor.StaticInterceptor.Builder.class), 26 | REGEX_FILTER( 27 | org.apache.flume.interceptor.RegexFilteringInterceptor.Builder.class), 28 | REGEX_EXTRACTOR(org.apache.flume.interceptor.RegexExtractorInterceptor.Builder.class); 29 | 30 | private final Class builderClass; 31 | 32 | private InterceptorType(Class builderClass) { 33 | this.builderClass = builderClass; 34 | } 35 | 36 | public Class getBuilderClass() { 37 | return builderClass; 38 | } 39 | 40 | } 41 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/ChannelCounterMBean.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation; 20 | 21 | /** 22 | * This interface represents a channel counter mbean. Any class implementing 23 | * this interface must sub-class 24 | * {@linkplain org.apache.flume.instrumentation.MonitoredCounterGroup}. This 25 | * interface might change between minor releases. Please see 26 | * {@linkplain org.apache.flume.instrumentation.ChannelCounter} class. 27 | */ 28 | public interface ChannelCounterMBean { 29 | 30 | long getChannelSize(); 31 | 32 | long getEventPutAttemptCount(); 33 | 34 | long getEventTakeAttemptCount(); 35 | 36 | long getEventPutSuccessCount(); 37 | 38 | long getEventTakeSuccessCount(); 39 | 40 | long getStartTime(); 41 | 42 | long getStopTime(); 43 | 44 | long getChannelCapacity(); 45 | 46 | String getType(); 47 | 48 | double getChannelFillPercentage(); 49 | } 50 | -------------------------------------------------------------------------------- /flume-ng-core/src/main/java/org/apache/flume/instrumentation/SourceCounterMBean.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Licensed to the Apache Software Foundation (ASF) under one 3 | * or more contributor license agreements. See the NOTICE file 4 | * distributed with this work for additional information 5 | * regarding copyright ownership. The ASF licenses this file 6 | * to you under the Apache License, Version 2.0 (the 7 | * "License"); you may not use this file except in compliance 8 | * with the License. You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, 13 | * software distributed under the License is distributed on an 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | * KIND, either express or implied. See the License for the 16 | * specific language governing permissions and limitations 17 | * under the License. 18 | */ 19 | package org.apache.flume.instrumentation; 20 | /** 21 | * This interface represents a source counter mbean. Any class implementing 22 | * this interface must sub-class 23 | * {@linkplain org.apache.flume.instrumentation.MonitoredCounterGroup}. This 24 | * interface might change between minor releases. Please see 25 | * {@linkplain org.apache.flume.instrumentation.SourceCounter} class. 26 | */ 27 | public interface SourceCounterMBean { 28 | 29 | long getEventReceivedCount(); 30 | 31 | long getEventAcceptedCount(); 32 | 33 | long getAppendReceivedCount(); 34 | 35 | long getAppendAcceptedCount(); 36 | 37 | long getAppendBatchReceivedCount(); 38 | 39 | long getAppendBatchAcceptedCount(); 40 | 41 | long getStartTime(); 42 | 43 | long getStopTime(); 44 | 45 | String getType(); 46 | 47 | long getOpenConnectionCount(); 48 | } 49 | --------------------------------------------------------------------------------