Orion context broker gets contextual performance

I have downloaded and installed the latest sources from Orion on my local Linux hardware. Basically everything works fine. But I am wondering if something can be done to get better performance. Whenever I process multiple entities (get an on / contextElement / id method) in a loop, say 100, it takes 50 to 100 milliseconds per entity, in this case more than 10 seconds to process the loop. If it ever has to be thousands or more, it will definitely take a long time for practical use.

Is there a way to improve performance? Why does a LAN request take such a relatively long time? Should I be looking for a performance issue on the client or broker side?

Thank you so much!

Cheers, Nicolas

+3


source to share


1 answer


You can find performance analysis in the Orion Installation and Administration Guide . However, please note the disclaimer:

Please note that this information is provided only as a hint, how to determine which indexes to use in yours, but the results in your particular environment may vary depending on the hardware profile, used for testing, setting the situation, etc.



However, 50-100ms per transaction (i.e. 10-20 TPS) seems to be very slow (note that in the TPS analysis, in the order of 100-1000 is reached). Thus, I would recommend some of the following tips:

  • On the server side, set up the correct indexes on the MongoDB instance used by Orion CB. As concluded in the above analysis, "it is highly recommended to set the index to _id.id on the entity collection." Read more about indexes in this section .
  • On the client side, you will get better performance if you run the entity creation query in parallel instead of a sequential loop.
+1


source







All Articles