Experiencing Slow processing when large number of items are added in Subscription request #1674
Replies: 8 comments 25 replies
-
|
Here is the screenshot from Visual VM capturing CPU and Memory Usage:
|
Beta Was this translation helpful? Give feedback.
-
|
You'll have to share the details (code) of your test so that I can better understand it. I'm not sure what you're talking about with storing PublishRepsonses, those aren't delivered to any of the normal user callbacks. |
Beta Was this translation helpful? Give feedback.
-
|
When we use OpcUaClient.publishAsync(), we receive PublishResponse in return. |
Beta Was this translation helpful? Give feedback.
-
|
For now I can say there are 30 threads running in parallel, subscribing for 50 items each. Have you tested scenario like this? |
Beta Was this translation helpful? Give feedback.
-
|
Hi @kevinherron, I just checked the logs and found 1 exception which is coming continuously due to which I am not able to move ahead with subscriptions io.netty.handler.codec.EncoderException: java.lang.NullPointerException: Cannot invoke "org.eclipse.milo.opcua.stack.core.types.structured.SubscriptionAcknowledgement.getSubscriptionId()" because "value" is null: . I just debugged at my end and found that there is no null check in code (SubscriptionAcknowledgement.java)
I just fixed it at my end
and then it started working properly. Can you suggest something here? |
Beta Was this translation helpful? Give feedback.
-
|
Hi @kevinherron, To subscribe multiple items at same time, I am creting Subscription and over that subscription I am creating MonitoredItems. Now when I am trying to create MonitoredItems using the "createMonitoredItems()" method, I am getting "Bad_SubscriptionIdInvalid" from server (Sometimes it gets created correctly without any error but sometimes it just throws "Bad_SubscriptionIdInvalid"). Here the subscription is created
and when I am trying to create MonitoredItems then it is giving statuscode "Bad_SubscriptionIdInvalid"
Is this behavior server specific or something can be there from Eclipse Milo SDK end or Something from my code? Can you suggest something here? |
Beta Was this translation helpful? Give feedback.
-
|
Hi @kevinherron,
Is there any way to stop this? |
Beta Was this translation helpful? Give feedback.
-
|
Hi @kevinherron, I was able to restore the performance that I was getting with OPC UA Stack that I was using earlier. Thank you for the detailed support and guidance. I truly appreciate the time and effort you put into helping me. It made a real difference. |
Beta Was this translation helpful? Give feedback.









Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi @kevinherron,
I am using Milo SDK version 1.0.8 and I am trying to carry out a load test on Milo SDK.
I am trying to add 30 different subscription requests each containing 50 items using 30 parallel threads. I am using a queue to store the PublishResponse till earlier responses are processed.
After some time, my queue size goes on increasing and it takes up the whole heap space which results in Java Out of memory exception. I suspect this behaviour is because the Milo SDK is getting slower in processing requests.
I was using OPC UA Stack Legacy earlier and there I had tested for this scenario. There this scenario works properly.
I also tried for less items(Like 1 or 2 subscription requests with 50 items each) on milo SDK. There it is working properly, but as the number of client items increase, it gets slowed resulting in Java out of memory exception and in turn stopping the whole process.
Have you tested the Milo SDK for this kind of load?
Also, can you share with me a full fledged code example for this subscription from Client side?
Thanks,
Chirantan
Beta Was this translation helpful? Give feedback.
All reactions