Skip to content

SignalR additional xml docs #7980

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 11, 2019
Merged

Conversation

analogrelay
Copy link
Contributor

Reviewed our xml docs as both ramping back up after leave and docathon. Things look pretty good, added a few things to some public methods.

@@ -985,11 +1010,17 @@ private async Task ReceiveLoop(ConnectionState connectionState)
}
}

/// <summary>
/// This method is for internal framework use and should not be called by user code.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or just make it private :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't want to bog this PR down with that, but I can just remove the doc comment. It was public in 2.2 so our standard policy is to deprecate it over one release first. See #7977 for more. I'll remove these changes and we can just discuss things there.

/// </summary>
/// <remarks>
/// If this event was triggered from a connection error, the <see cref="Exception"/> that occurred will be passed in as the
/// sole argument to this handler. If this event was triggered from a call to <see cref="StopAsync(CancellationToken)"/>, then
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might want to add the server closing the connection gracefully case here as well

/// <remarks>
/// SignalR connections can run on top of HTTP transports like WebSockets or Long Polling, or other non-HTTP transports. As a result,
/// this method can sometimes return <see langword="null"/> depending on the configuration of your application.
/// </remarks>
Copy link
Member

@halter73 halter73 Feb 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is a remark, beware that this won't show up in intellisense or the HttpConnectionContextExtensions generated docs. To see this you will have to got to the generated docs page dedicated exclusively to the GetHttpContext() method.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think I'll put or <see langword="null" /> if there is no HTTP context in the summary (and leave this remark that adds more detail).

@Eilon Eilon added the area-signalr Includes: SignalR clients and servers label Mar 1, 2019
@analogrelay analogrelay force-pushed the anurse/signalr-minor-xml-docs branch from 7db7b39 to 22e706c Compare March 1, 2019 21:56
@analogrelay
Copy link
Contributor Author

https://github.com/aspnet/AspNetCore/issues/7265 - which should now be skipped. Rerunning

@analogrelay
Copy link
Contributor Author

/azp run AspNetCore-helix-test

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

/// }
/// else
/// {
/// Console.WriteLine($"Connection closed due to an error: {exception.Message}");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: I normally prefer printing $"{exception}" over $"{exception.Message}" so you get the Exception type and stack trace too.

@analogrelay analogrelay merged commit 8759aa2 into master Mar 11, 2019
@analogrelay analogrelay deleted the anurse/signalr-minor-xml-docs branch May 1, 2019 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-signalr Includes: SignalR clients and servers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants