GithubHelp home page GithubHelp logo

Comments (10)

asmuth avatar asmuth commented on April 28, 2024

Mh, looks like it can't find a namespace. Which url are you accessing in your browser, "http://localhost:4242/"? Can you maybe paste your server file? :)

from clip.

johnmcdowall avatar johnmcdowall commented on April 28, 2024

Full url is:
http://localhost:4242/myapp#Overview

It's just the example from the readme:

require "fnordmetric"

 FnordMetric.namespace :myapp do

   gauge :unicorns_seen_per_hour, 
     :tick => 1.hour.to_i, 
     :title => "Unicorns seenper Hour"

   event(:unicorn_seen) do
     incr :unicorns_seen_per_hour 
   end

   widget 'Overview', {
     :title => "Unicorn-Sightings per Hour",
     :type => :timeline,
     :gauges => :unicorns_seen_per_hour,
     :autoupdate => 30
   }

 end

 FnordMetric.standalone

from clip.

asmuth avatar asmuth commented on April 28, 2024

Ah, can you see the dashboard? If you can see the dashboard, but there is this error in the server output, then it's because your browser is requesting the favicon.ico-file and that's not properly handeled right now. (I will fix that)

from clip.

johnmcdowall avatar johnmcdowall commented on April 28, 2024

Yes, sorry, I can see the Dashboard, but no values are showing. I just realized that when I tried to do the logging step it failed (my server file is called test.rb):

ruby test.rb log
:public is no longer used to avoid overloading Module#public, use :public_folder instead
    from /Users/john/.rvm/gems/ruby-1.9.2-p290/gems/fnordmetric-0.5.2/lib/fnordmetric/app.rb:15:in `<class:App>'
usage: test.rb {run|log|import} [DUMP_FILE=fm_dump.json]

Will that stop the values from showing up?

I am generating events with:

echo "{'_type': 'unicorn_seen'}\n" | nc localhost 1337

And the server seems to be capturing values:

[11-12-26 20:52:10] events_received: 37, events_processed: 37, queue_length: 0
[11-12-26 20:52:13] events_received: 37, events_processed: 37, queue_length: 0
[11-12-26 20:52:16] events_received: 37, events_processed: 37, queue_length: 0

from clip.

asmuth avatar asmuth commented on April 28, 2024

The values should stil show up. Try moving the graph one step to the right/future (there are little arrow-buttons next to the date-input in the headbar) and make shure the current day/hour is actually visible. (The timeline widgets don't show the current day/hour/tick per default, so that the graphs don't always "go down" at the end. - you have to pass the :include_current => true option if you want that).

from clip.

johnmcdowall avatar johnmcdowall commented on April 28, 2024

Hmm. Yeah I've paged through the date time input and still nothing. Surely I should see a value here in the 9pm range:

Dashboard

The server shows so far:

[11-12-26 21:06:58] events_received: 54, events_processed: 54, queue_length: 0
[11-12-26 21:07:01] events_received: 54, events_processed: 54, queue_length: 0

from clip.

asmuth avatar asmuth commented on April 28, 2024

Mh, how are you submitting the events? I just tried with

echo "{\"_type\": \"unicorn_seen\"}" | nc localhost 1337

Also, can you maybe paste the output of

ruby test.rb log DUMP_FILE=/tmp/foo.json 

thanks :)

from clip.

johnmcdowall avatar johnmcdowall commented on April 28, 2024

Ah ha!

I just used your method for posting events which if you look above is different from the one in the readme.

Yours:
echo "{"_type": "unicorn_seen"}" | nc localhost 1337

Readme:
echo "{'_type': 'unicorn_seen'}\n" | nc localhost 1337

I am seeing values now. Thanks!

from clip.

asmuth avatar asmuth commented on April 28, 2024

Yes, I already updated it. Thanks for the feedback and please get back to me if you have any more questions or issues :)

from clip.

johnmcdowall avatar johnmcdowall commented on April 28, 2024

Sure thing - thanks for the great software!

from clip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.