nutcracker 0.2.4.10mac → 0.2.4.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (290) hide show
  1. data/ext/nutcracker/ChangeLog +0 -0
  2. data/ext/nutcracker/LICENSE +0 -0
  3. data/ext/nutcracker/Makefile.am +0 -0
  4. data/ext/nutcracker/Makefile.in +190 -82
  5. data/ext/nutcracker/NOTICE +0 -0
  6. data/ext/nutcracker/README.md +0 -0
  7. data/ext/nutcracker/aclocal.m4 +231 -122
  8. data/ext/nutcracker/conf/nutcracker.leaf.yml +0 -0
  9. data/ext/nutcracker/conf/nutcracker.root.yml +0 -0
  10. data/ext/nutcracker/conf/nutcracker.yml +0 -0
  11. data/ext/nutcracker/config/config.guess +278 -248
  12. data/ext/nutcracker/config/config.sub +234 -77
  13. data/ext/nutcracker/config/depcomp +143 -39
  14. data/ext/nutcracker/config/install-sh +136 -116
  15. data/ext/nutcracker/config/ltmain.sh +1704 -788
  16. data/ext/nutcracker/config/missing +29 -65
  17. data/ext/nutcracker/config.h.in +0 -15
  18. data/ext/nutcracker/configure +1998 -1052
  19. data/ext/nutcracker/configure.ac +2 -34
  20. data/ext/nutcracker/contrib/Makefile.am +0 -0
  21. data/ext/nutcracker/contrib/Makefile.in +120 -47
  22. data/ext/nutcracker/contrib/yaml-0.1.4.tar.gz +0 -0
  23. data/ext/nutcracker/extconf.rb +5 -0
  24. data/ext/nutcracker/m4/libtool.m4 +960 -396
  25. data/ext/nutcracker/m4/ltoptions.m4 +17 -2
  26. data/ext/nutcracker/m4/ltversion.m4 +6 -6
  27. data/ext/nutcracker/notes/c-styleguide.txt +0 -0
  28. data/ext/nutcracker/notes/debug.txt +0 -0
  29. data/ext/nutcracker/notes/memcache.txt +0 -0
  30. data/ext/nutcracker/notes/recommendation.md +0 -0
  31. data/ext/nutcracker/notes/redis.md +0 -0
  32. data/ext/nutcracker/notes/socket.txt +0 -0
  33. data/ext/nutcracker/scripts/nutcracker.init +0 -0
  34. data/ext/nutcracker/scripts/nutcracker.spec +0 -0
  35. data/ext/nutcracker/scripts/redis-check.py +0 -0
  36. data/ext/nutcracker/src/Makefile.am +1 -1
  37. data/ext/nutcracker/src/Makefile.in +167 -81
  38. data/ext/nutcracker/src/hashkit/Makefile.am +0 -0
  39. data/ext/nutcracker/src/hashkit/Makefile.in +72 -37
  40. data/ext/nutcracker/src/hashkit/nc_crc16.c +0 -0
  41. data/ext/nutcracker/src/hashkit/nc_crc32.c +0 -0
  42. data/ext/nutcracker/src/hashkit/nc_fnv.c +0 -0
  43. data/ext/nutcracker/src/hashkit/nc_hashkit.h +0 -0
  44. data/ext/nutcracker/src/hashkit/nc_hsieh.c +0 -0
  45. data/ext/nutcracker/src/hashkit/nc_jenkins.c +0 -0
  46. data/ext/nutcracker/src/hashkit/nc_ketama.c +0 -0
  47. data/ext/nutcracker/src/hashkit/nc_md5.c +0 -0
  48. data/ext/nutcracker/src/hashkit/nc_modula.c +0 -0
  49. data/ext/nutcracker/src/hashkit/nc_murmur.c +0 -0
  50. data/ext/nutcracker/src/hashkit/nc_one_at_a_time.c +0 -0
  51. data/ext/nutcracker/src/hashkit/nc_random.c +0 -0
  52. data/ext/nutcracker/src/nc.c +0 -0
  53. data/ext/nutcracker/src/nc_array.c +0 -0
  54. data/ext/nutcracker/src/nc_array.h +0 -0
  55. data/ext/nutcracker/src/nc_client.c +0 -0
  56. data/ext/nutcracker/src/nc_client.h +0 -0
  57. data/ext/nutcracker/src/nc_conf.c +0 -0
  58. data/ext/nutcracker/src/nc_conf.h +0 -0
  59. data/ext/nutcracker/src/nc_connection.c +0 -0
  60. data/ext/nutcracker/src/nc_connection.h +0 -0
  61. data/ext/nutcracker/src/nc_core.c +26 -29
  62. data/ext/nutcracker/src/nc_core.h +5 -13
  63. data/ext/nutcracker/src/{nc_epoll.c → nc_event.c} +30 -94
  64. data/ext/nutcracker/src/nc_event.h +13 -33
  65. data/ext/nutcracker/src/nc_log.c +0 -0
  66. data/ext/nutcracker/src/nc_log.h +0 -0
  67. data/ext/nutcracker/src/nc_mbuf.c +0 -0
  68. data/ext/nutcracker/src/nc_mbuf.h +0 -0
  69. data/ext/nutcracker/src/nc_message.c +0 -0
  70. data/ext/nutcracker/src/nc_message.h +0 -0
  71. data/ext/nutcracker/src/nc_proxy.c +8 -8
  72. data/ext/nutcracker/src/nc_proxy.h +0 -0
  73. data/ext/nutcracker/src/nc_queue.h +0 -0
  74. data/ext/nutcracker/src/nc_rbtree.c +0 -0
  75. data/ext/nutcracker/src/nc_rbtree.h +0 -0
  76. data/ext/nutcracker/src/nc_request.c +3 -3
  77. data/ext/nutcracker/src/nc_response.c +6 -4
  78. data/ext/nutcracker/src/nc_server.c +5 -5
  79. data/ext/nutcracker/src/nc_server.h +0 -0
  80. data/ext/nutcracker/src/nc_signal.c +0 -0
  81. data/ext/nutcracker/src/nc_signal.h +0 -0
  82. data/ext/nutcracker/src/nc_stats.c +21 -16
  83. data/ext/nutcracker/src/nc_stats.h +4 -3
  84. data/ext/nutcracker/src/nc_string.c +0 -0
  85. data/ext/nutcracker/src/nc_string.h +0 -0
  86. data/ext/nutcracker/src/nc_util.c +0 -16
  87. data/ext/nutcracker/src/nc_util.h +0 -1
  88. data/ext/nutcracker/src/proto/Makefile.am +0 -0
  89. data/ext/nutcracker/src/proto/Makefile.in +72 -37
  90. data/ext/nutcracker/src/proto/nc_memcache.c +0 -0
  91. data/ext/nutcracker/src/proto/nc_proto.h +0 -0
  92. data/ext/nutcracker/src/proto/nc_redis.c +0 -0
  93. data/lib/nutcracker/version.rb +1 -1
  94. metadata +8 -201
  95. data/ext/nutcracker/Makefile +0 -643
  96. data/ext/nutcracker/autom4te.cache/output.0 +0 -18664
  97. data/ext/nutcracker/autom4te.cache/output.1 +0 -18664
  98. data/ext/nutcracker/autom4te.cache/output.2 +0 -18664
  99. data/ext/nutcracker/autom4te.cache/requests +0 -494
  100. data/ext/nutcracker/autom4te.cache/traces.0 +0 -2415
  101. data/ext/nutcracker/autom4te.cache/traces.1 +0 -945
  102. data/ext/nutcracker/autom4te.cache/traces.2 +0 -2415
  103. data/ext/nutcracker/config.h +0 -332
  104. data/ext/nutcracker/config.log +0 -2684
  105. data/ext/nutcracker/config.status +0 -2317
  106. data/ext/nutcracker/contrib/Makefile +0 -494
  107. data/ext/nutcracker/contrib/yaml-0.1.4/Makefile +0 -736
  108. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.0 +0 -13102
  109. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.1 +0 -13085
  110. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/output.2 +0 -13085
  111. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/requests +0 -476
  112. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.0 +0 -2339
  113. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.1 +0 -545
  114. data/ext/nutcracker/contrib/yaml-0.1.4/autom4te.cache/traces.2 +0 -2339
  115. data/ext/nutcracker/contrib/yaml-0.1.4/config.h +0 -81
  116. data/ext/nutcracker/contrib/yaml-0.1.4/config.h.in~ +0 -80
  117. data/ext/nutcracker/contrib/yaml-0.1.4/config.log +0 -688
  118. data/ext/nutcracker/contrib/yaml-0.1.4/config.status +0 -2032
  119. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/annotated.html +0 -51
  120. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/bc_s.png +0 -0
  121. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/classes.html +0 -41
  122. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/closed.png +0 -0
  123. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/doxygen.css +0 -656
  124. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/doxygen.png +0 -0
  125. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/files.html +0 -40
  126. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions.html +0 -91
  127. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x62.html +0 -84
  128. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x63.html +0 -87
  129. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x64.html +0 -83
  130. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x65.html +0 -110
  131. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x66.html +0 -79
  132. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x68.html +0 -80
  133. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x69.html +0 -92
  134. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6b.html +0 -71
  135. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6c.html +0 -88
  136. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6d.html +0 -96
  137. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6e.html +0 -71
  138. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x6f.html +0 -80
  139. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x70.html +0 -100
  140. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x71.html +0 -71
  141. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x72.html +0 -87
  142. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x73.html +0 -163
  143. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x74.html +0 -115
  144. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x75.html +0 -71
  145. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x76.html +0 -80
  146. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_0x77.html +0 -77
  147. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars.html +0 -91
  148. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x62.html +0 -84
  149. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x63.html +0 -87
  150. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x64.html +0 -83
  151. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x65.html +0 -110
  152. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x66.html +0 -79
  153. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x68.html +0 -80
  154. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x69.html +0 -92
  155. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6b.html +0 -71
  156. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6c.html +0 -88
  157. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6d.html +0 -96
  158. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6e.html +0 -71
  159. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x6f.html +0 -80
  160. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x70.html +0 -100
  161. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x71.html +0 -71
  162. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x72.html +0 -87
  163. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x73.html +0 -163
  164. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x74.html +0 -115
  165. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x75.html +0 -71
  166. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x76.html +0 -80
  167. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/functions_vars_0x77.html +0 -77
  168. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals.html +0 -667
  169. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_defs.html +0 -81
  170. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_enum.html +0 -78
  171. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_eval.html +0 -373
  172. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_func.html +0 -196
  173. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/globals_type.html +0 -126
  174. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__basic.html +0 -320
  175. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__emitter.html +0 -819
  176. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__events.html +0 -664
  177. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__export.html +0 -60
  178. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__nodes.html +0 -795
  179. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__parser.html +0 -606
  180. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__styles.html +0 -222
  181. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__tokens.html +0 -246
  182. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/group__version.html +0 -106
  183. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/index.html +0 -31
  184. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/modules.html +0 -42
  185. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/nav_f.png +0 -0
  186. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/nav_h.png +0 -0
  187. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/open.png +0 -0
  188. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__alias__data__s.html +0 -108
  189. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__document__s.html +0 -235
  190. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__emitter__s.html +0 -1300
  191. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__event__s.html +0 -496
  192. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__mark__s.html +0 -108
  193. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__node__pair__s.html +0 -91
  194. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__node__s.html +0 -420
  195. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__parser__s.html +0 -1229
  196. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__simple__key__s.html +0 -97
  197. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__tag__directive__s.html +0 -91
  198. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__token__s.html +0 -413
  199. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/structyaml__version__directive__s.html +0 -91
  200. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_a.png +0 -0
  201. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_b.png +0 -0
  202. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_h.png +0 -0
  203. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tab_s.png +0 -0
  204. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/tabs.css +0 -59
  205. data/ext/nutcracker/contrib/yaml-0.1.4/doc/html/yaml_8h.html +0 -525
  206. data/ext/nutcracker/contrib/yaml-0.1.4/include/Makefile.am +0 -17
  207. data/ext/nutcracker/contrib/yaml-0.1.4/include/Makefile.in +0 -470
  208. data/ext/nutcracker/contrib/yaml-0.1.4/libtool +0 -8890
  209. data/ext/nutcracker/contrib/yaml-0.1.4/src/Makefile +0 -484
  210. data/ext/nutcracker/contrib/yaml-0.1.4/src/api.lo +0 -12
  211. data/ext/nutcracker/contrib/yaml-0.1.4/src/api.o +0 -0
  212. data/ext/nutcracker/contrib/yaml-0.1.4/src/dumper.lo +0 -12
  213. data/ext/nutcracker/contrib/yaml-0.1.4/src/dumper.o +0 -0
  214. data/ext/nutcracker/contrib/yaml-0.1.4/src/emitter.lo +0 -12
  215. data/ext/nutcracker/contrib/yaml-0.1.4/src/emitter.o +0 -0
  216. data/ext/nutcracker/contrib/yaml-0.1.4/src/libyaml.la +0 -41
  217. data/ext/nutcracker/contrib/yaml-0.1.4/src/loader.lo +0 -12
  218. data/ext/nutcracker/contrib/yaml-0.1.4/src/loader.o +0 -0
  219. data/ext/nutcracker/contrib/yaml-0.1.4/src/parser.lo +0 -12
  220. data/ext/nutcracker/contrib/yaml-0.1.4/src/parser.o +0 -0
  221. data/ext/nutcracker/contrib/yaml-0.1.4/src/reader.lo +0 -12
  222. data/ext/nutcracker/contrib/yaml-0.1.4/src/reader.o +0 -0
  223. data/ext/nutcracker/contrib/yaml-0.1.4/src/scanner.lo +0 -12
  224. data/ext/nutcracker/contrib/yaml-0.1.4/src/scanner.o +0 -0
  225. data/ext/nutcracker/contrib/yaml-0.1.4/src/writer.lo +0 -12
  226. data/ext/nutcracker/contrib/yaml-0.1.4/src/writer.o +0 -0
  227. data/ext/nutcracker/contrib/yaml-0.1.4/stamp-h1 +0 -1
  228. data/ext/nutcracker/contrib/yaml-0.1.4/tests/Makefile +0 -675
  229. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor +0 -0
  230. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor-alt +0 -0
  231. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor-alt.o +0 -0
  232. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-deconstructor.o +0 -0
  233. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter +0 -0
  234. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter-alt +0 -0
  235. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter-alt.o +0 -0
  236. data/ext/nutcracker/contrib/yaml-0.1.4/tests/example-reformatter.o +0 -0
  237. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-dumper +0 -0
  238. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-dumper.o +0 -0
  239. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-emitter +0 -0
  240. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-emitter.o +0 -0
  241. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-loader +0 -0
  242. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-loader.o +0 -0
  243. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-parser +0 -0
  244. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-parser.o +0 -0
  245. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-scanner +0 -0
  246. data/ext/nutcracker/contrib/yaml-0.1.4/tests/run-scanner.o +0 -0
  247. data/ext/nutcracker/contrib/yaml-0.1.4/yaml-0.1.pc +0 -10
  248. data/ext/nutcracker/contrib/yaml-0.1.4/yaml-0.1.pc.in +0 -10
  249. data/ext/nutcracker/libtool +0 -9403
  250. data/ext/nutcracker/src/Makefile +0 -647
  251. data/ext/nutcracker/src/hashkit/Makefile +0 -476
  252. data/ext/nutcracker/src/hashkit/libhashkit.a +0 -0
  253. data/ext/nutcracker/src/hashkit/nc_crc16.o +0 -0
  254. data/ext/nutcracker/src/hashkit/nc_crc32.o +0 -0
  255. data/ext/nutcracker/src/hashkit/nc_fnv.o +0 -0
  256. data/ext/nutcracker/src/hashkit/nc_hsieh.o +0 -0
  257. data/ext/nutcracker/src/hashkit/nc_jenkins.o +0 -0
  258. data/ext/nutcracker/src/hashkit/nc_ketama.o +0 -0
  259. data/ext/nutcracker/src/hashkit/nc_md5.o +0 -0
  260. data/ext/nutcracker/src/hashkit/nc_modula.o +0 -0
  261. data/ext/nutcracker/src/hashkit/nc_murmur.o +0 -0
  262. data/ext/nutcracker/src/hashkit/nc_one_at_a_time.o +0 -0
  263. data/ext/nutcracker/src/hashkit/nc_random.o +0 -0
  264. data/ext/nutcracker/src/nc.o +0 -0
  265. data/ext/nutcracker/src/nc_array.o +0 -0
  266. data/ext/nutcracker/src/nc_client.o +0 -0
  267. data/ext/nutcracker/src/nc_conf.o +0 -0
  268. data/ext/nutcracker/src/nc_connection.o +0 -0
  269. data/ext/nutcracker/src/nc_core.o +0 -0
  270. data/ext/nutcracker/src/nc_epoll.o +0 -0
  271. data/ext/nutcracker/src/nc_kqueue.c +0 -296
  272. data/ext/nutcracker/src/nc_kqueue.o +0 -0
  273. data/ext/nutcracker/src/nc_log.o +0 -0
  274. data/ext/nutcracker/src/nc_mbuf.o +0 -0
  275. data/ext/nutcracker/src/nc_message.o +0 -0
  276. data/ext/nutcracker/src/nc_proxy.o +0 -0
  277. data/ext/nutcracker/src/nc_rbtree.o +0 -0
  278. data/ext/nutcracker/src/nc_request.o +0 -0
  279. data/ext/nutcracker/src/nc_response.o +0 -0
  280. data/ext/nutcracker/src/nc_server.o +0 -0
  281. data/ext/nutcracker/src/nc_signal.o +0 -0
  282. data/ext/nutcracker/src/nc_stats.o +0 -0
  283. data/ext/nutcracker/src/nc_string.o +0 -0
  284. data/ext/nutcracker/src/nc_util.o +0 -0
  285. data/ext/nutcracker/src/nutcracker +0 -0
  286. data/ext/nutcracker/src/proto/Makefile +0 -454
  287. data/ext/nutcracker/src/proto/libproto.a +0 -0
  288. data/ext/nutcracker/src/proto/nc_memcache.o +0 -0
  289. data/ext/nutcracker/src/proto/nc_redis.o +0 -0
  290. data/ext/nutcracker/stamp-h1 +0 -1
