Kafka performance tunings

Change-Id: I78b6c9d9dba08549135fea9d604bdf5bc2431372
Signed-off-by: Illia Polliul <ipolliul@mirantis.com>
diff --git a/opencontrail/files/3.0/server.properties b/opencontrail/files/3.0/server.properties
index 091346c..5560f5c 100644
--- a/opencontrail/files/3.0/server.properties
+++ b/opencontrail/files/3.0/server.properties
@@ -63,7 +63,7 @@
 # The default number of log partitions per topic. More partitions allow greater
 # parallelism for consumption, but this will also result in more files across
 # the brokers.
-num.partitions=1
+num.partitions=30
 
 # The number of threads per data directory to be used for log recovery at startup and flushing at shutdown.
 # This value is recommended to be increased for installations with data dirs located in RAID array.
@@ -94,14 +94,14 @@
 # from the end of the log.
 
 # The minimum age of a log file to be eligible for deletion
-log.retention.hours=168
+log.retention.hours=24
 
 # A size-based retention policy for logs. Segments are pruned from the log as long as the remaining
 # segments don't drop below log.retention.bytes.
 #log.retention.bytes=1073741824
 
 # The maximum size of a log segment file. When this size is reached a new log segment will be created.
-log.segment.bytes=1073741824
+log.segment.bytes=268435456
 
 # The interval at which log segments are checked to see if they can be deleted according
 # to the retention policies
@@ -118,7 +118,10 @@
 zookeeper.connect={% for member in database.members %}{{ member.host }}:2181{% if not loop.last %},{% endif %}{% endfor %}
 
 # Timeout in ms for connecting to zookeeper
-log.cleanup.policy=compact
+log.cleanup.policy=delete
+log.cleaner.threads=2
+log.cleaner.dedupe.buffer.size=250000000
+
 delete.topic.enable=true
 
 default.replication.factor={% if database.members|length>1 %}2{% else %}1{% endif %}
diff --git a/opencontrail/files/4.0/server.properties b/opencontrail/files/4.0/server.properties
index 5cdaee6..a8ff61b 100644
--- a/opencontrail/files/4.0/server.properties
+++ b/opencontrail/files/4.0/server.properties
@@ -63,7 +63,7 @@
 # The default number of log partitions per topic. More partitions allow greater
 # parallelism for consumption, but this will also result in more files across
 # the brokers.
-num.partitions=1
+num.partitions=30
 
 # The number of threads per data directory to be used for log recovery at startup and flushing at shutdown.
 # This value is recommended to be increased for installations with data dirs located in RAID array.
@@ -94,14 +94,14 @@
 # from the end of the log.
 
 # The minimum age of a log file to be eligible for deletion
-log.retention.hours=168
+log.retention.hours=24
 
 # A size-based retention policy for logs. Segments are pruned from the log as long as the remaining
 # segments don't drop below log.retention.bytes.
 #log.retention.bytes=1073741824
 
 # The maximum size of a log segment file. When this size is reached a new log segment will be created.
-log.segment.bytes=1073741824
+log.segment.bytes=268435456
 
 # The interval at which log segments are checked to see if they can be deleted according
 # to the retention policies
@@ -118,5 +118,8 @@
 zookeeper.connect={% for member in database.members %}{{ member.host }}:2181{% if not loop.last %},{% endif %}{% endfor %}
 
 # Timeout in ms for connecting to zookeeper
-log.cleanup.policy=compact
+log.cleanup.policy=delete
+log.cleaner.threads=2
+log.cleaner.dedupe.buffer.size=250000000
+
 delete.topic.enable=true