Open sujaymansingh opened 10 years ago
If it helps, it seems that if I don't have any dashboards open in a browser, then it is able to shutdown properly.
vagrant@bigboard:/opt/bigboard/dashboard$ dashing start -d
vagrant@bigboard:/opt/bigboard/dashboard$ dashing stop
Sending QUIT signal to process 2155 ...
Exiting!
vagrant@bigboard:/opt/bigboard/dashboard$
But if I do have dashboards open, it can't shutdown.
vagrant@bigboard:/opt/bigboard/dashboard$ dashing start -d
vagrant@bigboard:/opt/bigboard/dashboard$ dashing stop
Sending QUIT signal to process 2188 ...
Waiting for 3 connection(s) to finish, can take up to 30 sec, CTRL+C to stop now
Timeout!
Sending KILL signal to process 2188 ...
vagrant@bigboard:/opt/bigboard/dashboard$
Actually, just doing some more testing, it looks like even if I get dashing
to save its data on exit, it's pointless because dashing
doesn't read from the history file on start up anyway.
At this point it looks like dashing
doesn't support persistence of data. Is there a plan to add this feature later?
I think what might be best is for me to write my own little wrapper around it that accepts data, saves it to a file and then pushes it to dashing
.
(And periodically it can send all data to dashing
. Unfortunately this looks like I'll lose the updated_at
values, but there is not much I can do at this point.)
:+1: would really like to persist the results
After my initial confusion about ruby version numbers (!) I managed to get dashing running. I am using dashing 1.3.1
I am trying to get dashing to save its history to a file.
Now let me clear the history file, just to be sure.
Running as a foreground app seems to save the history fine (I ran
curl -i -d '{"auth_token": "test", "current": 1}' http://33.33.33.60/widgets/Something
in a different shell.)As we can see,
Something
has been added.But, if I run it as a daemon, I get no love :( (Again running
curl -i -d '{"auth_token": "test", "current": 2}' http://33.33.33.60/widgets/Something
in a different shell.)What could the issue be here? I really don't know much (anything) about ruby, bundle or sinatra.
Is running dashing as a daemon not recommended?
Does
-d
run as a different user and thus cause crazy permissions issues? (Though even then it should work. I have mydashboard_data
dir pretty much open to anything.)