kafka-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tao tony <tonytao0...@outlook.com>
Subject Dose kafka connector rest aoi support multiple thread access?
Date Fri, 14 Dec 2018 03:05:28 GMT
Dear teams,

We use Kafka-1.1.0 connector to load data,And start a connector using 
rest api by application.

Before we start a connector,we'll check it was not  existed and then 
create it. This was  encapsulated in a Quartz job.And each connector  
had a job.

We use spring resttemplate as below:

       ResponseEntity<String> response = 
restTemplate.getForEntity(requestUrl, String.class);

But when the jobs running  at the same time, it often  throw two kinds  
exception: "404 Not Found " and " 409 Conflict ". "404 Not Found " is a 
normal exception,it meams the connector not existed.

I could not handle the " 409 Conflict " exception,it was happed when the 
connector service is running,so I could not judge it was a connector 
server exception or it was just the connector reject the request.

" 409 Conflict " also returned when I use curl to get connector list:

  curl -X GET
{"error_code":409,"message":"Cannot complete request momentarily due to 
stale configuration (typically caused by a concurrent config change)"}

Dear teams,how could I solve the problem?I'm not sure whether it was 
caused  by the connector rest api not support multiple thread access.


View raw message