In kafka server.properties, the host.name and advertised.host.name are set to 10.190.20.144,port is:9090.
And on the nginx server,the command:
telnet 10.190.20.144 9090
works fine.
my producer code as below:
broker_list = {
{ host = "10.190.20.144", port = 9090 },
....
}
local bp = producer:new(broker_list, { producer_type = "async" })
local ok, err = bp:send("test", key, message);
but when I send the request to nginx,I got the message in error.log below:
018/06/10 23:05:43 [error] 14518#0: [lua] producer.lua:258: buffered messages send to kafka err: no resolver defined to resolve "10.190.20.144 ", retryable: true, topic: test, partition_id: 76, length: 1, context: ngx.timer, client: 220.110.201.20, server: 0.0.0.0:80
even add resolver 114.114.114.114 or 8.8.8.8; in the nginx.conf ,but also can not send the message to kakfa.
In kafka server.properties, the host.name and advertised.host.name are set to 10.190.20.144,port is:9090. And on the nginx server,the command:
works fine.
my producer code as below: broker_list = { { host = "10.190.20.144", port = 9090 }, .... } local bp = producer:new(broker_list, { producer_type = "async" }) local ok, err = bp:send("test", key, message);
but when I send the request to nginx,I got the message in error.log below:
018/06/10 23:05:43 [error] 14518#0: [lua] producer.lua:258: buffered messages send to kafka err: no resolver defined to resolve "10.190.20.144 ", retryable: true, topic: test, partition_id: 76, length: 1, context: ngx.timer, client: 220.110.201.20, server: 0.0.0.0:80
even add
resolver 114.114.114.114
or8.8.8.8;
in the nginx.conf ,but also can not send the message to kakfa.how to resolve it?