more docs

This commit is contained in:
Radu Ioan Fericean
2012-01-28 18:57:33 +02:00
parent 4875228926
commit 105c082556
2 changed files with 10 additions and 1 deletions

View File

@@ -11,6 +11,9 @@ import (
var raterList *RaterList
/*
Handler for the statistics web client
*/
func handler(w http.ResponseWriter, r *http.Request) {
fmt.Fprint(w, "<html><body><ol>")
for addr, _ := range raterList.clientAddresses {
@@ -19,6 +22,9 @@ func handler(w http.ResponseWriter, r *http.Request) {
fmt.Fprint(w, "</ol></body></html>")
}
/*
The function that gets the information from the raters using balancer.
*/
func CallRater(key string) (reply string) {
err := errors.New("") //not nil value
for err != nil {

View File

@@ -1,7 +1,10 @@
package main
type Responder int
type Responder byte
/*
RPC method thet provides the external RPC interface for getting the rating information.
*/
func (r *Responder) Get(args string, replay *string) error {
*replay = CallRater(args)
return nil