src/LaunchDarkly.EventSource/EventSource.cs
/// <summary>
/// Initiates the request to the EventSource API and parses Server Sent Events received by the API.
/// </summary>
/// <returns>A <see cref="System.Threading.Tasks.Task"/> A task that represents the work queued to execute in the ThreadPool.</returns>
/// <exception cref="InvalidOperationException">The method was called after the connection <see cref="ReadyState"/> was Open or Connecting.</exception>
Initiates the request to the EventSource API and parses Server Sent Events received by the API.
Initiates the request to the EventSource API and parses Server Sent Events received by the API .
public async Task StartAsync()
        {
            var cancellationToken = _pendingRequest.Token;
            while (!cancellationToken.IsCancellationRequested)
            {
                MaybeWaitWithBackOff();
                try
                {
                    await ConnectToEventSourceAsync(cancellationToken);
                    _backOff.ResetReconnectAttemptCount();
                }
                catch (Exception e)
                {
                    _logger.ErrorFormat("Encountered an error connecting to EventSource: {0}", e, e.Message);
                    _logger.Debug("", e);
                }
            }
        }
public async Task StartAsync ( ) { var cancellationToken = _pendingRequest . Token ; while ( ! cancellationToken . IsCancellationRequested ) { MaybeWaitWithBackOff ( ) ; try { await ConnectToEventSourceAsync ( cancellationToken ) ; _backOff . ResetReconnectAttemptCount ( ) ; } catch ( Exception e ) { _logger . ErrorFormat ( " " , e , e . Message ) ; _logger . Debug ( " " , e ) ; } } }
Initiates the request to the EventSource API and parses Server Sent Events received by the API.
Initiates the request to the EventSource API and parses Server Sent Events received by the API .
A  A task that represents the work queued to execute in the ThreadPool.
A A task that represents the work queued to execute in the ThreadPool .
The method was called after the connection  was Open or Connecting.
The method was called after the connection was Open or Connecting .