Play framework module using DDSL both as server and client
Java Python Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


Play Framework module for DDSL

January 14th 2013: Updated to use DDSL version 0.3.2

Plug-and-play cluster for Play

For info about DDSL

The play framework module DDSL brings DDSL to play 1.2.x..

(A Play 2.0 module is also available)

With DDSL you can create plug-and-play clusters with your play app both as server or client.

This is how easy it is to locate a service in your backend dynamic cluster:

String url = DDSL.getBestUrl( "PlayExampleServer", "1.0" );

This is how easy it is for your Play app to be part of the backend dynamic cluster:

#Set to true if you want to broadcast this play to DDSL
#Specify serviceId if ddsl.broadcastservice=true

If you need more server power, just start multiple play servers on new hardware - DDSL will automatically link it all together..

Try it

This example uses two play servers as servers/producers and one play app as client/consumer

Start the first server

  • cd into ddsl-playframework-module/ddsl-play-producer-example/
  • start it: ~/tools/play-1.2.5/play run

start the consumer

  • start a new console/terminal

  • cd into


  • start it:

  • (Assuming ~/tools/play-1.2.5/play is your valid path to play)

    ~/tools/play-1.2.5/play run

Go to http://localhost:9000/ with your browser. You can se that the consumer has "found" the server.

Then start another server

(This is just a copy of the first one with different http-port)

  • start a new console/terminal

  • cd into


  • start it:

    ~/tools/play-1.2.5/play run

Go back to http://localhost:9000/ with your browser. If you hit refresh several times you can se that you get response from both servers.

  • It is not round-robin but round-random Loadbalancing :)

  • If you only see one server, just keep retrying

  • You can add more servers if you like.

  • If you take one down, you will get some errors but after a couple of seconds The client will stop asking the server who went down.

  • The client is configured to cache each url for 1 second.