Hello, I have been running the below c# code snippet with the .net client SDK (version 5.1.0) against our Lightstreamer server version 7.2.2 and I kept getting invalid handshake and the connection kept switching to HTTP.
I tried ForcedTransport = "WS" and "WS-Streaming" as well but still no luck.

I tried the quickstart example on here, https://sdk.lightstreamer.com/ls-dot...les/intro.html and it worked fine with me.

Also I have a Java version (similar to the C# code below) and it works fine as well. It connects and I get status WS-Streaming back successfully. Somehow I can't make it work with the following though. Any idea what could be the reason?

using com.lightstreamer.client;
using Lightstreamer.DotNet.Logging.Log;

namespace ConsoleApp;

internal class Program
{
public static void Main()
{
LightstreamerClient.setLoggerProvider(new Log4NetLoggerProviderWrapper());

var client = new LightstreamerClient("https://myurl", "myAdapterSet")
{
connectionDetails =
{
User = "user",
Password = "token"
}
};
}
}


Log;

Session ID value changed to
Server Socket Name value changed to
Client IP value changed to
Server Instance Address value changed to
Opening new session ...
Cookies to be inserted for https://myurl/lightstreamer/create_s...ol=TLCP-2.1.0: <none>
Start message handler
Session ID value changed to Saff0bf8ac9a1ffc2M19aT4954759
Server Instance Address value changed to https://myurl/
Server Socket Name value changed to Lightstreamer HTTP Server
Client IP value changed to xxxxxx
Cookies to be inserted for https://myurl: <none>
WS upgrade error: Invalid handshake response getStatus: 404 Not Found
CONNECTED:STREAM-SENSING
Unable to establish session of the current type. Switching session type WS Streaming->prepare HTTP Streaming
Sending request to the server to force a rebind on the current connection during FIRST_BINDING
Cookies to be inserted for https://myurl/lightstreamer/control....ol=TLCP-2.1.0: <none>
Batch completed
CONNECTED:STREAM-SENSING
CONNECTED:STREAM-SENSING
Failed to switch session type. Starting new session prepare HTTP Streaming
Closing session new.switch.timeout.timeout.FIRST_BINDING.1
Sending request to the server to destroy the current session during FIRST_BINDING
Reset message handler
Session ID value changed to
Server Socket Name value changed to
Client IP value changed to
Server Instance Address value changed to
Stop Protocol
Protocol dismissed
Closing wsc
Session ID value changed to
Server Socket Name value changed to
Client IP value changed to
Server Instance Address value changed to
Opening new session ...
Cookies to be inserted for https://myurl/lightstreamer/create_s...ol=TLCP-2.1.0: <none>
Start message handler
Session ID value changed to Sd47a36c69c7bcb65M19aT5003510
Server Instance Address value changed to https://myurl/
Server Socket Name value changed to Lightstreamer HTTP Server
Client IP value changed to xxxxxxx
Cookies to be inserted for https://myurl/lightstreamer/bind_ses...ol=TLCP-2.1.0: <none>
Keepalive Interval value changed to 5000
CONNECTED:HTTP-STREAMING
CONNECTED:HTTP-STREAMING
CONNECTED:HTTP-STREAMING