Troubleshoot Your Microsoft .NET Clients
This procedure provides troubleshooting information for the most common issues that occur when using Kaazing Microsoft .NET clients.
Before You Begin
This procedure is part of Checklist: Build Microsoft .NET WebSocket Clients.
Note: Learn about supported browsers, operating systems, and platform versions in the Release Notes.
To Troubleshoot Your Microsoft .NET Clients
The following are some things that can go wrong when using the .NET clients:
- Debug Log Produces an Error
- Delay to Initial Connection Request from the .NET Client
- .NET client has reached connection limit
Debug Log Produces an Error
When debugging an application from Visual Studio, the debug log gives you a disconnecting message or an error.
Cause
This message usually means that you are trying to debug an application from Visual Studio and using the incorrect cross-site-constraint to connect to Kaazing Gateway services.
Action
A cross-site-constraint of * is required to connect to Kaazing Gateway services when debugging applications from Visual Studio using a file:// based URL.
Delay to Initial Connection Request from the .NET Client
The initial WebSocket connection from the .NET client built using Kaazing client libraries for .NET is delayed by several seconds.
Cause
The delay may be caused by automatic proxy detection in Windows.
Action
To address this, if using Internet Explorer, choose Options > Connections tab > LAN Settings. Clear the Automatically Detect Settings checkbox and, if necessary, specify the proxy settings. In .NET applications, you can bypass the proxy settings by including the lineSystem.Net.WebRequest.DefaultWebProxy = null; beforethe client initiates the WebSocket connection. If your application requires a proxy, change the null value in this line to the default proxy or follow these instructions.
To get more troubleshooting information for your .NET clients, see Display Logs for .NET Clients.
.NET client has reached connection limit
The .NET client has reached a maximum connection limit per domain of two connections.
Cause
The Microsoft .NET 4.0 Framework has a maximum connection limit of two per domain, similar to the browser limitation.
Action
For any Microsoft .NET application that uses more than one WebSocket connection at a time, you must either ensure that any WebSocket connection is closed by using WebSocket.Close()
before opening another WebSocket connection, or increase the connection limit on the application by updating the maxconnection
attribute in the app.config
file. For more information about the error and tuning .NET client connections, see (KG-1851) Two Connection Limit in Kaazing Kaazing Clients for Microsoft .NET in Release Notes.
Next Step
You have completed the Microsoft .NET client procedures. For more information on client API development, see the .NET WebSocket Client API.