Professional OPC
Development Tools

logos

Online Forums

Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.

Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.

Do not use the Contact page for technical issues.

Best practice for subscribing to large numbers of tags

More
18 Feb 2021 09:32 - 18 Feb 2021 09:33 #9459 by support
Hello,
many thanks for your update. I am glad it has helped.

The licensing error is weirder, and even weirder is its suggested relation to Tasks, but you never know... If you get a reproducible case, I would be really interested in having it too - in which case we should be able to figure it out.

Ad 1: This will be with QuickOPC 2021.1 release. Date is not fixed yet. For rough information, it may be around April 2021.
Ad 2: See kb.opclabs.com/OPC_XML_Configuration . The actual properties you can set are all described in the Microsoft documentation.

Kind regards
Last edit: 18 Feb 2021 09:33 by support.

Please Log in or Create an account to join the conversation.

More
18 Feb 2021 04:16 #9458 by krito
Hi,

Just wanted to give you an update.
We've got it all working now using the pre-release version 5.60.0-rev15 nuget package.
I'm not sure why we were getting that weird licensing error, but it stopped when I removed some Task-related code that wrapped around the calls to SubscribeMultiple(). On another developer's machine we replicated the error but in that case we saw the same License error with slightly different code structure (still using Tasks though).

When I have some more time I'll see if I can reliably replicate the License error, and if I can then I'll provide the details.

Just a couple of questions:
1. When will the fix for the WCF HttpBindings be available as a stable nuget release?
2. Do you have an example of how to configure the HttpBinding through appsettings.json?

Regards

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 20:01 #9434 by support
I do not think that Thrading.Tasks usage can be related to the license problem.

If there is a possibility that you computer is up for more than 24 days, can you please reboot it and retest?
Explanation: The code to check the runtime duration is relatively simple, but it depends on 32-bit TickCount counter from the system, which wraps over after certain number of days (tick count starts at zero when the system boots). I have verified the code and the wrap-over appears to be handled correctly, but you never know...

Thank you

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 15:06 #9433 by krito
I'm doing all of this during my Visual Studio debugging sessions, so the host process is started at the same time as the IHostedService that runs the OPC client code.

Our code makes heavy use of async/await, and wraps alot of operations inside Threading.Tasks. Is there anything in the licensing that might get messed up from deeply nested threading?

I've been trying to get our existing project to work, but I think now I will strip it back down to the basics and see if I can get the subscriptions to work properly. I'll let you know what I find.

Regards

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 13:43 #9432 by support
Thank you.

Could't it be that the host *process* is kept running? The "runtime" in license checking code is not per EasyDAClient instance or anything a like. It starts counting when the *process* first uses the EasyDAClient, and it never resets - only in a new process it gets a new start.

Regards

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 13:21 #9431 by krito
Hi,

1. Yes, we're running on a trial license, and it appears to stop early.
2. We're using .NET Core 3.1
3. It's a .NET Core console app. The main AppHost runs one or more IHostedServices (aka BackgroundService classes), one of which is our OPC client that interfaces with the server/simulator. The app is intended to be deployed and run as a Windows Service.

Best Regards,

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 13:02 #9430 by support
Hello.

Not related to the problem with the license, but I would recommend to browse sequentially, but keep accumulating the tags obtained, and then subscribe to them all at once (or do it after a large number tags accumulate). But subscribing sequentially in chunks of 49 is probably slower than for example, subscribing in a chunk of 490 tags.

Best regards

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 12:59 #9429 by support
Hello,

1. So this actually *is* running on a trial license, but the problem is that it stops too early (not after 30- minutes as it should)? Or, do you provide a license key?

2. This is on Windows under .NET Core, right?

3. What kind of project is your app? Desktop app/Windows service/Web app/Web service/etc.

Note: It is very unusual. We have not had a problem like that before.

Please Log in or Create an account to join the conversation.

More
10 Feb 2021 12:47 #9428 by krito
Hi,

Thanks for providing the prerelease version. We've updated to the prerelease nuget package, and changed our code to sequentially browse each asset one-by-one, and subscribing to each asset's tags:
//pseudocode
foreach (var asset in assetList) //e.g. list of turbines
{
 string[] tags = browseTagsFor(asset); // each call here yields 49 tags
 subscribeMultiple(asset, tags); // uses a single EasyDAClient instance (not using Isolated mode or anything)
}

However, while the application is still going through the process of iterating over all the assets and setting up subscriptions, we're now getting license errors like the following:

2021-02-10 11:55:37.904 [WRN] [] Opc Item: {"tag":"Turbine.A25.BladeAngleC","dataValue":"Run time is over the limit in license \"Multipurpose\", serial number 1111111120. The license you are running (most likely trial version) does not provide valid data after certain time period expires. Note that after the component's process is simply restarted, valid data will be provided again. Obtain and install proper license to permanently resolve this error. [...]"}


This is happening after only 2-3 minutes of runtime. The application usually loops over the first 30 assets (out of a possible 110 in our simulator) and then we start to see these errors. I've tried to see if it's related to the total number of tags subscribed, but I've seen the error with as few as ~750 tags and as many as ~1700; there doesn't appear to be a consistent pattern.

I've also tried the latest stable nuget release 5.59.1055 but the same error occurs after a few minutes.

We're in the process of getting budget approval to purchase a site license, but that could take quite a few weeks.

Any ideas what could be wrong?

Best Regards

Please Log in or Create an account to join the conversation.

More
05 Feb 2021 10:46 #9398 by support
Hello,
please test with the prerelease package from www.nuget.org, it is labeled 5.60.0-rev15 .

Best regards

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.082 seconds