Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X
hello developers,
We have lots of edges running agent developed from C sdk, the agent will using twApi_InvokeService api to update the corresponding Thing model on Platform.
We have experienced a trouble that the platform seems out of resource to handle all the invoke service request from the edges issued simultaneously.
The symptoms is:
1. TW instance is responsive to the simple service invoke request slowly(like invoking Thing.getAvatarUrl), almost more than 1 minute),
2. after we shutdown all the edges, the platform seems still process the accumulated service invoking from the edges.
So my questions are:
1 How does TW instance behave when lots of service invoking request from edge is launched simultaneously, will they be queued and be processed in sequence? If the service invoking request is queueing, will this behavior lead to memory overload at the end?
2 If the service invoking request is achieving on the platform, what will happened when the edge is shut down, will the platform cancel the queueing service invoking request?
3 At the edge side, will the parameters "timeout" and "forceConnect" impact the queueing behavior?
I'm really looking forward to your answers.
Hi Mr. Zhang,
As I checked the invoke service should be asynchronous. Tomcat has a queue to manage the requests. And if the request are large, tomcat can get overload or even down.
Once the invoke service request is on Tomcat queue, it will be execute even edge SDK is shut down. Platform will not cancel the request.
The queue is not Tomcat side, so I guess parameters "timeout" and "forceConnect" on edge side will not impact the queue. (I don't have any evidence to make sure of this yet)
If ther are any detail you want to talk with me, please send email to me. lily.liu@thingworx.com
Lily
Dear Qiqiang Zhang,
Did you get your answer? Or do you get any hint from the answer Li Li Liu provided? If yes please mark her answer as Correct or Mark it as Helpful.
Thank you,
Br,
Anna