Commit Graph

39 Commits

Author SHA1 Message Date
Con Kolivas
8631f33809 Accept ping requests on the various unix sockets 2014-05-12 22:49:39 +10:00
Con Kolivas
686d6da799 Send shutdown messages to the listener thread on watchdog shutdown or signal handling 2014-05-12 22:34:24 +10:00
Con Kolivas
75db39209f Abort trying to relaunch processes if we're relaunching them too fast 2014-05-12 22:09:06 +10:00
Con Kolivas
7ab22aa1ec Consider other modes of generator failure terminal and shut down 2014-05-12 21:56:59 +10:00
Con Kolivas
28f3f6cb2e Shut down more gracefully on startup failure 2014-05-12 21:51:18 +10:00
Con Kolivas
78fbb4e91d Make logging directory configurable, and store share logs by height/workid and totals for the pool as well 2014-05-03 22:04:42 +10:00
Con Kolivas
55045434f1 Make the start and minimum diff configurable and set them to 42 and 1 by default 2014-05-02 23:01:53 +10:00
Con Kolivas
a615b56d76 Install signal handlers which push the signal to the top process which will try to gracefully shut down each child process 2014-05-01 14:12:39 +10:00
Con Kolivas
78a3121668 Add signal handlers to enable terminate requests to end cleanly allowing profile generation 2014-05-01 12:30:43 +10:00
Con Kolivas
32f51fdceb Fix missing break 2014-04-29 13:44:46 +10:00
Con Kolivas
d8bb3380ae Add option to kill off old instance 2014-04-29 10:36:37 +10:00
Con Kolivas
c274457caa Add loglevel support with default of notice level, configurable on command line 2014-04-29 10:17:42 +10:00
Con Kolivas
fd2c51bed3 Restructure includes to only have ckpool instance and proc instance in ckpool.h 2014-04-29 09:57:17 +10:00
Con Kolivas
fefe13e929 Check for no response in the listener thread and allow 1 minute timeouts for receiving messages 2014-04-28 21:37:49 +10:00
Con Kolivas
0b08bbb43e Add submission of blocksolves 2014-04-27 20:51:09 +10:00
Con Kolivas
126c7964e2 Add a json parser to the stratum receiver that will generate return messages 2014-04-25 18:34:52 +10:00
Con Kolivas
55b8e8424a Add connector process which will process all remote communications 2014-04-23 14:38:34 +10:00
Con Kolivas
4ab9120e61 Handle failed generator startup as a fatal startup, sending listener a shutdown message and adding shutdown parsing 2014-04-23 13:07:04 +10:00
Con Kolivas
2b1f9510cf Add a block update thread that polls bitcoind regularly for the latest hash and handle failed json requests as closed sockets 2014-04-23 09:51:56 +10:00
Con Kolivas
8f0958bbfb Add some default parameters to make polling intervals configurable 2014-04-22 22:03:48 +10:00
Con Kolivas
a723e70f51 Remove signal handlers and use a watchdog thread to watch for dead child processes and restart them 2014-04-21 20:06:20 +10:00
Con Kolivas
0d3d2434be Use name for socket directory and add more config options 2014-04-21 18:36:22 +10:00
Con Kolivas
6f1838536c Create a stratifier thread that updates the data from the gbt template regularly and receives other requests 2014-04-21 15:58:07 +10:00
Con Kolivas
945c730447 Add and test a getbase function of the generator process 2014-04-21 14:13:12 +10:00
Con Kolivas
6f679e1cf4 Create the main read parse loop for the generator and send it a test message 2014-04-21 13:46:18 +10:00
Con Kolivas
194c8e42f3 Begin parsing of a config file, storing btcd url, auth and pass 2014-04-21 09:54:25 +10:00
Con Kolivas
15170c79d2 Original sighandlers don't actually come in useful here 2014-04-19 20:47:01 +10:00
Con Kolivas
219c49817e Install the signal handlers only for the master process and try to clean up in consistent fashion with handler 2014-04-19 20:22:53 +10:00
Con Kolivas
f864e1176c Install signal handlers and store the originals in the ckpool_t 2014-04-19 20:05:20 +10:00
Con Kolivas
2f7f3ecad4 Store the pid in the proc instance structure and try to clean up on processes exiting 2014-04-19 19:52:08 +10:00
Con Kolivas
10c2b48b4f Rename processes and change generator function to suit pi model 2014-04-19 19:36:50 +10:00
Con Kolivas
2c9653d138 Add a process structure to contain all variables likely to be used by spawned processes 2014-04-19 19:24:06 +10:00
Con Kolivas
9544d280e3 Launch generator process and abstract out more of the per process files created 2014-04-19 17:56:45 +10:00
Con Kolivas
e5d9d0a609 Use no global variables and append / to all directory names 2014-04-19 17:19:37 +10:00
Con Kolivas
8a23b0bb28 Write the pid to a temporary file 2014-04-19 17:14:22 +10:00
Con Kolivas
41bc9865c9 Begin basic main function parsing parameters, create a directory for sockets and create a listener thread 2014-04-19 12:56:45 +10:00
Con Kolivas
ef93d2760e Add some commonly used functions to a common header and check headers in configure.ac 2014-04-08 20:11:57 +10:00
Con Kolivas
2f961cc489 Add basic library creation rules 2014-04-08 16:10:21 +10:00
Con Kolivas
6e2edf7ee4 Basic build infrastructure 2014-04-08 15:42:24 +10:00