Skip to content

Update the README example with correct code #8

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,16 @@ function startEditorServers(ports) {
var CONFIG = {
'resources': [
{
// resource is some value identify this resource
// by default it should be the hostname to match
resource: 'localhost:8000',
// The name of the selector should
selector: loadfire.selectors.host('localhost:8000'),

// List of backends to hit
backends: EDITOR_SERVERS,

// Load balancing pattern
// As of now a few are builtin
// random, roundrobin, sticky
pattern: 'roundrobin'
balancer: loadfire.balancers.roundrobin,
}
],

Expand All @@ -80,7 +79,8 @@ function main() {
// Now start our load balancer
loadServer.run();

// Check out localhost:8000
// Check out localhost:8000 in a browser (must be localhost and not
// 127.0.0.1 - the name must match the selector name.
// Refresh a few times and you'll see different port numbers appear
// depending on which http server the requests are proxied to
// since we are using the roundrobin pattern it will cycle through them
Expand Down