diff --git a/docs/content/Configuration.md b/docs/content/Configuration.md index 15d0ecdd126..51afb07ae65 100644 --- a/docs/content/Configuration.md +++ b/docs/content/Configuration.md @@ -15,7 +15,7 @@ There are three JVM parameters that we set on all of our processes: Modules ======= -As of Druid v0.6.2, most core Druid functionality has been compartmentalized into modules. There are a set of default modules that may apply to any node type, and there are specific modules for the different node types. Default modules are __lazily instantiated__. Each module has its own set of configuration. This page will describe the configuration of the default modules. +As of Druid v0.6, most core Druid functionality has been compartmentalized into modules. There are a set of default modules that may apply to any node type, and there are specific modules for the different node types. Default modules are __lazily instantiated__. Each module has its own set of configuration. This page will describe the configuration of the default modules. Configuration of the various modules is done via Java properties. These can either be provided as `-D` system properties on the java command line or they can be passed in via a file called `runtime.properties` that exists on the classpath. diff --git a/docs/content/Tutorial:-The-Druid-Cluster.md b/docs/content/Tutorial:-The-Druid-Cluster.md index 1ec1048d428..a3b5e2d7ef5 100644 --- a/docs/content/Tutorial:-The-Druid-Cluster.md +++ b/docs/content/Tutorial:-The-Druid-Cluster.md @@ -202,7 +202,7 @@ Usually, when new segments are created, these MySQL entries are created directly ``` sql use druid; -INSERT INTO segments (id, dataSource, created_date, start, end, partitioned, version, used, payload) VALUES ('wikipedia_2013-08-01T00:00:00.000Z_2013-08-02T00:00:00.000Z_2013-08-08T21:22:48.989Z', 'wikipedia', '2013-08-08T21:26:23.799Z', '2013-08-01T00:00:00.000Z', '2013-08-02T00:00:00.000Z', '0', '2013-08-08T21:22:48.989Z', '1', '{\"dataSource\":\"wikipedia\",\"interval\":\"2013-08-01T00:00:00.000Z/2013-08-02T00:00:00.000Z\",\"version\":\"2013-08-08T21:22:48.989Z\",\"loadSpec\":{\"type\":\"s3_zip\",\"bucket\":\"static.druid.io\",\"key\":\"data/segments/wikipedia/20130801T000000.000Z_20130802T000000.000Z/2013-08-08T21_22_48.989Z/0/index.zip\"},\"dimensions\":\"dma_code,continent_code,geo,area_code,robot,country_name,network,city,namespace,anonymous,unpatrolled,page,postal_code,language,newpage,user,region_lookup\",\"metrics\":\"count,delta,variation,added,deleted\",\"shardSpec\":{\"type\":\"none\"},\"binaryVersion\":9,\"size\":24664730,\"identifier\":\"wikipedia_2013-08-01T00:00:00.000Z_2013-08-02T00:00:00.000Z_2013-08-08T21:22:48.989Z\"}'); +INSERT INTO druid_segments (id, dataSource, created_date, start, end, partitioned, version, used, payload) VALUES ('wikipedia_2013-08-01T00:00:00.000Z_2013-08-02T00:00:00.000Z_2013-08-08T21:22:48.989Z', 'wikipedia', '2013-08-08T21:26:23.799Z', '2013-08-01T00:00:00.000Z', '2013-08-02T00:00:00.000Z', '0', '2013-08-08T21:22:48.989Z', '1', '{\"dataSource\":\"wikipedia\",\"interval\":\"2013-08-01T00:00:00.000Z/2013-08-02T00:00:00.000Z\",\"version\":\"2013-08-08T21:22:48.989Z\",\"loadSpec\":{\"type\":\"s3_zip\",\"bucket\":\"static.druid.io\",\"key\":\"data/segments/wikipedia/20130801T000000.000Z_20130802T000000.000Z/2013-08-08T21_22_48.989Z/0/index.zip\"},\"dimensions\":\"dma_code,continent_code,geo,area_code,robot,country_name,network,city,namespace,anonymous,unpatrolled,page,postal_code,language,newpage,user,region_lookup\",\"metrics\":\"count,delta,variation,added,deleted\",\"shardSpec\":{\"type\":\"none\"},\"binaryVersion\":9,\"size\":24664730,\"identifier\":\"wikipedia_2013-08-01T00:00:00.000Z_2013-08-02T00:00:00.000Z_2013-08-08T21:22:48.989Z\"}'); ``` If you look in your coordinator node logs, you should, after a maximum of a minute or so, see logs of the following form: @@ -237,6 +237,8 @@ druid.port=8083 druid.zk.service.host=localhost +druid.extensions.coordinates=["io.druid.extensions:druid-examples:0.6.2-SNAPSHOT"] + druid.db.connector.connectURI=jdbc\:mysql\://localhost\:3306/druid druid.db.connector.user=druid druid.db.connector.password=diurd diff --git a/docs/content/Twitter-Tutorial.textile b/docs/content/Twitter-Tutorial.textile index 5f8809191b3..ea74f934030 100644 --- a/docs/content/Twitter-Tutorial.textile +++ b/docs/content/Twitter-Tutorial.textile @@ -61,12 +61,12 @@ Once the node starts up you will see a bunch of logs about setting up properties
2013-05-17 23:04:40,934 INFO [main] org.mortbay.log - Started SelectChannelConnector@0.0.0.0:8080
 2013-05-17 23:04:40,935 INFO [main] com.metamx.common.lifecycle.Lifecycle$AnnotationBasedHandler - Invoking start method[public void com.metamx.druid.http.FileRequestLogger.start()] on object[com.metamx.druid.http.FileRequestLogger@42bb0406].
 2013-05-17 23:04:41,578 INFO [Twitter Stream consumer-1[Establishing connection]] twitter4j.TwitterStreamImpl - Connection established.
