cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X

How to improve connection server performance to reduce package lose rate

No ratings
  • There is a test on connection server 7.2. With 4core CPU and 8GB memory, we sent 1000 http requests every second and there is 5% http request losted. After changing configuration for connection server, the lost rate drop to 0.86%.
  • Here are some suggestions to improve connection server performance
  1. Reset parameters in connection server configuration file cxserver.conf. (..\conf\cxserver.conf)
    • Adjust parameters max-connection-pool-size and max-wait-queue-size
    • User-added image
  2. Change the default JVM settings. (increase memory for JVM properly)
    • In this case, I created a new file named startMyConnectionServer.bat file with below code:
      • SET CONNECTION_SERVER_HOME=C:\connection-server-7.2.0.2095

      • SET JAVA_OPTS=-Xms2G -Xmx2G

      • %CONNECTION_SERVER_HOME%\bin\connection-server.bat

  3. Increase connection server's hardware (memory, CPU cores)
Comments

Could you please specify which version of connection server? I thought I could figure it out from the linked pdf but that brings me to a ThingWorx Core pdf and it's not the same as the Connection Server. I'm pretty sure it's something > Connection Server 7.2 but I'm wondering which one exactly.

Do you have some supporting evidence as to why changing the max-connection-pool-size and max-wait-queue-size from the defaults made a tangible difference? Perhaps some data to share? I'd be very interested in your analysis and how you came to these conclusions.

I don't recommend changing the connection-server.bat file (or connection-server for linux). Instead I'd recommend you make a script that sets those variables in a shell and passes them into the Connection-Server by using the JAVA_OPTS path. If you modify the file you'll likely need to remember to make these changes every time you update the Connection Server code.

I oversee the product development team responsible for this product. I would appreciate any information you have to share Li Li Liu​.

Hi Clint,

Many thanks for your advice on my article. I've changed the location form Developer Community to ThingWorx Support Team Collaboration to validate. 

It's Connection Server 7.2. This article is a summary of my TS case. Customer doing pressure test on connection server. They sent 1000 http requests every second and there is 5% http request losted. After changing max-connection-pool-size and max-wait-queue-size and combine with increase JVM memory size, the lost rate drop to 0.86%. For your suggestion on JAVA_OPTS, I added it to the article and also give a more detail symptom.

If you have any furhter concern for this article, just feel free to let me know.

Again, I am really appreciated of your advices.

Best Regards,

Lily

Hello,

Was this post moved? Clint Dovholuk reached out to me and let me know that he can no longer access this post and therefore cannot reply.

Best,

Linda

Does this group think it would be useful for R&D to document our products with a "how to install the software as a service"? (i don't know if every product does this) I only ask because the proper way to do this is to make a script that calls the emessage.bat file. So i would make a "startMyConnectionServer.bat" and somehow make it a service (so that when the server restarts it starts) and I would specify it like:

{code}

SET CONNECTION_SERVER_HOME=c:\thingworx\connection-server

SET JAVA_OPTS="-Xms2G -Xmx2G"

%CONNECTION_SERVER_HOME%\bin\connection-server.bat

{code}

(something like that)

Editing the connection-server.bat is not recommended because you'll have to remember to update the file when you update the software.

Hi Clint,

Thanks. I updated your suggestion to my article.

BR,

Lily

Version history
Last update:
‎Aug 28, 2017 09:52 PM
Updated by: