Skip to content

RestSharp provides a timeout error (Status Code 0) when doing multiple simultaneous requests in multiple threads... #1489

@rajdeepg

Description

@rajdeepg

Expected Behavior

RestSharp provides a timeout error (Status Code 0) when doing multiple simultaneous requests in multiple threads. It would be nice to explain what the actual error is. We spent a few weeks debugging this issue and it turns out the way to fix this issue is to raise the default connection limit:

System.Net.ServicePointManager.DefaultConnectionLimit = 100;

Actual Behavior

It would have been nice if RestSharp indicate this as a problem with the ConnectionLimit instead of returning a timeout error (Status Code 0).

Steps to Reproduce the Problem

  1. Create 10 threads in a sample Windows application.
  2. Do a Get call to google.com or something.
    3.You will get the timeout error after a few minutes.

Specifications

  • Version: Latest Version
  • Platform: Windows
  • Subsystem: Windows 10

StackTrace

No Stack Trace

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions