Skip to content

Fix server examples in documentation - #12

Merged
samuel-williams-shopify merged 2 commits into
socketry:mainfrom
albertalef:fix-server-example
Oct 30, 2026
Merged

samuel-williams-shopify merged 2 commits into
socketry:mainfrom
albertalef:fix-server-example

Conversation

@albertalef

@albertalef albertalef commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

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
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@samuel-williams-shopify
samuel-williams-shopify merged commit 1b34af5 into socketry:main Oct 30, 2026
11 of 13 checks passed
@samuel-williams-shopify

Copy link
Copy Markdown
Contributor

Thanks!

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.

2 participants