@@ -1,8 +1,9 @@
1
- # Makefile.in generated by automake 1.10 from Makefile.am.
1
+ # Makefile.in generated by automake 1.11.3 from Makefile.am.
2
2
  # @configure_input@
3
3
 
4
4
  # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
5
- # 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
5
+ # 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
6
+ # Foundation, Inc.
6
7
  # This Makefile.in is free software; the Free Software Foundation
7
8
  # gives unlimited permission to copy and/or distribute it,
8
9
  # with or without modifications, as long as this notice is preserved.
@@ -17,8 +18,9 @@
17
18
 
18
19
  VPATH = @srcdir@
19
20
  pkgdatadir = $(datadir)/@PACKAGE@
20
- pkglibdir = $(libdir)/@PACKAGE@
21
21
  pkgincludedir = $(includedir)/@PACKAGE@
22
+ pkglibdir = $(libdir)/@PACKAGE@
23
+ pkglibexecdir = $(libexecdir)/@PACKAGE@
22
24
  am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
23
25
  install_sh_DATA = $(install_sh) -c -m 644
24
26
  install_sh_PROGRAM = $(install_sh) -c
@@ -46,6 +48,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
46
48
  mkinstalldirs = $(install_sh) -d
47
49
  CONFIG_HEADER = $(top_builddir)/config.h
48
50
  CONFIG_CLEAN_FILES =
51
+ CONFIG_CLEAN_VPATH_FILES =
49
52
  LIBRARIES = $(noinst_LIBRARIES)
50
53
  ARFLAGS = cru
51
54
  libhashkit_a_AR = $(AR) $(ARFLAGS)
@@ -56,9 +59,10 @@ am_libhashkit_a_OBJECTS = nc_crc16.$(OBJEXT) nc_crc32.$(OBJEXT) \
56
59
  nc_murmur.$(OBJEXT) nc_one_at_a_time.$(OBJEXT) \
57
60
  nc_random.$(OBJEXT)
58
61
  libhashkit_a_OBJECTS = $(am_libhashkit_a_OBJECTS)
59
- DEFAULT_INCLUDES = -I. -I$(top_builddir)@am__isrc@
62
+ DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
60
63
  depcomp = $(SHELL) $(top_srcdir)/config/depcomp
61
64
  am__depfiles_maybe = depfiles
65
+ am__mv = mv -f
62
66
  COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
63
67
  $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
64
68
  LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
@@ -93,6 +97,7 @@ CXXFLAGS = @CXXFLAGS@
93
97
  CYGPATH_W = @CYGPATH_W@
94
98
  DEFS = @DEFS@
95
99
  DEPDIR = @DEPDIR@
100
+ DLLTOOL = @DLLTOOL@
96
101
  DSYMUTIL = @DSYMUTIL@
97
102
  DUMPBIN = @DUMPBIN@
98
103
  ECHO_C = @ECHO_C@
@@ -116,6 +121,7 @@ LIPO = @LIPO@
116
121
  LN_S = @LN_S@
117
122
  LTLIBOBJS = @LTLIBOBJS@
118
123
  MAKEINFO = @MAKEINFO@
124
+ MANIFEST_TOOL = @MANIFEST_TOOL@
119
125
  MKDIR_P = @MKDIR_P@
120
126
  NM = @NM@
121
127
  NMEDIT = @NMEDIT@
@@ -141,6 +147,7 @@ abs_builddir = @abs_builddir@
141
147
  abs_srcdir = @abs_srcdir@
142
148
  abs_top_builddir = @abs_top_builddir@
143
149
  abs_top_srcdir = @abs_top_srcdir@
150
+ ac_ct_AR = @ac_ct_AR@
144
151
  ac_ct_CC = @ac_ct_CC@
145
152
  ac_ct_CXX = @ac_ct_CXX@
146
153
  ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
@@ -216,14 +223,14 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
216
223
  @for dep in $?; do \
217
224
  case '$(am__configure_deps)' in \
218
225
  *$$dep*) \
219
- cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
220
- && exit 0; \
226
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
227
+ && { if test -f $@; then exit 0; else break; fi; }; \
221
228
  exit 1;; \
222
229
  esac; \
223
230
  done; \
224
- echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/hashkit/Makefile'; \
225
- cd $(top_srcdir) && \
226
- $(AUTOMAKE) --foreign src/hashkit/Makefile
231
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/hashkit/Makefile'; \
232
+ $(am__cd) $(top_srcdir) && \
233
+ $(AUTOMAKE) --foreign src/hashkit/Makefile
227
234
  .PRECIOUS: Makefile
228
235
  Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
229
236
  @case '$?' in \
@@ -241,10 +248,11 @@ $(top_srcdir)/configure: $(am__configure_deps)
241
248
  cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
242
249
  $(ACLOCAL_M4): $(am__aclocal_m4_deps)
243
250
  cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
251
+ $(am__aclocal_m4_deps):
244
252
 
245
253
  clean-noinstLIBRARIES:
246
254
  -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
247
- libhashkit.a: $(libhashkit_a_OBJECTS) $(libhashkit_a_DEPENDENCIES)
255
+ libhashkit.a: $(libhashkit_a_OBJECTS) $(libhashkit_a_DEPENDENCIES) $(EXTRA_libhashkit_a_DEPENDENCIES)
248
256
  -rm -f libhashkit.a
249
257
  $(libhashkit_a_AR) libhashkit.a $(libhashkit_a_OBJECTS) $(libhashkit_a_LIBADD)
250
258
  $(RANLIB) libhashkit.a
@@ -269,21 +277,21 @@ distclean-compile:
269
277
 
270
278
  .c.o:
271
279
  @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
272
- @am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
280
+ @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
273
281
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
274
282
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
275
283
  @am__fastdepCC_FALSE@ $(COMPILE) -c $<
276
284
 
277
285
  .c.obj:
278
286
  @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
279
- @am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
287
+ @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
280
288
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
281
289
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
282
290
  @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'`
283
291
 
284
292
  .c.lo:
285
293
  @am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
286
- @am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
294
+ @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
287
295
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
288
296
  @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
289
297
  @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<
@@ -299,45 +307,49 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
299
307
  unique=`for i in $$list; do \
300
308
  if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
301
309
  done | \
302
- $(AWK) ' { files[$$0] = 1; } \
303
- END { for (i in files) print i; }'`; \
310
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
311
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
304
312
  mkid -fID $$unique
305
313
  tags: TAGS
306
314
 
307
315
  TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
308
316
  $(TAGS_FILES) $(LISP)
309
- tags=; \
317
+ set x; \
310
318
  here=`pwd`; \
311
319
  list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
312
320
  unique=`for i in $$list; do \
313
321
  if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
314
322
  done | \
315
- $(AWK) ' { files[$$0] = 1; } \
316
- END { for (i in files) print i; }'`; \
317
- if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
323
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
324
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
325
+ shift; \
326
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
318
327
  test -n "$$unique" || unique=$$empty_fix; \
319
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
320
- $$tags $$unique; \
328
+ if test $$# -gt 0; then \
329
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
330
+ "$$@" $$unique; \
331
+ else \
332
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
333
+ $$unique; \
334
+ fi; \
321
335
  fi
322
336
  ctags: CTAGS
323
337
  CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
324
338
  $(TAGS_FILES) $(LISP)
325
- tags=; \
326
- here=`pwd`; \
327
339
  list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
328
340
  unique=`for i in $$list; do \
329
341
  if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
330
342
  done | \
331
- $(AWK) ' { files[$$0] = 1; } \
332
- END { for (i in files) print i; }'`; \
333
- test -z "$(CTAGS_ARGS)$$tags$$unique" \
343
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
344
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
345
+ test -z "$(CTAGS_ARGS)$$unique" \
334
346
  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
335
- $$tags $$unique
347
+ $$unique
336
348
 
337
349
  GTAGS:
338
350
  here=`$(am__cd) $(top_builddir) && pwd` \
339
- && cd $(top_srcdir) \
340
- && gtags -i $(GTAGS_ARGS) $$here
351
+ && $(am__cd) $(top_srcdir) \
352
+ && gtags -i $(GTAGS_ARGS) "$$here"
341
353
 
342
354
  distclean-tags:
343
355
  -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -358,13 +370,17 @@ distdir: $(DISTFILES)
358
370
  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
359
371
  if test -d $$d/$$file; then \
360
372
  dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
373
+ if test -d "$(distdir)/$$file"; then \
374
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
375
+ fi; \
361
376
  if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
362
- cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
377
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
378
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
363
379
  fi; \
364
- cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
380
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
365
381
  else \
366
- test -f $(distdir)/$$file \
367
- || cp -p $$d/$$file $(distdir)/$$file \
382
+ test -f "$(distdir)/$$file" \
383
+ || cp -p $$d/$$file "$(distdir)/$$file" \
368
384
  || exit 1; \
369
385
  fi; \
370
386
  done
@@ -382,16 +398,22 @@ install-am: all-am
382
398
 
383
399
  installcheck: installcheck-am
384
400
  install-strip:
