Druid poor perfermance

Hi,

When I run the real-time node that consumes rabbitmq, druid loses performance.

Queries put 20 milliseconds when real-time node does not run pass to 4 seconds.

All nodes are in the same machine.

-------realtime.spec -------

[{

“dataSchema”: {

“dataSource”: “aaaaa”,

“parser”: {

“type”: “base64”,

“parseSpec”: {

“format”: “json”,

“timestampSpec”: {

“column”: “date”,

“format”: “auto”

},

“dimensionsSpec”: {

“dimensions”: [“accountId”, “itemId”, “recipientEmail”, “recipientId”, “kind”, “duration”, “browser”, “operatingSystem”, “listId”, “date”],

“dimensionExclusions”: ,

“spatialDimensions”:

}

}

},

“metricsSpec”: [{

“type”: “count”,

“name”: “count”

}, {

“type”: “doubleSum”,

“name”: “added”,

“fieldName”: “added”

}, {

“type”: “doubleSum”,

“name”: “doubleSumDration”,

“fieldName”: “duration”

}, {

“type”: “longSum”,

“name”: “longSumDration”,

“fieldName”: “duration”

}, {

“type”: “doubleSum”,

“name”: “deleted”,

“fieldName”: “deleted”

}, {

“type”: “doubleSum”,

“name”: “delta”,

“fieldName”: “delta”

}, {

“type”: “hyperUnique”,

“name”: “unique_email”,

“fieldName”: “email”

}, {

“type”: “hyperUnique”,

“name”: “unique_item”,

“fieldName”: “itemId”

}

],

“granularitySpec”: {

“type”: “uniform”,

“segmentGranularity”: “hour”,

“queryGranularity”: “NONE”

}

},

“ioConfig”: {

“type”: “realtime”,

“firehose”: {

“type”: “rabbitmq”,

“connection”: {

“host”: “xxxxx”,

“port”: “xxxxx”,

“username”: “xxxxx”,

“password”: “xxxxx”,

“virtualHost”: “xxxxx”,

“uri”: “xxxxx”

},

“config”: {

“exchange”: “xxxxx”,

“queue”: “xxxxx”,

“routingKey”: “#”,

“durable”: “true”,

“exclusive”: “false”,

“autoDelete”: “false”,

“maxRetries”: “5”,

“retryIntervalSeconds”: “1”,

“maxDurationSeconds”: “3”

}

},

“plumber”: {

“type”: “realtime”

}

},

“tuningConfig”: {

“type”: “realtime”,

“maxRowsInMemory”: 100,

“intermediatePersistPeriod”: “PT1H”,

“reportParseExceptions”: true,

“windowPeriod”: “PT1H”,

“segmentGranularity”: “hour”,

“basePersistDirectory”: “/var/realtime/basePersist”,

“rejectionPolicy”: {

“type”: “messageTime”

}

}

}]

---------- runtime.properties------

druid.host=127.0.0.1

druid.port=8087

com.metamx.emitter.logging=true

com.metamx.emitter.logging.level=info

druid.processing.formatString=processing_%s

druid.processing.numThreads=4

druid.processing.buffer.sizeBytes=10000000

druid.service=druid/realtime

druid.request.logging.dir=/var/druid

druid.realtime.specFile=realtime.spec

com.metamx.emitter.logging=true

com.metamx.emitter.logging.level=info

druid.paths.indexCache=/var/log/druid

com.metamx.aws.accessKey=dummy_access_key

com.metamx.aws.secretKey=dummy_secret_key

druid.pusher.s3.bucket=dummy_s3_bucket

druid.zk.service.host=localhost

druid.server.maxSize=30

druid.zk.paths.base=/druid

--------- jvm.config ------

-server

-Xms4g

-Xmx4g

-XX:MaxDirectMemorySize=4g

-Duser.timezone=UTC

-Dfile.encoding=UTF-8

-Djava.io.tmpdir=/var/tmp/druid

-Djava.util.logging.manager=org.apache.logging.log4j.jul.LogManager

Hi try to use the druid metrics to understand where are the issues and possible optimizations routes http://druid.io/docs/latest/operations/metrics.html

This page might have some nice hints http://druid.io/docs/latest/operations/performance-faq.html

to explore metrics druid has several emitters like log, http, graphite, statsD …

for instance graphite config docs can be found here http://druid.io/docs/latest/development/extensions-contrib/graphite.html