Skip to content

Fix server examples in documentation - #12

Open
albertalef wants to merge 1 commit into
socketry:mainfrom
albertalef:fix-server-example
Open

albertalef wants to merge 1 commit into
socketry:mainfrom
albertalef:fix-server-example

Conversation

@albertalef

@albertalef albertalef commented Oct 13, 2026 •

Copy link
Copy Markdown

In the Getting Started documentation, was being explained:

# Running a Server

require "async/http/server"
require "async/http/endpoint"

endpoint = Async::HTTP::Endpoint.parse("http://localhost:50051")
server = Async::HTTP::Server.for(endpoint, dispatcher)

Async do
	server.run
end

But this is no more the correct usage of Async::HTTP::Server.

Im changing the documentation to:

Async::HTTP::Server.new(dispatcher, endpoint)

Types of Changes

  • Maintenance.
  • Documentation.

Contribution

Signed-off-by: Albert Alef <albertalef@protonmail.com>
@albertalef
albertalef marked this pull request as ready for review October 13, 2026 21:32
@socketry socketry deleted a comment from albertalef Oct 15, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant