.NET 6.0 support

Questions regarding the use of the .NET SDK 2.0 for Server or Client development or integration into customer products ...

Moderator: uasdknet

Post Reply
vluedeling
Jr. Member
Jr. Member
Posts: 1
Joined: 09 Sep 2020, 13:34

.NET 6.0 support

Post by vluedeling »

We are trying to integrate the .NET Server SDK version 3.1.0 into a new project which is based on .NET 6.0 but cannot get it to work. Clients cannot connect. UaExport (version 1.5.1) reports timeouts.

For testing purposes, we have written a small library which encapsulates the Unified Automation libraries, together with a simple console test program.

When we target .NET 5.0 with these projects, everything works fine. UaExpert can connect and we see the nodes we expect to see.

When we just switch the target platform to in the project files from net5.0 to net6.0, the solution continues to compile, but when we run it, UaExpert refuses to connect.

Have there been tests already with .NET 6.0? If not, when do you plan to release a version that is compatible with .NET 6.0?

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: .NET 6.0 support

Post by Support Team »

Hello,

when reading this:
https://documentation.unified-automation.com/uasdknet/3.1.0/html/L1Overview.html#intro_supported_frameworks_policies

including Note
Due to backwards compatibility our .NET Framework 4.8 and both .NET Standard assemblies already offer compatibility with Microsofts .NET5 Framework. But we cannot provide any support for it at the moment. Use it at your own risk.

I would consider NO, there were no tests ever done with .NET6 and most likely there were no test done with .NET5. In the compatibility table it says Standard 2.1 and Core 3.1 at the most. BTW capsulation Unified Automation libraries (for whatever reason) is not allowed due to license restrictions.

But yes, there is a plan to support .NET6 in the future, however as always we first wait until .NET6 is fully released, we do not test with any RC (release candidate) nor any pre-version.
Best regards
Unified Automation Support Team

jramirez-jh
Hero Member
Hero Member
Posts: 21
Joined: 14 Jun 2021, 23:39

Re: .NET 6.0 support

Post by jramirez-jh »

I'm also struggling with exactly the same problem, after doing some tests and tracing the network pakets using WireShark I've found that the SDK (running under .NET 6) is not able to open the port (socket) where the server is supposed to be listening.

This is very easy to confirm just executing the NETSTAT command on Windows to look for the open ports.

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: .NET 6.0 support

Post by Support Team »

Yes, we are aware of this issue.

It´s a problem of opening a TCP socket. This comes from a change in the behavior of a .Net class in .Net6.

A workaround would be to set the InternetProtocolVersion to IPv4Only or to set the NetworkInterface to "0.0.0.0". But this would limit the whole thing to IPv4.
For IPv4 and IPv6 working, the NetworkInterface would have to be set to "[::]".

A more detailed explanation of the NetworkInterface property can be found here:
https://documentation.unified-automation.com/uasdknet/3.1.0/html/L2BaseLibConfigSchema.html#L3NetworkInterfaceConfiguration
Best regards
Unified Automation Support Team

timothycorwin
Jr. Member
Jr. Member
Posts: 1
Joined: 20 Jan 2022, 22:21

Re: .NET 6.0 support

Post by timothycorwin »

Is there an ETA or roadmap for .NET 6.0 support? it is now generally available, the latest LTS release, and 3.1 will reach End of Support this December.
I would very much like to upgrade my OPC Servers before that time...

werenskjold
Jr. Member
Jr. Member
Posts: 1
Joined: 25 Oct 2022, 08:07

Re: .NET 6.0 support

Post by werenskjold »

Is there any updates on this issue?

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: .NET 6.0 support

Post by Support Team »

Hi,

please check out .NET SDK Version v3.2.x

At least the changelog says that .NET6 is supported since end of August.
Best regards
Unified Automation Support Team

Post Reply