-2013-05-17 23:04:41,578 INFO [Twitter Stream consumer-1[Establishing connection]] druid.examples.twitter.TwitterSpritzerFirehoseFactory - Connected_to_Twitter
+2013-05-17 23:04:41,578 INFO [Twitter Stream consumer-1[Establishing connection]] io.druid.examples.twitter.TwitterSpritzerFirehoseFactory - Connected_to_Twitter
 2013-05-17 23:04:41,578 INFO [Twitter Stream consumer-1[Establishing connection]] twitter4j.TwitterStreamImpl - Receiving status stream.
 
Periodically, you'll also see messages of the form: -
2013-05-17 23:04:59,793 INFO [chief-twitterstream] druid.examples.twitter.TwitterSpritzerFirehoseFactory - nextRow() has returned 1,000 InputRows
+
2013-05-17 23:04:59,793 INFO [chief-twitterstream] io.druid.examples.twitter.TwitterSpritzerFirehoseFactory - nextRow() has returned 1,000 InputRows
 
These messages indicate you are ingesting events. The Druid real time-node ingests events in an in-memory buffer. Periodically, these events will be persisted to disk. Persisting to disk generates a whole bunch of logs: diff --git a/examples/bin/run_example_client.sh b/examples/bin/run_example_client.sh index 316034bec48..5212adf2a52 100755 --- a/examples/bin/run_example_client.sh +++ b/examples/bin/run_example_client.sh @@ -18,7 +18,7 @@ EXAMPLE=$1 if [ -z ${EXAMPLE} ] ; then echo "Please specify an example type." echo "Examples availables:" - echo `ls ${EXAMPLES_DIR}` + echo `ls ${EXAMPLES_DIR} | grep -v indexing` read -p "> " EXAMPLE echo " " fi diff --git a/examples/bin/run_example_server.sh b/examples/bin/run_example_server.sh index 7fd7585849e..7f2e98c9fdb 100755 --- a/examples/bin/run_example_server.sh +++ b/examples/bin/run_example_server.sh @@ -19,7 +19,7 @@ EXAMPLE=$1 if [ -z ${EXAMPLE} ] ; then echo "Please specify an example type." echo "Examples availables:" - echo `ls ${EXAMPLES_DIR}` + echo `ls ${EXAMPLES_DIR} | grep -v indexing` read -p "> " EXAMPLE echo " " fi diff --git a/examples/config/historical/runtime.properties b/examples/config/historical/runtime.properties index 593fbe0ad0a..9fd6f2897a6 100644 --- a/examples/config/historical/runtime.properties +++ b/examples/config/historical/runtime.properties @@ -4,7 +4,7 @@ druid.port=8081 druid.zk.service.host=localhost -druid.extensions.coordinates=["io.druid.extensions:druid-s3-extensions:0.6.2"] +druid.extensions.coordinates=["io.druid.extensions:druid-s3-extensions:0.6.2-SNAPSHOT"] # Dummy read only AWS account (used to download example data) druid.s3.secretKey=QyyfVZ7llSiRg6Qcrql1eEUG7buFpAK6T6engr1b diff --git a/examples/config/realtime/runtime.properties b/examples/config/realtime/runtime.properties index 56ce08fe4d0..7dcdd3845dd 100644 --- a/examples/config/realtime/runtime.properties +++ b/examples/config/realtime/runtime.properties @@ -4,6 +4,8 @@ druid.port=8083 druid.zk.service.host=localhost +druid.extensions.coordinates=["io.druid.extensions:druid-examples:0.6.2-SNAPSHOT"] + druid.db.connector.connectURI=jdbc\:mysql\://localhost\:3306/druid druid.db.connector.user=druid druid.db.connector.password=diurd diff --git a/examples/pom.xml b/examples/pom.xml index 52dc61c5850..dcb1b980d82 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -20,7 +20,7 @@ 4.0.0 - io.druid + io.druid.extensions druid-examples druid-examples druid-examples diff --git a/examples/src/main/java/druid/examples/ExamplesDruidModule.java b/examples/src/main/java/io/druid/examples/ExamplesDruidModule.java similarity index 87% rename from examples/src/main/java/druid/examples/ExamplesDruidModule.java rename to examples/src/main/java/io/druid/examples/ExamplesDruidModule.java index 5a3a024fd33..86a23d061c2 100644 --- a/examples/src/main/java/druid/examples/ExamplesDruidModule.java +++ b/examples/src/main/java/io/druid/examples/ExamplesDruidModule.java @@ -17,16 +17,16 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples; +package io.druid.examples; import com.fasterxml.jackson.databind.Module; import com.fasterxml.jackson.databind.jsontype.NamedType; import com.fasterxml.jackson.databind.module.SimpleModule; import com.google.inject.Binder; -import druid.examples.flights.FlightsFirehoseFactory; -import druid.examples.rand.RandomFirehoseFactory; -import druid.examples.twitter.TwitterSpritzerFirehoseFactory; -import druid.examples.web.WebFirehoseFactory; +import io.druid.examples.flights.FlightsFirehoseFactory; +import io.druid.examples.rand.RandomFirehoseFactory; +import io.druid.examples.twitter.TwitterSpritzerFirehoseFactory; +import io.druid.examples.web.WebFirehoseFactory; import io.druid.initialization.DruidModule; import java.util.Arrays; diff --git a/examples/src/main/java/druid/examples/flights/FlightsConverter.java b/examples/src/main/java/io/druid/examples/flights/FlightsConverter.java similarity index 99% rename from examples/src/main/java/druid/examples/flights/FlightsConverter.java rename to examples/src/main/java/io/druid/examples/flights/FlightsConverter.java index 2edb012b62b..adfaf61d48f 100644 --- a/examples/src/main/java/druid/examples/flights/FlightsConverter.java +++ b/examples/src/main/java/io/druid/examples/flights/FlightsConverter.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.flights; +package io.druid.examples.flights; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.io.Closeables; diff --git a/examples/src/main/java/druid/examples/flights/FlightsFirehoseFactory.java b/examples/src/main/java/io/druid/examples/flights/FlightsFirehoseFactory.java similarity index 99% rename from examples/src/main/java/druid/examples/flights/FlightsFirehoseFactory.java rename to examples/src/main/java/io/druid/examples/flights/FlightsFirehoseFactory.java index fce667f5df3..4e43ec40855 100644 --- a/examples/src/main/java/druid/examples/flights/FlightsFirehoseFactory.java +++ b/examples/src/main/java/io/druid/examples/flights/FlightsFirehoseFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.flights; +package io.druid.examples.flights; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/examples/src/main/java/druid/examples/rabbitmq/RabbitMQProducerMain.java b/examples/src/main/java/io/druid/examples/rabbitmq/RabbitMQProducerMain.java similarity index 99% rename from examples/src/main/java/druid/examples/rabbitmq/RabbitMQProducerMain.java rename to examples/src/main/java/io/druid/examples/rabbitmq/RabbitMQProducerMain.java index 0e9bd2be4dd..597bc031bd0 100644 --- a/examples/src/main/java/druid/examples/rabbitmq/RabbitMQProducerMain.java +++ b/examples/src/main/java/io/druid/examples/rabbitmq/RabbitMQProducerMain.java @@ -1,4 +1,4 @@ -package druid.examples.rabbitmq; +package io.druid.examples.rabbitmq; import com.rabbitmq.client.Channel; import com.rabbitmq.client.Connection; diff --git a/examples/src/main/java/druid/examples/rand/RandomFirehoseFactory.java b/examples/src/main/java/io/druid/examples/rand/RandomFirehoseFactory.java similarity index 99% rename from examples/src/main/java/druid/examples/rand/RandomFirehoseFactory.java rename to examples/src/main/java/io/druid/examples/rand/RandomFirehoseFactory.java index 6c02600650c..06df9ad5d99 100644 --- a/examples/src/main/java/druid/examples/rand/RandomFirehoseFactory.java +++ b/examples/src/main/java/io/druid/examples/rand/RandomFirehoseFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.rand; +package io.druid.examples.rand; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/examples/src/main/java/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java b/examples/src/main/java/io/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java similarity index 99% rename from examples/src/main/java/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java rename to examples/src/main/java/io/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java index dcb5915b8a0..20ca2074c8e 100644 --- a/examples/src/main/java/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java +++ b/examples/src/main/java/io/druid/examples/twitter/TwitterSpritzerFirehoseFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.twitter; +package io.druid.examples.twitter; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/examples/src/main/java/druid/examples/web/InputSupplierUpdateStream.java b/examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStream.java similarity index 99% rename from examples/src/main/java/druid/examples/web/InputSupplierUpdateStream.java rename to examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStream.java index 4546d8cb2a9..c558d8f998c 100644 --- a/examples/src/main/java/druid/examples/web/InputSupplierUpdateStream.java +++ b/examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStream.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.fasterxml.jackson.core.JsonParseException; import com.fasterxml.jackson.core.type.TypeReference; diff --git a/examples/src/main/java/druid/examples/web/InputSupplierUpdateStreamFactory.java b/examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStreamFactory.java similarity index 97% rename from examples/src/main/java/druid/examples/web/InputSupplierUpdateStreamFactory.java rename to examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStreamFactory.java index 52a9c47f6f4..6741ec7b870 100644 --- a/examples/src/main/java/druid/examples/web/InputSupplierUpdateStreamFactory.java +++ b/examples/src/main/java/io/druid/examples/web/InputSupplierUpdateStreamFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.io.InputSupplier; diff --git a/examples/src/main/java/druid/examples/web/RenamingKeysUpdateStream.java b/examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStream.java similarity index 98% rename from examples/src/main/java/druid/examples/web/RenamingKeysUpdateStream.java rename to examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStream.java index 2bd63e7f1f1..fd35aa3a233 100644 --- a/examples/src/main/java/druid/examples/web/RenamingKeysUpdateStream.java +++ b/examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStream.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.collect.Maps; diff --git a/examples/src/main/java/druid/examples/web/RenamingKeysUpdateStreamFactory.java b/examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStreamFactory.java similarity index 97% rename from examples/src/main/java/druid/examples/web/RenamingKeysUpdateStreamFactory.java rename to examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStreamFactory.java index 021088d982e..f30566041a8 100644 --- a/examples/src/main/java/druid/examples/web/RenamingKeysUpdateStreamFactory.java +++ b/examples/src/main/java/io/druid/examples/web/RenamingKeysUpdateStreamFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import java.util.Map; diff --git a/examples/src/main/java/druid/examples/web/UpdateStream.java b/examples/src/main/java/io/druid/examples/web/UpdateStream.java similarity index 97% rename from examples/src/main/java/druid/examples/web/UpdateStream.java rename to examples/src/main/java/io/druid/examples/web/UpdateStream.java index bb84fb0a9e1..0d64e8bde36 100644 --- a/examples/src/main/java/druid/examples/web/UpdateStream.java +++ b/examples/src/main/java/io/druid/examples/web/UpdateStream.java @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import java.util.Map; import java.util.concurrent.TimeUnit; diff --git a/examples/src/main/java/druid/examples/web/UpdateStreamFactory.java b/examples/src/main/java/io/druid/examples/web/UpdateStreamFactory.java similarity index 96% rename from examples/src/main/java/druid/examples/web/UpdateStreamFactory.java rename to examples/src/main/java/io/druid/examples/web/UpdateStreamFactory.java index c65685ba68b..8c7831237d7 100644 --- a/examples/src/main/java/druid/examples/web/UpdateStreamFactory.java +++ b/examples/src/main/java/io/druid/examples/web/UpdateStreamFactory.java @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; public interface UpdateStreamFactory { diff --git a/examples/src/main/java/druid/examples/web/WebFirehoseFactory.java b/examples/src/main/java/io/druid/examples/web/WebFirehoseFactory.java similarity index 99% rename from examples/src/main/java/druid/examples/web/WebFirehoseFactory.java rename to examples/src/main/java/io/druid/examples/web/WebFirehoseFactory.java index e4ae9ac4c1a..92ee64e76b1 100644 --- a/examples/src/main/java/druid/examples/web/WebFirehoseFactory.java +++ b/examples/src/main/java/io/druid/examples/web/WebFirehoseFactory.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; diff --git a/examples/src/main/java/druid/examples/web/WebJsonSupplier.java b/examples/src/main/java/io/druid/examples/web/WebJsonSupplier.java similarity index 98% rename from examples/src/main/java/druid/examples/web/WebJsonSupplier.java rename to examples/src/main/java/io/druid/examples/web/WebJsonSupplier.java index 093ca1ad3ca..cafb39c3214 100644 --- a/examples/src/main/java/druid/examples/web/WebJsonSupplier.java +++ b/examples/src/main/java/io/druid/examples/web/WebJsonSupplier.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.io.InputSupplier; import com.metamx.emitter.EmittingLogger; diff --git a/examples/src/main/resources/META-INF/services/io.druid.initialization.DruidModule b/examples/src/main/resources/META-INF/services/io.druid.initialization.DruidModule new file mode 100644 index 00000000000..3e8743ed2ed --- /dev/null +++ b/examples/src/main/resources/META-INF/services/io.druid.initialization.DruidModule @@ -0,0 +1 @@ +io.druid.examples.ExamplesDruidModule \ No newline at end of file diff --git a/examples/src/test/java/druid/examples/web/InputSupplierUpdateStreamTest.java b/examples/src/test/java/io/druid/examples/web/InputSupplierUpdateStreamTest.java similarity index 99% rename from examples/src/test/java/druid/examples/web/InputSupplierUpdateStreamTest.java rename to examples/src/test/java/io/druid/examples/web/InputSupplierUpdateStreamTest.java index a86d239806f..d076afd4e9a 100644 --- a/examples/src/test/java/druid/examples/web/InputSupplierUpdateStreamTest.java +++ b/examples/src/test/java/io/druid/examples/web/InputSupplierUpdateStreamTest.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.io.InputSupplier; import junit.framework.Assert; diff --git a/examples/src/test/java/druid/examples/web/RenamingKeysUpdateStreamTest.java b/examples/src/test/java/io/druid/examples/web/RenamingKeysUpdateStreamTest.java similarity index 99% rename from examples/src/test/java/druid/examples/web/RenamingKeysUpdateStreamTest.java rename to examples/src/test/java/io/druid/examples/web/RenamingKeysUpdateStreamTest.java index 86ba0476c8e..dc08e7fe471 100644 --- a/examples/src/test/java/druid/examples/web/RenamingKeysUpdateStreamTest.java +++ b/examples/src/test/java/io/druid/examples/web/RenamingKeysUpdateStreamTest.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.io.InputSupplier; import junit.framework.Assert; diff --git a/examples/src/test/java/druid/examples/web/TestCaseSupplier.java b/examples/src/test/java/io/druid/examples/web/TestCaseSupplier.java similarity index 97% rename from examples/src/test/java/druid/examples/web/TestCaseSupplier.java rename to examples/src/test/java/io/druid/examples/web/TestCaseSupplier.java index f4ae5ba0939..baf44a613d8 100644 --- a/examples/src/test/java/druid/examples/web/TestCaseSupplier.java +++ b/examples/src/test/java/io/druid/examples/web/TestCaseSupplier.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.io.InputSupplier; diff --git a/examples/src/test/java/druid/examples/web/WebFirehoseFactoryTest.java b/examples/src/test/java/io/druid/examples/web/WebFirehoseFactoryTest.java similarity index 99% rename from examples/src/test/java/druid/examples/web/WebFirehoseFactoryTest.java rename to examples/src/test/java/io/druid/examples/web/WebFirehoseFactoryTest.java index bb7f6b25a24..d8ee9c966c3 100644 --- a/examples/src/test/java/druid/examples/web/WebFirehoseFactoryTest.java +++ b/examples/src/test/java/io/druid/examples/web/WebFirehoseFactoryTest.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import com.google.common.collect.ImmutableMap; import com.google.common.collect.Lists; diff --git a/examples/src/test/java/druid/examples/web/WebJsonSupplierTest.java b/examples/src/test/java/io/druid/examples/web/WebJsonSupplierTest.java similarity index 97% rename from examples/src/test/java/druid/examples/web/WebJsonSupplierTest.java rename to examples/src/test/java/io/druid/examples/web/WebJsonSupplierTest.java index 5bb72e2af17..d80fd5479f9 100644 --- a/examples/src/test/java/druid/examples/web/WebJsonSupplierTest.java +++ b/examples/src/test/java/io/druid/examples/web/WebJsonSupplierTest.java @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -package druid.examples.web; +package io.druid.examples.web; import org.junit.Test; diff --git a/indexing-service/src/main/java/io/druid/indexing/common/index/EventReceiverFirehoseFactory.java b/indexing-service/src/main/java/io/druid/indexing/common/index/EventReceiverFirehoseFactory.java index d1ff387dd9e..d6af4474f70 100644 --- a/indexing-service/src/main/java/io/druid/indexing/common/index/EventReceiverFirehoseFactory.java +++ b/indexing-service/src/main/java/io/druid/indexing/common/index/EventReceiverFirehoseFactory.java @@ -63,6 +63,9 @@ public class EventReceiverFirehoseFactory implements FirehoseFactory private final MapInputRowParser parser; private final Optional chatHandlerProvider; + @Deprecated + private final EventReceiverFirehoseFactoryConfig config; + @JsonCreator public EventReceiverFirehoseFactory( @JsonProperty("serviceName") String serviceName, @@ -75,14 +78,17 @@ public class EventReceiverFirehoseFactory implements FirehoseFactory { // This code is here for backwards compatibility if (serviceName == null) { - serviceName = String.format("%s:%s", + this.serviceName = String.format( + "%s:%s", config.getFirehoseIdPrefix(), Preconditions.checkNotNull(firehoseId, "firehoseId") ); + this.config = config; + } else { + this.serviceName = Preconditions.checkNotNull(serviceName, "serviceName"); + this.config = null; } - this.serviceName = Preconditions.checkNotNull(serviceName, "serviceName"); - this.bufferSize = bufferSize == null || bufferSize <= 0 ? DEFAULT_BUFFER_SIZE : bufferSize; this.parser = Preconditions.checkNotNull(parser, "parser"); this.chatHandlerProvider = Optional.fromNullable(chatHandlerProvider); @@ -98,7 +104,6 @@ public class EventReceiverFirehoseFactory implements FirehoseFactory if (chatHandlerProvider.isPresent()) { log.info("Found chathandler of class[%s]", chatHandlerProvider.get().getClass().getName()); chatHandlerProvider.get().register(serviceName, firehose); - chatHandlerProvider.get().register(serviceName.replaceAll(".*:", ""), firehose); // rofl } else { log.info("No chathandler detected"); } @@ -112,6 +117,17 @@ public class EventReceiverFirehoseFactory implements FirehoseFactory return serviceName; } + @Deprecated + @JsonProperty("firehoseId") + public String getFirehoseId() + { + if (config != null) { + return serviceName.replaceFirst(config.getFirehoseIdPrefix(), ""); + } + + return null; + } + @JsonProperty public int getBufferSize() { diff --git a/services/pom.xml b/services/pom.xml index fbf2d9ffa71..f054753cc80 100644 --- a/services/pom.xml +++ b/services/pom.xml @@ -17,7 +17,8 @@ ~ along with this program; if not, write to the Free Software ~ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. --> - + 4.0.0 io.druid druid-services @@ -82,6 +83,16 @@ ${project.build.directory}/${project.artifactId}-${project.version}-selfcontained.jar + + + *:* + + META-INF/*.SF + META-INF/*.DSA + META-INF/*.RSA + + +