diff --git a/server/graph.go b/server/graph.go
index 11b55b84fef483d16ff545bf50894444fdd58576..9406f760158029519ecf32edb07f7993c6dfc632 100644 (file)
--- a/server/graph.go
+++ b/server/graph.go
"fmt"
"io"
"net/http"
- "strings"
"time"
"code.google.com/p/plotinum/plot"
)
func (s *Server) graph(w http.ResponseWriter, req request) {
- if len(req.args) < 2 {
+ if len(req.args) != 2 {
s.internal(w, fmt.Errorf("Missing host/metric information"))
}
host := proto.EscapeString(req.args[0])
- metric := proto.EscapeString(strings.Join(req.args[1:], "/"))
+ metric := proto.EscapeString(req.args[1])
res, err := s.query(fmt.Sprintf("TIMESERIES %s.%s", host, metric))
if err != nil {
s.internal(w, fmt.Errorf("Failed to retrieve graph data: %v", err))