uber / uReplicator

Improvement of Apache Kafka Mirrormaker

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is it possible to change parameter num.of.producers via config file or command line arguments?

disserakt opened this issue · comments

Hi to all!
@yangy0000 - I found parameter num.of.producers in file
uReplicator-Worker/src/main/java/com/uber/stream/ureplicator/worker/Constants.java, but it is only listed in this file.
Is it possible to change the number of producers by changing this parameter num.of.producers via a some config file or command line argument?
I tried adding it to the configuration file helix.properties - but nothing came of it, num.of.producers was not taken to work.

Or the only option is to change num.of.producers in the source file
uReplicator-Worker/src/main/java/com/uber/stream/ureplicator/worker/Constants.java
and then build it?

I would be glad to hear any advice, thanks.

commented

yes, you can change num.of.producers in producer.properties

@yangy0000 - that's how - understood, thank you very much for the explanation!
I will check this. That is, producer.properties would look something like this?

############################# Producer Basics #############################

# list of brokers used for bootstrapping knowledge about the rest of the cluster
# format: host1:port1,host2:port2 ...
bootstrap.servers=kafka-ro-staging01.msk.ru:9092,kafka-ro-staging02.msk.ru:9092,kafka-ro-staging03.msk.ru:9092
client.id=ureplicator-producer-dev

# specify the compression codec for all data generated: none, gzip, snappy, lz4.
# the old config values work as well: 0, 1, 2, 3 for none, gzip, snappy, lz4, respectively
compression.type=none

# message encoder
key.serializer=org.apache.kafka.common.serialization.ByteArraySerializer
value.serializer=org.apache.kafka.common.serialization.ByteArraySerializer

# batch configs
acks=all
batch.size=12288
linger.ms=20
buffer.memory=52428800
max.request.size=5242880
send.buffer.bytes=20971520
max.in.flight.requests.per.connection=5
request.timeout.ms=30000

# number of producers
num.of.producers=4
commented

yes, it is