Skip to content

Commit 6c3042d

Browse files
Increasing poll timeout
Increasing poll timeout to 10 secs
1 parent 46e33d3 commit 6c3042d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ncds-sdk/src/main/java/com/nasdaq/ncdsclient/internal/ReadSchemaTopic.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public ReadSchemaTopic(){
3535
public Schema readSchema(String topic) throws Exception {
3636
KafkaConsumer schemaConsumer= getConsumer("Control-"+getClientID(securityProps));
3737
schemaConsumer.subscribe(Collections.singletonList(controlSchemaName));
38-
Duration sec = Duration.ofSeconds(5);
38+
Duration sec = Duration.ofSeconds(10);
3939
Schema messageSchema = null;
4040
ConsumerRecord<String,GenericRecord> lastRecord=null;
4141

@@ -93,7 +93,7 @@ public Set<String> getTopics() throws Exception{
9393

9494
KafkaConsumer schemaConsumer= getConsumer("Control-"+getClientID(securityProps));
9595
schemaConsumer.subscribe(Collections.singletonList(controlSchemaName));
96-
Duration sec = Duration.ofSeconds(5);
96+
Duration sec = Duration.ofSeconds(10);
9797
while (true) {
9898
ConsumerRecords<String, GenericRecord> schemaRecords = schemaConsumer.poll(sec);
9999
if(schemaRecords.isEmpty()){
@@ -160,4 +160,4 @@ private Schema internalSchema (String topic) throws Exception {
160160
}
161161
}
162162

163-
}
163+
}

0 commit comments

Comments
 (0)