Commit Graph

  • 71be121083 Microoptimise Con Kolivas 2015-02-08 08:38:10 +1100
  • ab4d3a672f Set notified flag to false immediately upon setting a new proxy Con Kolivas 2015-02-07 18:24:47 +1100
  • 64a3703f09 Move to pushing all notify data from the generator to avoid an extra message and reconnect clients once the current proxy has its first notification data Con Kolivas 2015-02-07 18:21:08 +1100
  • 1d69aa0ae9 Simplify send_subscribe code Con Kolivas 2015-02-07 17:45:25 +1100
  • 836f2f3ff2 Avoid extra call to get subscription from generator by pushing it with the subscribe message to the stratifier Con Kolivas 2015-02-07 17:41:47 +1100
  • 25d8c015e5 Add information about which proxy's socket is invalidated Con Kolivas 2015-02-07 15:06:12 +1100
  • db9a777767 Reconnect clients lazily on proxy switch once we receive another message from them and drop them if they don't disconnect on their own within a minute Con Kolivas 2015-02-07 14:46:43 +1100
  • 5665d54545 Test without dropping listen backlog Con Kolivas 2015-02-07 13:15:06 +1100
  • a80f9aa492 Don't miss dropping stratifier clients whose dropped flag is set when no reference count is held Con Kolivas 2015-02-07 11:49:14 +1100
  • f0f628df84 Reuse known ckp variable in drop_client Con Kolivas 2015-02-07 11:41:02 +1100
  • 289caa2732 Issue reconnect to generator immediately upon a reconnect request Con Kolivas 2015-02-07 11:29:28 +1100
  • 84a399adf0 Only send a notify request to the stratifier if it's from the current proxy Con Kolivas 2015-02-06 22:54:46 +1100
  • 37afa5fd02 Rename current_proxy in generator to best_proxy for clarity Con Kolivas 2015-02-06 22:47:54 +1100
  • 8825c7c901 Only give read socket line warning if proxy was considered alive at the time Con Kolivas 2015-02-06 22:42:41 +1100
  • c5b856ac7c Update notify after setting proxy before reconnecting clients Con Kolivas 2015-02-06 22:36:43 +1100
  • 32b88de36c Explicitly set the proxy in the stratifier when we switch and avoid creating workbases from backup proxies Con Kolivas 2015-02-06 22:35:26 +1100
  • c2fe4f30e1 Set proxies to not alive when their sockets invalidate and close sockets on reconnect being issued Con Kolivas 2015-02-06 21:56:48 +1100
  • cdc8efb0c4 Add message when proxy recovers Con Kolivas 2015-02-06 21:41:00 +1100
  • 042360bf40 Don't try to act on inactive clients Con Kolivas 2015-02-06 21:35:48 +1100
  • 14e3ed70c8 Don't try to act on inactive clients Con Kolivas 2015-02-06 21:35:48 +1100
  • 5a19bd0e4a Send a reconnect if we detect a changed subscription on the current proxy Con Kolivas 2015-02-06 21:19:21 +1100
  • 57e7916296 Demote unnecessary warning in stratifier to debug Con Kolivas 2015-02-06 21:08:29 +1100
  • 288e4b67bb Demote various messages in proxy mode but add more information to warnings Con Kolivas 2015-02-06 21:07:47 +1100
  • d8d9388b6c Add more information and demote messages for proxy send fails Con Kolivas 2015-02-06 20:55:08 +1100
  • 16fbfee068 Wiat 90 seconds before potentially failing over to a pool that has just recovered Con Kolivas 2015-02-06 20:52:40 +1100
  • fea1ea2953 Always update the subscription and notification details for every proxy updated, sending a reconnect instead when the proxy changes Con Kolivas 2015-02-06 20:33:56 +1100
  • d02862d1fe Update subscriptions and notifications for proxies that aren't the current proxy for faster switching Con Kolivas 2015-02-06 20:24:53 +1100
  • 520b36cc70 Send which proxy we wish to get a subscribe or notify to/from the connector to stratifier and whether to reconnect Con Kolivas 2015-02-06 19:17:45 +1100
  • f02a35dfcf Send notready message when notify data is not ready in the generator instead of no response Con Kolivas 2015-02-06 18:20:18 +1100
  • d474047d42 Drop proxy reference when socket invalidated Con Kolivas 2015-02-06 18:14:08 +1100
  • b7e71e1be7 Attach to every upstream pool in proxy mode all the time and fail over and back as needed Con Kolivas 2015-02-06 17:03:14 +1100
  • 52cd066563 Add proxies to the stratifier as its notified of their existence by the generator and issue reconnects without rejecting connections when a new subscribe is discovered Con Kolivas 2015-02-06 14:40:22 +1100
  • 622bd1541f Make stratifier data contain a pointer to the proxy data and add a hashlist to be able to add multiple proxies, allocating only one for now Con Kolivas 2015-02-06 13:45:41 +1100
  • 15351e5dde Proxy msg_id is not used in any meaningful way so remove it Con Kolivas 2015-02-06 12:00:34 +1100
  • c8268c3ef1 Merge branch 'proxydev' Con Kolivas 2015-02-05 17:19:41 +1100
  • 4e95186403 Improve warnings and verbosity for various proxy connection failures Con Kolivas 2015-02-05 16:16:51 +1100
  • 416b7a02eb Handle proxy failover correctly for remainder of upstream pools when a reconnect is issued and don't lose original pool details, demoting it to last instead Con Kolivas 2015-02-05 16:05:38 +1100
  • fcc4309561 Add info about proxies to warnings Con Kolivas 2015-02-05 14:35:11 +1100
  • 7f92dfbc7e Remove unnecessary warning Con Kolivas 2015-02-05 14:14:34 +1100
  • 20746db270 Check against chosen_server in the server watchdog Con Kolivas 2015-02-05 14:01:47 +1100
  • d66befef02 Don't reset the chosen_server value in live_proxy Con Kolivas 2015-02-05 13:56:21 +1100
  • 7e5a0620af Cache responses in proxy mode in case they come out of order to be able to successfully managed different subscribe variations Con Kolivas 2015-02-05 13:31:45 +1100
  • 9f07cc11e0 Export the char_entry_t type Con Kolivas 2015-02-05 12:08:08 +1100
  • 9dd3d95064 Fix dereference errors with dropall Con Kolivas 2015-02-05 11:58:52 +1100
  • 1a3ed51ba9 Fix workings when no serverurl is explicitly specified in config Con Kolivas 2015-02-05 11:29:58 +1100
  • dd160666de Do not mask SIGQUIT to allow us to force coredumps on child processes Con Kolivas 2015-02-05 11:20:39 +1100
  • 03b25370fe Check for client ref counts in dropall Con Kolivas 2015-02-05 10:49:41 +1100
  • 5dd35d6555 Fix workings when no serverurl is explicitly specified in config Con Kolivas 2015-02-05 11:29:58 +1100
  • 9863dedf59 Do not mask SIGQUIT to allow us to force coredumps on child processes Con Kolivas 2015-02-05 11:20:39 +1100
  • 745d95246c Check for client ref counts in dropall Con Kolivas 2015-02-05 10:49:41 +1100
  • 9c1e5f2332 Send reconnect instead of dropall to stratifier when killing an upstream proxy and drop them lazily Con Kolivas 2015-02-05 10:46:07 +1100
  • 1432b90829 Remove code talking to local btcd in proxy mode since we won't be able to submit any realistic block solves locally Con Kolivas 2015-02-05 10:29:18 +1100
  • a090bd6c26 Convert use of %ld to PRId64 in ckpool.c Con Kolivas 2015-02-05 10:09:13 +1100
  • 04f4f090e2 Convert use of %ld to PRId64 in connector Con Kolivas 2015-02-05 10:08:14 +1100
  • 67fd11bc13 Convert use of %ld to PRId64 in stratifier Con Kolivas 2015-02-05 10:06:37 +1100
  • 841d22ec05 Drop the server backlog to minimum after the pool has been accepting connections for 90 seconds Con Kolivas 2015-02-04 23:59:42 +1100
  • 78b2cf0277 Further fine grain the locking in the connector Con Kolivas 2015-02-04 23:46:47 +1100
  • 67c00d57c6 Fine grain the locking for read/write sections using the upgradeable variants in the stratifier where suitable Con Kolivas 2015-02-04 23:42:16 +1100
  • d94202dacb Avoid one cast Con Kolivas 2015-02-04 23:22:46 +1100
  • a7b2c3d8aa Shorten sleep interval while accept flag is not set Con Kolivas 2015-02-04 23:02:22 +1100
  • 6274371ccf Microoptimise epoll_wait call Con Kolivas 2015-02-04 23:10:59 +1100
  • bfbb9b574f Remove unused macro Con Kolivas 2015-02-04 22:47:24 +1100
  • 2d56e4fa04 Init the proxy share mutex ckolivas 2015-02-04 11:52:48 +1100
  • 33f40ed3cf Use 64 bits for share id in proxy ckolivas 2015-02-04 11:19:32 +1100
  • 6db343fec6 Fix 1st 10 minute preauth to still grab suggested diff and auth the rest Con Kolivas 2015-02-03 23:47:44 +1100
  • 0a616baa46 Don't send any preauths for already authorised users for the first 10 minutes after their first successful auth Con Kolivas 2015-02-03 23:32:45 +1100
  • 15787d8932 We may as well read the poolstats when not in standalone mode as well on restart since we may expose them Con Kolivas 2015-02-03 16:24:41 +1100
  • 5805e83fe1 Trivial comment update Con Kolivas 2015-02-03 15:16:15 +1100
  • 0d2d81baba Store and restore lastupdate stats by user and worker and use it to decay restored stats Con Kolivas 2015-02-03 14:55:13 +1100
  • baf9a6497d Store last update time by user and worker Con Kolivas 2015-02-03 14:38:33 +1100
  • 9d774a4f9b Store the lastupdate time with the pool stats and decay the value if it's been longer than 2 minutes Con Kolivas 2015-02-03 14:31:51 +1100
  • 6de132f0f0 Export json_get_int64 helper Con Kolivas 2015-02-03 13:59:36 +1100
  • 7990969af4 Read off pool stats on restarts in standalone mode instead of guessing the older hashrate by time bias Con Kolivas 2015-02-03 12:32:23 +1100
  • e465fb6d6e Don't try to discard passthrough clients to prevent derefs Con Kolivas 2015-02-03 08:21:46 +1100
  • 413f8f538a Remove dereferencing error of accessing authorised after client may be killed Con Kolivas 2015-02-02 22:46:23 +1100
  • 57cc749ae3 Guarantee reliable worker count by counting all clients once their user is recognised Con Kolivas 2015-02-02 22:14:33 +1100
  • 9341ffb640 Highest client id may not be reliable enough to prevent duplicate ids Con Kolivas 2015-02-02 22:01:57 +1100
  • a8d701df36 Discretely handle authorisation attempt to make it impossible to try and authorise twice Con Kolivas 2015-02-02 21:23:49 +1100
  • a29c423052 Trivial comment change Con Kolivas 2015-02-02 20:39:14 +1100
  • 880101ccbc Remove unnecessary extra list when clients are dead Con Kolivas 2015-02-02 19:13:01 +1100
  • f6ac71033c Disconnected and dead clients can't be holding a reference ckolivas 2015-02-02 13:15:26 +1100
  • 897df18c2f Send a whole update to a client instead of just the diff if they've only been sending rejects Con Kolivas 2015-02-01 17:58:11 +1100
  • b5fcff0bcb Optimise method parsing for the common case of shares first and do not allow clients to try and subscribe or authorise twice Con Kolivas 2015-02-01 17:54:55 +1100
  • d59787a0e5 Do lazy invalidation without parsing method Con Kolivas 2015-02-01 17:47:21 +1100
  • 12d9827ba1 Trivial comments Con Kolivas 2015-02-01 17:32:07 +1100
  • 2f53e6a004 Minor comment Con Kolivas 2015-02-01 15:34:06 +1100
  • 37b2f3a8b2 Fix minor memory leak when requesting stats Con Kolivas 2015-02-01 15:12:32 +1100
  • eacb000ad9 Elaborate on killing proxy message Con Kolivas 2015-02-01 15:04:37 +1100
  • 415e3864fa Handle old instance processes before forking any new ones for there to be no conflict with the stored pid numbers in the filenames Con Kolivas 2015-02-01 14:51:13 +1100
  • b1218a7cf0 Add config option to prioritise more clients than supporting clients with high hashrates Con Kolivas 2015-02-01 13:25:32 +1100
  • 60864c7bdf Fix symbol size warning Con Kolivas 2015-02-01 13:04:36 +1100
  • 43d1336321 Increment proxy count only after new proxy is set up Con Kolivas 2015-02-01 11:39:32 +1100
  • a7ed36931f Fix proxy reconnect potentially trying to switch proxies before the instance is fully set up and bypass old instances that have issued a reconnect Con Kolivas 2015-02-01 11:33:06 +1100
  • 9be8913f15 Merge branch 'master' of bitbucket.org:ckolivas/ckpool Con Kolivas 2015-02-01 00:02:54 +1100
  • 79bd0c0112 If these memory tricks are not good enough for valgrind they're not good enough for ckpool Con Kolivas 2015-01-31 23:52:38 +1100
  • 3ae83b4468 Merge branch 'master' of https://bitbucket.org/ckolivas/ckpool kanoi 2015-01-31 21:15:02 +1100
  • e4a55560f0 php - add colour explanation to the blocks page kanoi 2015-01-31 21:07:42 +1100
  • b44502b406 Merge branch 'master' of bitbucket.org:ckolivas/ckpool Con Kolivas 2015-01-31 14:13:29 +1100
  • 0c07ddb5ad Don't use client structure out of lock in connector's drop_client Con Kolivas 2015-01-31 14:12:06 +1100
  • 2c35501d6d ckdb - don't store auths in the db kanoi 2015-01-30 20:34:43 +1100