Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X
Hi All,
We are using Thingworx-common-6.0.2.jar and Thingworx 7.4.8-b39
We use single edge client connection to update properties of multiple remote things
code works OK when we test with 50 devices , we get below exception when tested with 500 devices
##############################################
code - com.thingworx.communications.client.ConnectedThingClient.java
public void bind(List<String> things)
/* */ throws Exception
/* */ {
/* 362 */ BindRequestMessage bind = new BindRequestMessage();
/* */
/* 364 */ bind.getRequestContext().setRequestId(UniqueID.globalCounter());
/* 365 */ bind.getRequestContext().setMethod(RESTAPIConstants.Method.BINDREQUEST);
/* 366 */ bind.getRequestContext().setNames(things);
/* */
/* 368 */ if ((StringUtilities.isNonEmpty(getClientConfigurator().getName())) && (StringUtilities.isNonEmpty(getClientConfigurator().getType()))) {
/* 369 */ bind.getRequestContext().setGatewayName(getClientConfigurator().getName());
/* 370 */ bind.getRequestContext().setGatewayType(getClientConfigurator().getType());
/* 371 */ bind.getRequestContext().getNames().add(bind.getRequestContext().getGatewayName());
/* */ }
/* */
/* 374 */ ResponseMessage response = getEndpoint().sendRequest(bind);
/* */
/* 376 */ if (response.getResponseContext().getResultCode() != RESTAPIConstants.StatusCode.STATUS_SUCCESS) {
/* 377 */ throw new Exception("Could not bind things: " + response.getResponseContext().getResultMessage());
/* */ }
/* */
/* 380 */ for (String thingName : things) {
/* 381 */ getThing(thingName).setBound(true);
/* */ }
/* */ }
#######################################
Error -
java.lang.Exception: Could not bind things: Client binding limit exceeded.
at com.thingworx.communications.client.ConnectedThingClient.bind(ConnectedThingClient.java:377)
at com.thingworx.communications.client.ConnectedThingClient.bind(ConnectedThingClient.java:342)
at com.thingworx.communications.client.ConnectedThingClient.bindThing(ConnectedThingClient.java:202)
at com.techm.tnt.protocol.gateway.brokerConsumer.KafkaRecordProcessor.updateDeviceData(KafkaRecordProcessor.java:181)
at com.techm.tnt.protocol.gateway.brokerConsumer.KafkaRecordProcessor.run(KafkaRecordProcessor.java:115)
at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)