385
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
386
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
387
- `test -z '$(STRIP)' || \
388
- echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
401
+ if test -z '$(STRIP)'; then \
402
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
403
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
404
+ install; \
405
+ else \
406
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
407
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
408
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
409
+ fi
389
410
  mostlyclean-generic:
390
411
 
391
412
  clean-generic:
392
413
 
393
414
  distclean-generic:
394
415
  -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
416
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
395
417
 
396
418
  maintainer-clean-generic:
397
419
  @echo "This command is intended for maintainers to use"
@@ -414,6 +436,8 @@ dvi-am:
414
436
 
415
437
  html: html-am
416
438
 
439
+ html-am:
440
+
417
441
  info: info-am
418
442
 
419
443
  info-am:
@@ -422,18 +446,28 @@ install-data-am:
422
446
 
423
447
  install-dvi: install-dvi-am
424
448
 
449
+ install-dvi-am:
450
+
425
451
  install-exec-am:
426
452
 
427
453
  install-html: install-html-am
428
454
 
455
+ install-html-am:
456
+
429
457
  install-info: install-info-am
430
458
 
459
+ install-info-am:
460
+
431
461
  install-man:
432
462
 
433
463
  install-pdf: install-pdf-am
434
464
 
465
+ install-pdf-am:
466
+
435
467
  install-ps: install-ps-am
436
468
 
469
+ install-ps-am:
470
+
437
471
  installcheck-am:
438
472
 
439
473
  maintainer-clean: maintainer-clean-am
@@ -471,6 +505,7 @@ uninstall-am:
471
505
  mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
472
506
  pdf pdf-am ps ps-am tags uninstall uninstall-am
473
507
 
508
+
474
509
  # Tell versions [3.59,3.63) of GNU make to not export all variables.
475
510
  # Otherwise a system limit (for SysV at least) may be exceeded.
476
511
  .NOEXPORT:
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -17,6 +17,9 @@
17
17
 
18
18
  #include <stdlib.h>
19
19
  #include <unistd.h>
20
+
21
+ #include <sys/epoll.h>
22
+
20
23
  #include <nc_core.h>
21
24
  #include <nc_event.h>
22
25
  #include <nc_conf.h>
@@ -25,10 +28,6 @@
25
28
 
26
29
  static uint32_t ctx_id; /* context generation */
27
30
 
28
- /* function prototype for use in core_ctx_create() */
29
- static void
30
- core_core(void *arg, uint32_t evflags);
31
-
32
31
  static struct context *
33
32
  core_ctx_create(struct instance *nci)
34
33
  {
@@ -42,10 +41,12 @@ core_ctx_create(struct instance *nci)
42
41
  ctx->id = ++ctx_id;
43
42
  ctx->cf = NULL;
44
43
  ctx->stats = NULL;
45
- ctx->evb = NULL;
46
44
  array_null(&ctx->pool);
45
+ ctx->ep = -1;
46
+ ctx->nevent = EVENT_SIZE_HINT;
47
47
  ctx->max_timeout = nci->stats_interval;
48
48
  ctx->timeout = ctx->max_timeout;
49
+ ctx->event = NULL;
49
50
 
50
51
  /* parse and create configuration */
51
52
  ctx->cf = conf_create(nci->conf_filename);
@@ -73,8 +74,8 @@ core_ctx_create(struct instance *nci)
73
74
  }
74
75
 
75
76
  /* initialize event handling for client, proxy and server */
76
- ctx->evb = evbase_create(NC_EVENT_SIZE, &core_core);
77
- if (ctx->evb == NULL) {
77
+ status = event_init(ctx, EVENT_SIZE_HINT);
78
+ if (status != NC_OK) {
78
79
  stats_destroy(ctx->stats);
79
80
  server_pool_deinit(&ctx->pool);
80
81
  conf_destroy(ctx->cf);
@@ -86,7 +87,7 @@ core_ctx_create(struct instance *nci)
86
87
  status = server_pool_preconnect(ctx);
87
88
  if (status != NC_OK) {
88
89
  server_pool_disconnect(ctx);
89
- evbase_destroy(ctx->evb);
90
+ event_deinit(ctx);
90
91
  stats_destroy(ctx->stats);
91
92
  server_pool_deinit(&ctx->pool);
92
93
  conf_destroy(ctx->cf);
@@ -98,7 +99,7 @@ core_ctx_create(struct instance *nci)
98
99
  status = proxy_init(ctx);
99
100
  if (status != NC_OK) {
100
101
  server_pool_disconnect(ctx);
101
- evbase_destroy(ctx->evb);
102
+ event_deinit(ctx);
102
103
  stats_destroy(ctx->stats);
103
104
  server_pool_deinit(&ctx->pool);
104
105
  conf_destroy(ctx->cf);
@@ -117,7 +118,7 @@ core_ctx_destroy(struct context *ctx)
117
118
  log_debug(LOG_VVERB, "destroy ctx %p id %"PRIu32"", ctx, ctx->id);
118
119
  proxy_deinit(ctx);
119
120
  server_pool_disconnect(ctx);
120
- evbase_destroy(ctx->evb);
121
+ event_deinit(ctx);
121
122
  stats_destroy(ctx->stats);
122
123
  server_pool_deinit(&ctx->pool);
123
124
  conf_destroy(ctx->cf);
@@ -205,9 +206,9 @@ core_close(struct context *ctx, struct conn *conn)
205
206
  conn->eof, conn->done, conn->recv_bytes, conn->send_bytes,
206
207
  conn->err ? ':' : ' ', conn->err ? strerror(conn->err) : "");
207
208
 
208
- status = event_del_conn(ctx->evb, conn);
209
+ status = event_del_conn(ctx->ep, conn);
209
210
  if (status < 0) {
210
- log_warn("event del conn %c %d failed, ignored: %s",
211
+ log_warn("event del conn e %d %c %d failed, ignored: %s", ctx->ep,
211
212
  type, conn->sd, strerror(errno));
212
213
  }
213
214
 
@@ -276,33 +277,23 @@ core_timeout(struct context *ctx)
276
277
  }
277
278
 
278
279
  static void
279
- core_core(void *arg, uint32_t evflags)
280
+ core_core(struct context *ctx, struct conn *conn, uint32_t events)
280
281
  {
281
282
  rstatus_t status;
282
- struct conn *conn = (struct conn *) arg;
283
- struct context *ctx;
284
283
 
285
-
286
-
287
- if ((conn->proxy) || (conn->client)) {
288
- ctx = ((struct server_pool *) (conn -> owner)) -> ctx;
289
- } else {
290
- ctx = ((struct server_pool *) (((struct server *) (conn -> owner)) -> owner )) -> ctx;
291
- }
292
-
293
- log_debug(LOG_VVERB, "event %04"PRIX32" on %c %d", evflags,
284
+ log_debug(LOG_VVERB, "event %04"PRIX32" on %c %d", events,
294
285
  conn->client ? 'c' : (conn->proxy ? 'p' : 's'), conn->sd);
295
286
 
296
- conn->events = evflags;
287
+ conn->events = events;
297
288
 
298
289
  /* error takes precedence over read | write */
299
- if (evflags & EV_ERR) {
290
+ if (events & EPOLLERR) {
300
291
  core_error(ctx, conn);
301
292
  return;
302
293
  }
303
294
 
304
295
  /* read takes precedence over write */
305
- if (evflags & EV_READ) {
296
+ if (events & (EPOLLIN | EPOLLHUP)) {
306
297
  status = core_recv(ctx, conn);
307
298
  if (status != NC_OK || conn->done || conn->err) {
308
299
  core_close(ctx, conn);
@@ -310,7 +301,7 @@ core_core(void *arg, uint32_t evflags)
310
301
  }
311
302
  }
312
303
 
313
- if (evflags & EV_WRITE) {
304
+ if (events & EPOLLOUT) {
314
305
  status = core_send(ctx, conn);
315
306
  if (status != NC_OK || conn->done || conn->err) {
316
307
  core_close(ctx, conn);
@@ -324,11 +315,17 @@ core_loop(struct context *ctx)
324
315
  {
325
316
  int i, nsd;
326
317
 
327
- nsd = event_wait(ctx->evb, ctx->timeout);
318
+ nsd = event_wait(ctx->ep, ctx->event, ctx->nevent, ctx->timeout);
328
319
  if (nsd < 0) {
329
320
  return nsd;
330
321
  }
331
322
 
323
+ for (i = 0; i < nsd; i++) {
324
+ struct epoll_event *ev = &ctx->event[i];
325
+
326
+ core_core(ctx, ev->data.ptr, ev->events);
327
+ }
328
+
332
329
  core_timeout(ctx);
333
330
 
334
331
  stats_swap(ctx->stats);
@@ -40,20 +40,10 @@
40
40
  # define NC_STATS 0
41
41
  #endif
42
42
 
43
- #ifdef HAVE_EPOLL
44
- #define NC_HAVE_EPOLL 1
45
- #elif HAVE_KQUEUE
46
- #define NC_HAVE_KQUEUE 1
47
- #endif
48
-
49
43
  #ifdef HAVE_LITTLE_ENDIAN
50
44
  # define NC_LITTLE_ENDIAN 1
51
45
  #endif
52
46
 
53
- #ifdef HAVE_BACKTRACE
54
- #define NC_HAVE_BACKTRACE 1
55
- #endif
56
-
57
47
  #define NC_OK 0
58
48
  #define NC_ERROR -1
59
49
  #define NC_EAGAIN -2
@@ -111,12 +101,14 @@ struct context {
111
101
  struct stats *stats; /* stats */
112
102
 
113
103
  struct array pool; /* server_pool[] */
114
- struct evbase *evb;
104
+
105
+ int ep; /* epoll device */
106
+ int nevent; /* # epoll event */
115
107
  int max_timeout; /* epoll wait max timeout in msec */
116
- int timeout;
108
+ int timeout; /* epoll wait timeout in msec */
109
+ struct epoll_event *event; /* epoll event */
117
110
  };
118
111
 
119
-
120
112
  struct instance {
121
113
  struct context *ctx; /* active context */
122
114
  int log_level; /* log level */