amps-python-client 5.3.4.1__zip → 5.3.4.3__zip

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (918) hide show
  1. amps-python-client-5.3.4.3/LICENSE +168 -0
  2. amps-python-client-5.3.4.3/PKG-INFO +112 -0
  3. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/ack-messages.doctree +0 -0
  4. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/content-messages.doctree +0 -0
  5. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/intro.doctree +0 -0
  6. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/logon.doctree +0 -0
  7. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/protocol-reference.doctree +0 -0
  8. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/publishing.doctree +0 -0
  9. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/query-delimiters.doctree +0 -0
  10. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/query-subscribe.doctree +0 -0
  11. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/removing.doctree +0 -0
  12. amps-python-client-5.3.4.3/docs/command-reference/doctrees/chapters/utilities.doctree +0 -0
  13. amps-python-client-5.3.4.3/docs/command-reference/doctrees/environment.pickle +0 -0
  14. amps-python-client-5.3.4.3/docs/command-reference/doctrees/index.doctree +0 -0
  15. amps-python-client-5.3.4.3/docs/command-reference/html/.buildinfo +4 -0
  16. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/ack-messages.rst.txt +8 -0
  17. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/content-messages.rst.txt +8 -0
  18. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/intro.rst.txt +8 -0
  19. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/logon.rst.txt +8 -0
  20. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/protocol-reference.rst.txt +8 -0
  21. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/publishing.rst.txt +8 -0
  22. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/query-delimiters.rst.txt +8 -0
  23. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/query-subscribe.rst.txt +8 -0
  24. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/removing.rst.txt +8 -0
  25. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/chapters/utilities.rst.txt +8 -0
  26. amps-python-client-5.3.4.3/docs/command-reference/html/_sources/index.rst.txt +36 -0
  27. amps-python-client-5.3.4.3/docs/command-reference/html/_static/custom.css +161 -0
  28. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/ack-messages.html +95 -0
  29. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/content-messages.html +95 -0
  30. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/intro.html +95 -0
  31. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/logon.html +95 -0
  32. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/protocol-reference.html +93 -0
  33. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/publishing.html +95 -0
  34. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/query-delimiters.html +95 -0
  35. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/query-subscribe.html +95 -0
  36. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/removing.html +95 -0
  37. amps-python-client-5.3.4.3/docs/command-reference/html/chapters/utilities.html +95 -0
  38. amps-python-client-5.3.4.3/docs/command-reference/html/genindex.html +97 -0
  39. amps-python-client-5.3.4.3/docs/command-reference/html/index.html +98 -0
  40. amps-python-client-5.3.4.3/docs/command-reference/html/objects.inv +6 -0
  41. amps-python-client-5.3.4.3/docs/command-reference/html/search.html +107 -0
  42. amps-python-client-5.3.4.3/docs/command-reference/html/searchindex.js +1 -0
  43. amps-python-client-5.3.4.3/docs/html/.buildinfo +4 -0
  44. amps-python-client-5.3.4.3/docs/html/code.html +6851 -0
  45. amps-python-client-5.3.4.3/docs/html/genindex.html +1363 -0
  46. amps-python-client-5.3.4.3/docs/html/index.html +131 -0
  47. amps-python-client-5.3.4.3/docs/html/objects.inv +0 -0
  48. amps-python-client-5.3.4.3/docs/html/py-modindex.html +111 -0
  49. amps-python-client-5.3.4.3/docs/html/search.html +107 -0
  50. amps-python-client-5.3.4.3/docs/html/searchindex.js +1 -0
  51. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/advanced-topics.doctree +0 -0
  52. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/cpp-compiler-list.doctree +0 -0
  53. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/cpp-feature-table.doctree +0 -0
  54. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/creating-commands.doctree +0 -0
  55. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/deltas.doctree +0 -0
  56. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/error-handling.doctree +0 -0
  57. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/exceptions.doctree +0 -0
  58. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/first-program.doctree +0 -0
  59. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/high-availability.doctree +0 -0
  60. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/installing.doctree +0 -0
  61. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/introduction.doctree +0 -0
  62. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/moving-from-python-lite.doctree +0 -0
  63. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/performance-tips.doctree +0 -0
  64. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/queues.doctree +0 -0
  65. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/sow.doctree +0 -0
  66. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/subscriptions.doctree +0 -0
  67. amps-python-client-5.3.4.3/docs/python/doctrees/chapters/utilities.doctree +0 -0
  68. amps-python-client-5.3.4.3/docs/python/doctrees/environment.pickle +0 -0
  69. amps-python-client-5.3.4.3/docs/python/doctrees/index.doctree +0 -0
  70. amps-python-client-5.3.4.3/docs/python/html/.buildinfo +4 -0
  71. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/advanced-topics.rst.txt +398 -0
  72. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/cpp-feature-table.rst.txt +26 -0
  73. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/creating-commands.rst.txt +159 -0
  74. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/deltas.rst.txt +79 -0
  75. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/error-handling.rst.txt +481 -0
  76. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/exceptions.rst.txt +123 -0
  77. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/first-program.rst.txt +168 -0
  78. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/high-availability.rst.txt +879 -0
  79. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/installing.rst.txt +184 -0
  80. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/introduction.rst.txt +50 -0
  81. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/moving-from-python-lite.rst.txt +32 -0
  82. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/performance-tips.rst.txt +432 -0
  83. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/queues.rst.txt +282 -0
  84. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/sow.rst.txt +294 -0
  85. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/subscriptions.rst.txt +374 -0
  86. amps-python-client-5.3.4.3/docs/python/html/_sources/chapters/utilities.rst.txt +214 -0
  87. amps-python-client-5.3.4.3/docs/python/html/_static/custom.css +161 -0
  88. amps-python-client-5.3.4.3/docs/python/html/chapters/advanced-topics.html +447 -0
  89. amps-python-client-5.3.4.3/docs/python/html/chapters/cpp-compiler-list.html +92 -0
  90. amps-python-client-5.3.4.3/docs/python/html/chapters/cpp-feature-table.html +156 -0
  91. amps-python-client-5.3.4.3/docs/python/html/chapters/creating-commands.html +2882 -0
  92. amps-python-client-5.3.4.3/docs/python/html/chapters/deltas.html +169 -0
  93. amps-python-client-5.3.4.3/docs/python/html/chapters/error-handling.html +745 -0
  94. amps-python-client-5.3.4.3/docs/python/html/chapters/exceptions.html +266 -0
  95. amps-python-client-5.3.4.3/docs/python/html/chapters/first-program.html +526 -0
  96. amps-python-client-5.3.4.3/docs/python/html/chapters/high-availability.html +1017 -0
  97. amps-python-client-5.3.4.3/docs/python/html/chapters/installing.html +264 -0
  98. amps-python-client-5.3.4.3/docs/python/html/chapters/introduction.html +245 -0
  99. amps-python-client-5.3.4.3/docs/python/html/chapters/moving-from-python-lite.html +118 -0
  100. amps-python-client-5.3.4.3/docs/python/html/chapters/performance-tips.html +499 -0
  101. amps-python-client-5.3.4.3/docs/python/html/chapters/queues.html +352 -0
  102. amps-python-client-5.3.4.3/docs/python/html/chapters/sow.html +383 -0
  103. amps-python-client-5.3.4.3/docs/python/html/chapters/subscriptions.html +535 -0
  104. amps-python-client-5.3.4.3/docs/python/html/chapters/utilities.html +302 -0
  105. amps-python-client-5.3.4.3/docs/python/html/genindex.html +351 -0
  106. amps-python-client-5.3.4.3/docs/python/html/index.html +382 -0
  107. amps-python-client-5.3.4.3/docs/python/html/objects.inv +0 -0
  108. amps-python-client-5.3.4.3/docs/python/html/search.html +107 -0
  109. amps-python-client-5.3.4.3/docs/python/html/searchindex.js +1 -0
  110. amps-python-client-5.3.4.3/docs/python-quickstart/doctrees/chapters/crankitup.doctree +0 -0
  111. amps-python-client-5.3.4.3/docs/python-quickstart/doctrees/chapters/equipment.doctree +0 -0
  112. amps-python-client-5.3.4.3/docs/python-quickstart/doctrees/environment.pickle +0 -0
  113. amps-python-client-5.3.4.3/docs/python-quickstart/doctrees/index.doctree +0 -0
  114. amps-python-client-5.3.4.3/docs/python-quickstart/html/.buildinfo +4 -0
  115. amps-python-client-5.3.4.3/docs/python-quickstart/html/_static/custom.css +161 -0
  116. amps-python-client-5.3.4.3/docs/python-quickstart/html/chapters/crankitup.html +271 -0
  117. amps-python-client-5.3.4.3/docs/python-quickstart/html/chapters/equipment.html +105 -0
  118. amps-python-client-5.3.4.3/docs/python-quickstart/html/genindex.html +97 -0
  119. amps-python-client-5.3.4.3/docs/python-quickstart/html/index.html +381 -0
  120. amps-python-client-5.3.4.3/docs/python-quickstart/html/objects.inv +0 -0
  121. amps-python-client-5.3.4.3/docs/python-quickstart/html/search.html +107 -0
  122. amps-python-client-5.3.4.3/docs/python-quickstart/html/searchindex.js +1 -0
  123. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/acks.doctree +0 -0
  124. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/actions.doctree +0 -0
  125. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/amps-statistics.doctree +0 -0
  126. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/amps_expressions.doctree +0 -0
  127. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/amps_functions.doctree +0 -0
  128. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/auxiliary_modules.doctree +0 -0
  129. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/config-file-shortcuts.doctree +0 -0
  130. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/conflated_topics.doctree +0 -0
  131. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/constructing-fields.doctree +0 -0
  132. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/daemon.doctree +0 -0
  133. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/delta.doctree +0 -0
  134. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/distribution.doctree +0 -0
  135. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/enrichment.doctree +0 -0
  136. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/events.doctree +0 -0
  137. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/file_format_versions.doctree +0 -0
  138. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/glossary.doctree +0 -0
  139. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/ha.doctree +0 -0
  140. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/installing_and_starting.doctree +0 -0
  141. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/intro.doctree +0 -0
  142. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/logging.doctree +0 -0
  143. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/messageTypes.doctree +0 -0
  144. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/monitoring.doctree +0 -0
  145. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/oof.doctree +0 -0
  146. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/operation.doctree +0 -0
  147. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/pub_sub.doctree +0 -0
  148. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/queues.doctree +0 -0
  149. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/replication.doctree +0 -0
  150. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/securing.doctree +0 -0
  151. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/sow.doctree +0 -0
  152. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/sow_queries.doctree +0 -0
  153. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/spark.doctree +0 -0
  154. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/transports.doctree +0 -0
  155. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/troubleshooting.doctree +0 -0
  156. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/txlog.doctree +0 -0
  157. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/usecases.doctree +0 -0
  158. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/utilities.doctree +0 -0
  159. amps-python-client-5.3.4.3/docs/user-guide/doctrees/chapters/views.doctree +0 -0
  160. amps-python-client-5.3.4.3/docs/user-guide/doctrees/environment.pickle +0 -0
  161. amps-python-client-5.3.4.3/docs/user-guide/doctrees/index.doctree +0 -0
  162. amps-python-client-5.3.4.3/docs/user-guide/html/.buildinfo +4 -0
  163. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/acks.rst.txt +8 -0
  164. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/actions.rst.txt +8 -0
  165. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/amps-statistics.rst.txt +8 -0
  166. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/amps_expressions.rst.txt +8 -0
  167. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/amps_functions.rst.txt +8 -0
  168. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/auxiliary_modules.rst.txt +8 -0
  169. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/config-file-shortcuts.rst.txt +8 -0
  170. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/conflated_topics.rst.txt +8 -0
  171. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/constructing-fields.rst.txt +8 -0
  172. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/daemon.rst.txt +8 -0
  173. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/delta.rst.txt +8 -0
  174. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/distribution.rst.txt +8 -0
  175. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/enrichment.rst.txt +8 -0
  176. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/events.rst.txt +8 -0
  177. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/file_format_versions.rst.txt +8 -0
  178. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/glossary.rst.txt +8 -0
  179. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/ha.rst.txt +8 -0
  180. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/installing_and_starting.rst.txt +8 -0
  181. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/intro.rst.txt +8 -0
  182. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/logging.rst.txt +8 -0
  183. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/messageTypes.rst.txt +8 -0
  184. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/monitoring.rst.txt +8 -0
  185. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/oof.rst.txt +8 -0
  186. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/operation.rst.txt +8 -0
  187. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/pub_sub.rst.txt +8 -0
  188. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/queues.rst.txt +8 -0
  189. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/replication.rst.txt +8 -0
  190. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/securing.rst.txt +8 -0
  191. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/sow.rst.txt +8 -0
  192. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/sow_queries.rst.txt +8 -0
  193. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/transports.rst.txt +8 -0
  194. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/troubleshooting.rst.txt +8 -0
  195. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/txlog.rst.txt +8 -0
  196. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/usecases.rst.txt +8 -0
  197. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/utilities.rst.txt +8 -0
  198. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/chapters/views.rst.txt +8 -0
  199. amps-python-client-5.3.4.3/docs/user-guide/html/_sources/index.rst.txt +62 -0
  200. amps-python-client-5.3.4.3/docs/user-guide/html/_static/custom.css +161 -0
  201. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/acks.html +94 -0
  202. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/actions.html +94 -0
  203. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/amps-statistics.html +94 -0
  204. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/amps_expressions.html +94 -0
  205. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/amps_functions.html +94 -0
  206. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/auxiliary_modules.html +94 -0
  207. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/config-file-shortcuts.html +94 -0
  208. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/conflated_topics.html +94 -0
  209. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/constructing-fields.html +94 -0
  210. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/daemon.html +94 -0
  211. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/delta.html +94 -0
  212. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/distribution.html +94 -0
  213. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/enrichment.html +94 -0
  214. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/events.html +94 -0
  215. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/file_format_versions.html +94 -0
  216. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/glossary.html +92 -0
  217. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/ha.html +94 -0
  218. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/installing_and_starting.html +94 -0
  219. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/intro.html +94 -0
  220. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/logging.html +94 -0
  221. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/messageTypes.html +94 -0
  222. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/monitoring.html +94 -0
  223. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/oof.html +94 -0
  224. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/operation.html +94 -0
  225. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/pub_sub.html +94 -0
  226. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/queues.html +94 -0
  227. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/replication.html +94 -0
  228. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/securing.html +94 -0
  229. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/sow.html +94 -0
  230. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/sow_queries.html +94 -0
  231. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/spark.html +819 -0
  232. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/transports.html +94 -0
  233. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/troubleshooting.html +94 -0
  234. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/txlog.html +94 -0
  235. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/usecases.html +94 -0
  236. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/utilities.html +94 -0
  237. amps-python-client-5.3.4.3/docs/user-guide/html/chapters/views.html +94 -0
  238. amps-python-client-5.3.4.3/docs/user-guide/html/genindex.html +133 -0
  239. amps-python-client-5.3.4.3/docs/user-guide/html/index.html +96 -0
  240. amps-python-client-5.3.4.3/docs/user-guide/html/objects.inv +0 -0
  241. amps-python-client-5.3.4.3/docs/user-guide/html/search.html +106 -0
  242. amps-python-client-5.3.4.3/docs/user-guide/html/searchindex.js +1 -0
  243. amps-python-client-5.3.4.3/include/ampspy_bookmarkstore.hpp +63 -0
  244. amps-python-client-5.3.4.3/include/ampspy_compat.h +63 -0
  245. amps-python-client-5.3.4.3/include/ampspy_defs.hpp +181 -0
  246. amps-python-client-5.3.4.3/include/ampspy_recoverypointadapter.hpp +52 -0
  247. amps-python-client-5.3.4.3/include/ampspy_shims.hpp +113 -0
  248. amps-python-client-5.3.4.3/include/ampspy_type_object.hpp +242 -0
  249. amps-python-client-5.3.4.3/include/ampspy_types.hpp +1139 -0
  250. amps-python-client-5.3.4.3/include/ampspyver.h +30 -0
  251. amps-python-client-5.3.4.3/index.html +66 -0
  252. amps-python-client-5.3.4.3/samples/AMPSConsolePublisher.py +59 -0
  253. amps-python-client-5.3.4.3/samples/AMPSConsoleSubscriber.py +63 -0
  254. amps-python-client-5.3.4.3/samples/AMPSFIXBuilderPublisher.py +71 -0
  255. amps-python-client-5.3.4.3/samples/AMPSFIXShredderSubscriber.py +69 -0
  256. amps-python-client-5.3.4.3/samples/AMPSNVFIXBuilderPublisher.py +71 -0
  257. amps-python-client-5.3.4.3/samples/AMPSNVFIXShredderSubscriber.py +67 -0
  258. amps-python-client-5.3.4.3/samples/AMPSPublishForReplay.py +81 -0
  259. amps-python-client-5.3.4.3/samples/AMPSQueueConsumer.py +69 -0
  260. amps-python-client-5.3.4.3/samples/AMPSQueuePublisher.py +59 -0
  261. amps-python-client-5.3.4.3/samples/AMPSSOWConsolePublisher.py +67 -0
  262. amps-python-client-5.3.4.3/samples/AMPSSOWConsoleSubscriber.py +77 -0
  263. amps-python-client-5.3.4.3/samples/AMPSSOWandSubscribeConsoleSubscriber.py +79 -0
  264. amps-python-client-5.3.4.3/samples/AMPSSOWandSubscribeWithOOF.py +108 -0
  265. amps-python-client-5.3.4.3/samples/AMPSSubscribeForReplay.py +128 -0
  266. amps-python-client-5.3.4.3/samples/AMPSUpdateForOOF.py +123 -0
  267. amps-python-client-5.3.4.3/samples/CompositeMessagePublisher.py +84 -0
  268. amps-python-client-5.3.4.3/samples/CompositeMessageSubscriber.py +87 -0
  269. amps-python-client-5.3.4.3/samples/RandomServerChooser.py +66 -0
  270. amps-python-client-5.3.4.3/samples/sample.xml +335 -0
  271. amps-python-client-5.3.4.3/setup.py +210 -0
  272. amps-python-client-5.3.4.3/setup_amps.py +94 -0
  273. amps-python-client-5.3.4.3/src/ampspy_shims.cpp +214 -0
  274. amps-python-client-5.3.4.3/src/ampspy_type_object.cpp +495 -0
  275. amps-python-client-5.3.4.3/src/authenticator.cpp +128 -0
  276. amps-python-client-5.3.4.3/src/bookmarkstore.cpp +246 -0
  277. amps-python-client-5.3.4.3/src/client.cpp +2648 -0
  278. amps-python-client-5.3.4.3/src/client_docs.h +1210 -0
  279. amps-python-client-5.3.4.3/src/cmessagehandler.cpp +161 -0
  280. amps-python-client-5.3.4.3/src/command.cpp +164 -0
  281. amps-python-client-5.3.4.3/src/command_docs.h +274 -0
  282. amps-python-client-5.3.4.3/src/compositemessagebuilder.cpp +113 -0
  283. amps-python-client-5.3.4.3/src/compositemessageparser.cpp +151 -0
  284. amps-python-client-5.3.4.3/src/conflatingrecoverypointadapter.cpp +197 -0
  285. amps-python-client-5.3.4.3/src/cpp/include/amps/BlockPublishStore.hpp +2050 -0
  286. amps-python-client-5.3.4.3/src/cpp/include/amps/BlockStore.hpp +674 -0
  287. amps-python-client-5.3.4.3/src/cpp/include/amps/BookmarkStore.hpp +542 -0
  288. amps-python-client-5.3.4.3/src/cpp/include/amps/Buffer.hpp +214 -0
  289. amps-python-client-5.3.4.3/src/cpp/include/amps/CompositeMessageBuilder.hpp +174 -0
  290. amps-python-client-5.3.4.3/src/cpp/include/amps/CompositeMessageParser.hpp +151 -0
  291. amps-python-client-5.3.4.3/src/cpp/include/amps/DefaultServerChooser.hpp +162 -0
  292. amps-python-client-5.3.4.3/src/cpp/include/amps/Field.hpp +723 -0
  293. amps-python-client-5.3.4.3/src/cpp/include/amps/HAClient.hpp +370 -0
  294. amps-python-client-5.3.4.3/src/cpp/include/amps/HAClientImpl.hpp +460 -0
  295. amps-python-client-5.3.4.3/src/cpp/include/amps/HybridPublishStore.hpp +481 -0
  296. amps-python-client-5.3.4.3/src/cpp/include/amps/LoggedBookmarkStore.hpp +1256 -0
  297. amps-python-client-5.3.4.3/src/cpp/include/amps/MMapBookmarkStore.hpp +1283 -0
  298. amps-python-client-5.3.4.3/src/cpp/include/amps/MMapStoreBuffer.hpp +297 -0
  299. amps-python-client-5.3.4.3/src/cpp/include/amps/MemoryBookmarkStore.hpp +1628 -0
  300. amps-python-client-5.3.4.3/src/cpp/include/amps/MemoryPublishStore.hpp +66 -0
  301. amps-python-client-5.3.4.3/src/cpp/include/amps/MemoryStoreBuffer.hpp +247 -0
  302. amps-python-client-5.3.4.3/src/cpp/include/amps/MemorySubscriptionManager.hpp +850 -0
  303. amps-python-client-5.3.4.3/src/cpp/include/amps/Message.hpp +1827 -0
  304. amps-python-client-5.3.4.3/src/cpp/include/amps/MessageRouter.hpp +647 -0
  305. amps-python-client-5.3.4.3/src/cpp/include/amps/PublishStore.hpp +158 -0
  306. amps-python-client-5.3.4.3/src/cpp/include/amps/ReconnectDelayStrategy.hpp +106 -0
  307. amps-python-client-5.3.4.3/src/cpp/include/amps/ReconnectDelayStrategyImpl.hpp +317 -0
  308. amps-python-client-5.3.4.3/src/cpp/include/amps/RecoveryPoint.hpp +323 -0
  309. amps-python-client-5.3.4.3/src/cpp/include/amps/RecoveryPointAdapter.hpp +501 -0
  310. amps-python-client-5.3.4.3/src/cpp/include/amps/RingBookmarkStore.hpp +669 -0
  311. amps-python-client-5.3.4.3/src/cpp/include/amps/SOWRecoveryPointAdapter.hpp +494 -0
  312. amps-python-client-5.3.4.3/src/cpp/include/amps/ServerChooser.hpp +156 -0
  313. amps-python-client-5.3.4.3/src/cpp/include/amps/ServerChooserImpl.hpp +95 -0
  314. amps-python-client-5.3.4.3/src/cpp/include/amps/amps.h +815 -0
  315. amps-python-client-5.3.4.3/src/cpp/include/amps/amps_impl.h +220 -0
  316. amps-python-client-5.3.4.3/src/cpp/include/amps/amps_ssl.h +78 -0
  317. amps-python-client-5.3.4.3/src/cpp/include/amps/ampscrc.hpp +208 -0
  318. amps-python-client-5.3.4.3/src/cpp/include/amps/ampsplusplus.hpp +8846 -0
  319. amps-python-client-5.3.4.3/src/cpp/include/amps/ampsuri.h +84 -0
  320. amps-python-client-5.3.4.3/src/cpp/include/amps/ampsver.h +41 -0
  321. amps-python-client-5.3.4.3/src/cpp/include/amps/ampsver.h.in +41 -0
  322. amps-python-client-5.3.4.3/src/cpp/include/amps/constants.hpp +194 -0
  323. amps-python-client-5.3.4.3/src/cpp/include/amps/util.hpp +1722 -0
  324. amps-python-client-5.3.4.3/src/cpp/src/amps_protocol.c +693 -0
  325. amps-python-client-5.3.4.3/src/cpp/src/amps_ssl.c +565 -0
  326. amps-python-client-5.3.4.3/src/cpp/src/atfork.c +484 -0
  327. amps-python-client-5.3.4.3/src/cpp/src/client.c +498 -0
  328. amps-python-client-5.3.4.3/src/cpp/src/message.c +837 -0
  329. amps-python-client-5.3.4.3/src/cpp/src/message_generated.h +611 -0
  330. amps-python-client-5.3.4.3/src/cpp/src/tcp.c +1683 -0
  331. amps-python-client-5.3.4.3/src/cpp/src/tcps.c +2005 -0
  332. amps-python-client-5.3.4.3/src/cpp/src/transports.c +129 -0
  333. amps-python-client-5.3.4.3/src/cpp/src/unix.c +1063 -0
  334. amps-python-client-5.3.4.3/src/cpp/src/uri.c +301 -0
  335. amps-python-client-5.3.4.3/src/exponentialdelaystrategy.cpp +131 -0
  336. amps-python-client-5.3.4.3/src/failedwritehandler.cpp +116 -0
  337. amps-python-client-5.3.4.3/src/fixbuilder.cpp +146 -0
  338. amps-python-client-5.3.4.3/src/fixeddelaystrategy.cpp +115 -0
  339. amps-python-client-5.3.4.3/src/fixshredder.cpp +105 -0
  340. amps-python-client-5.3.4.3/src/fixshredder_docs.h +38 -0
  341. amps-python-client-5.3.4.3/src/haclient.cpp +691 -0
  342. amps-python-client-5.3.4.3/src/haclient_docs.h +200 -0
  343. amps-python-client-5.3.4.3/src/hybridpublishstore.cpp +137 -0
  344. amps-python-client-5.3.4.3/src/hybridpublishstore_docs.h +31 -0
  345. amps-python-client-5.3.4.3/src/memorybookmarkstore.cpp +373 -0
  346. amps-python-client-5.3.4.3/src/memorybookmarkstore_docs.h +39 -0
  347. amps-python-client-5.3.4.3/src/memorypublishstore.cpp +160 -0
  348. amps-python-client-5.3.4.3/src/memorypublishstore_docs.h +32 -0
  349. amps-python-client-5.3.4.3/src/message.cpp +765 -0
  350. amps-python-client-5.3.4.3/src/message_docs.h +306 -0
  351. amps-python-client-5.3.4.3/src/messagestream.cpp +630 -0
  352. amps-python-client-5.3.4.3/src/messagestream_docs.h +45 -0
  353. amps-python-client-5.3.4.3/src/mmapbookmarkstore.cpp +422 -0
  354. amps-python-client-5.3.4.3/src/nvfixbuilder.cpp +160 -0
  355. amps-python-client-5.3.4.3/src/nvfixbuilder_docs.h +35 -0
  356. amps-python-client-5.3.4.3/src/nvfixshredder.cpp +99 -0
  357. amps-python-client-5.3.4.3/src/nvfixshredder_docs.h +43 -0
  358. amps-python-client-5.3.4.3/src/publishstore.cpp +183 -0
  359. amps-python-client-5.3.4.3/src/raw_wrapper.cpp +765 -0
  360. amps-python-client-5.3.4.3/src/reason.cpp +71 -0
  361. amps-python-client-5.3.4.3/src/recoverypoint.cpp +135 -0
  362. amps-python-client-5.3.4.3/src/recoverypointadapter.cpp +171 -0
  363. amps-python-client-5.3.4.3/src/ringbookmarkstore.cpp +360 -0
  364. amps-python-client-5.3.4.3/src/serverchooser.cpp +245 -0
  365. amps-python-client-5.3.4.3/src/serverchooser_docs.h +41 -0
  366. amps-python-client-5.3.4.3/src/sowrecoverypointadapter.cpp +248 -0
  367. amps-python-client-5.3.4.3/src/store.cpp +62 -0
  368. amps-python-client-5.3.4.3/src/versioninfo.cpp +175 -0
  369. amps-python-client-5.3.4.1/LICENSE +0 -157
  370. amps-python-client-5.3.4.1/PKG-INFO +0 -112
  371. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/ack-messages.doctree +0 -0
  372. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/content-messages.doctree +0 -0
  373. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/intro.doctree +0 -0
  374. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/logon.doctree +0 -0
  375. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/protocol-reference.doctree +0 -0
  376. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/publishing.doctree +0 -0
  377. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/query-delimiters.doctree +0 -0
  378. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/query-subscribe.doctree +0 -0
  379. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/removing.doctree +0 -0
  380. amps-python-client-5.3.4.1/docs/command-reference/doctrees/chapters/utilities.doctree +0 -0
  381. amps-python-client-5.3.4.1/docs/command-reference/doctrees/environment.pickle +0 -0
  382. amps-python-client-5.3.4.1/docs/command-reference/doctrees/index.doctree +0 -0
  383. amps-python-client-5.3.4.1/docs/command-reference/html/.buildinfo +0 -4
  384. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/ack-messages.rst.txt +0 -32
  385. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/content-messages.rst.txt +0 -27
  386. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/intro.rst.txt +0 -43
  387. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/logon.rst.txt +0 -231
  388. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/protocol-reference.rst.txt +0 -1474
  389. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/publishing.rst.txt +0 -25
  390. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/query-delimiters.rst.txt +0 -12
  391. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/query-subscribe.rst.txt +0 -23
  392. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/removing.rst.txt +0 -6
  393. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/chapters/utilities.rst.txt +0 -13
  394. amps-python-client-5.3.4.1/docs/command-reference/html/_sources/index.rst.txt +0 -56
  395. amps-python-client-5.3.4.1/docs/command-reference/html/_static/custom.css +0 -192
  396. amps-python-client-5.3.4.1/docs/command-reference/html/_static/custom.css.backup +0 -161
  397. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/ack-messages.html +0 -417
  398. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/content-messages.html +0 -417
  399. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/intro.html +0 -126
  400. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/logon.html +0 -295
  401. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/protocol-reference.html +0 -1190
  402. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/publishing.html +0 -436
  403. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/query-delimiters.html +0 -173
  404. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/query-subscribe.html +0 -2123
  405. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/removing.html +0 -299
  406. amps-python-client-5.3.4.1/docs/command-reference/html/chapters/utilities.html +0 -287
  407. amps-python-client-5.3.4.1/docs/command-reference/html/genindex.html +0 -97
  408. amps-python-client-5.3.4.1/docs/command-reference/html/index.html +0 -138
  409. amps-python-client-5.3.4.1/docs/command-reference/html/objects.inv +0 -0
  410. amps-python-client-5.3.4.1/docs/command-reference/html/search.html +0 -107
  411. amps-python-client-5.3.4.1/docs/command-reference/html/searchindex.js +0 -1
  412. amps-python-client-5.3.4.1/docs/html/.buildinfo +0 -4
  413. amps-python-client-5.3.4.1/docs/html/code.html +0 -6503
  414. amps-python-client-5.3.4.1/docs/html/genindex.html +0 -1361
  415. amps-python-client-5.3.4.1/docs/html/index.html +0 -131
  416. amps-python-client-5.3.4.1/docs/html/objects.inv +0 -0
  417. amps-python-client-5.3.4.1/docs/html/py-modindex.html +0 -111
  418. amps-python-client-5.3.4.1/docs/html/search.html +0 -107
  419. amps-python-client-5.3.4.1/docs/html/searchindex.js +0 -1
  420. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/advanced-topics.doctree +0 -0
  421. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/cpp-compiler-list.doctree +0 -0
  422. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/cpp-feature-table.doctree +0 -0
  423. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/creating-commands.doctree +0 -0
  424. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/deltas.doctree +0 -0
  425. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/error-handling.doctree +0 -0
  426. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/exceptions.doctree +0 -0
  427. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/first-program.doctree +0 -0
  428. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/high-availability.doctree +0 -0
  429. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/installing.doctree +0 -0
  430. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/introduction.doctree +0 -0
  431. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/moving-from-python-lite.doctree +0 -0
  432. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/performance-tips.doctree +0 -0
  433. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/queues.doctree +0 -0
  434. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/sow.doctree +0 -0
  435. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/subscriptions.doctree +0 -0
  436. amps-python-client-5.3.4.1/docs/python/doctrees/chapters/utilities.doctree +0 -0
  437. amps-python-client-5.3.4.1/docs/python/doctrees/environment.pickle +0 -0
  438. amps-python-client-5.3.4.1/docs/python/doctrees/index.doctree +0 -0
  439. amps-python-client-5.3.4.1/docs/python/html/.buildinfo +0 -4
  440. amps-python-client-5.3.4.1/docs/python/html/_images/caution.svg +0 -25
  441. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/advanced-topics.rst.txt +0 -398
  442. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/cpp-feature-table.rst.txt +0 -26
  443. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/creating-commands.rst.txt +0 -159
  444. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/deltas.rst.txt +0 -79
  445. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/error-handling.rst.txt +0 -482
  446. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/exceptions.rst.txt +0 -128
  447. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/first-program.rst.txt +0 -142
  448. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/high-availability.rst.txt +0 -876
  449. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/installing.rst.txt +0 -184
  450. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/introduction.rst.txt +0 -50
  451. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/moving-from-python-lite.rst.txt +0 -32
  452. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/performance-tips.rst.txt +0 -434
  453. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/queues.rst.txt +0 -282
  454. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/sow.rst.txt +0 -292
  455. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/subscriptions.rst.txt +0 -374
  456. amps-python-client-5.3.4.1/docs/python/html/_sources/chapters/utilities.rst.txt +0 -214
  457. amps-python-client-5.3.4.1/docs/python/html/_static/custom.css +0 -192
  458. amps-python-client-5.3.4.1/docs/python/html/_static/custom.css.backup +0 -161
  459. amps-python-client-5.3.4.1/docs/python/html/chapters/advanced-topics.html +0 -447
  460. amps-python-client-5.3.4.1/docs/python/html/chapters/cpp-compiler-list.html +0 -92
  461. amps-python-client-5.3.4.1/docs/python/html/chapters/cpp-feature-table.html +0 -156
  462. amps-python-client-5.3.4.1/docs/python/html/chapters/creating-commands.html +0 -2837
  463. amps-python-client-5.3.4.1/docs/python/html/chapters/deltas.html +0 -169
  464. amps-python-client-5.3.4.1/docs/python/html/chapters/error-handling.html +0 -746
  465. amps-python-client-5.3.4.1/docs/python/html/chapters/exceptions.html +0 -272
  466. amps-python-client-5.3.4.1/docs/python/html/chapters/first-program.html +0 -499
  467. amps-python-client-5.3.4.1/docs/python/html/chapters/high-availability.html +0 -1014
  468. amps-python-client-5.3.4.1/docs/python/html/chapters/installing.html +0 -264
  469. amps-python-client-5.3.4.1/docs/python/html/chapters/introduction.html +0 -245
  470. amps-python-client-5.3.4.1/docs/python/html/chapters/moving-from-python-lite.html +0 -118
  471. amps-python-client-5.3.4.1/docs/python/html/chapters/performance-tips.html +0 -499
  472. amps-python-client-5.3.4.1/docs/python/html/chapters/queues.html +0 -352
  473. amps-python-client-5.3.4.1/docs/python/html/chapters/sow.html +0 -381
  474. amps-python-client-5.3.4.1/docs/python/html/chapters/subscriptions.html +0 -535
  475. amps-python-client-5.3.4.1/docs/python/html/chapters/utilities.html +0 -302
  476. amps-python-client-5.3.4.1/docs/python/html/genindex.html +0 -351
  477. amps-python-client-5.3.4.1/docs/python/html/index.html +0 -380
  478. amps-python-client-5.3.4.1/docs/python/html/objects.inv +0 -0
  479. amps-python-client-5.3.4.1/docs/python/html/search.html +0 -107
  480. amps-python-client-5.3.4.1/docs/python/html/searchindex.js +0 -1
  481. amps-python-client-5.3.4.1/docs/python-quickstart/doctrees/chapters/crankitup.doctree +0 -0
  482. amps-python-client-5.3.4.1/docs/python-quickstart/doctrees/chapters/equipment.doctree +0 -0
  483. amps-python-client-5.3.4.1/docs/python-quickstart/doctrees/environment.pickle +0 -0
  484. amps-python-client-5.3.4.1/docs/python-quickstart/doctrees/index.doctree +0 -0
  485. amps-python-client-5.3.4.1/docs/python-quickstart/html/.buildinfo +0 -4
  486. amps-python-client-5.3.4.1/docs/python-quickstart/html/_static/custom.css +0 -192
  487. amps-python-client-5.3.4.1/docs/python-quickstart/html/_static/custom.css.backup +0 -161
  488. amps-python-client-5.3.4.1/docs/python-quickstart/html/chapters/crankitup.html +0 -271
  489. amps-python-client-5.3.4.1/docs/python-quickstart/html/chapters/equipment.html +0 -105
  490. amps-python-client-5.3.4.1/docs/python-quickstart/html/genindex.html +0 -97
  491. amps-python-client-5.3.4.1/docs/python-quickstart/html/index.html +0 -382
  492. amps-python-client-5.3.4.1/docs/python-quickstart/html/objects.inv +0 -0
  493. amps-python-client-5.3.4.1/docs/python-quickstart/html/search.html +0 -107
  494. amps-python-client-5.3.4.1/docs/python-quickstart/html/searchindex.js +0 -1
  495. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/acks.doctree +0 -0
  496. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/actions.doctree +0 -0
  497. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/amps-statistics.doctree +0 -0
  498. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/amps_expressions.doctree +0 -0
  499. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/amps_functions.doctree +0 -0
  500. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/auxiliary_modules.doctree +0 -0
  501. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/config-file-shortcuts.doctree +0 -0
  502. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/conflated_topics.doctree +0 -0
  503. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/constructing-fields.doctree +0 -0
  504. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/daemon.doctree +0 -0
  505. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/delta.doctree +0 -0
  506. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/distribution.doctree +0 -0
  507. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/enrichment.doctree +0 -0
  508. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/events.doctree +0 -0
  509. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/file_format_versions.doctree +0 -0
  510. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/glossary.doctree +0 -0
  511. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/ha.doctree +0 -0
  512. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/installing_and_starting.doctree +0 -0
  513. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/intro.doctree +0 -0
  514. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/logging.doctree +0 -0
  515. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/messageTypes.doctree +0 -0
  516. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/monitoring.doctree +0 -0
  517. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/oof.doctree +0 -0
  518. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/operation.doctree +0 -0
  519. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/pub_sub.doctree +0 -0
  520. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/queues.doctree +0 -0
  521. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/replication.doctree +0 -0
  522. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/securing.doctree +0 -0
  523. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/sow.doctree +0 -0
  524. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/sow_queries.doctree +0 -0
  525. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/spark.doctree +0 -0
  526. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/transports.doctree +0 -0
  527. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/troubleshooting.doctree +0 -0
  528. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/txlog.doctree +0 -0
  529. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/usecases.doctree +0 -0
  530. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/utilities.doctree +0 -0
  531. amps-python-client-5.3.4.1/docs/user-guide/doctrees/chapters/views.doctree +0 -0
  532. amps-python-client-5.3.4.1/docs/user-guide/doctrees/environment.pickle +0 -0
  533. amps-python-client-5.3.4.1/docs/user-guide/doctrees/index.doctree +0 -0
  534. amps-python-client-5.3.4.1/docs/user-guide/html/.buildinfo +0 -4
  535. amps-python-client-5.3.4.1/docs/user-guide/html/_images/AMPS-Queues-Intro.svg +0 -1330
  536. amps-python-client-5.3.4.1/docs/user-guide/html/_images/GeoRepl.png +0 -0
  537. amps-python-client-5.3.4.1/docs/user-guide/html/_images/HA_async_ack.png +0 -0
  538. amps-python-client-5.3.4.1/docs/user-guide/html/_images/HA_sync_ack.png +0 -0
  539. amps-python-client-5.3.4.1/docs/user-guide/html/_images/Hot-Hot-Replication.png +0 -0
  540. amps-python-client-5.3.4.1/docs/user-guide/html/_images/MessageOrdering.svg +0 -235
  541. amps-python-client-5.3.4.1/docs/user-guide/html/_images/OOF5.png +0 -0
  542. amps-python-client-5.3.4.1/docs/user-guide/html/_images/OOF6.png +0 -0
  543. amps-python-client-5.3.4.1/docs/user-guide/html/_images/OOF7.png +0 -0
  544. amps-python-client-5.3.4.1/docs/user-guide/html/_images/OOF8.png +0 -0
  545. amps-python-client-5.3.4.1/docs/user-guide/html/_images/PubSub1.svg +0 -1
  546. amps-python-client-5.3.4.1/docs/user-guide/html/_images/PubSub2.svg +0 -1
  547. amps-python-client-5.3.4.1/docs/user-guide/html/_images/SOWAndSubscribeAndReplace.svg +0 -684
  548. amps-python-client-5.3.4.1/docs/user-guide/html/_images/SOWQuery1.svg +0 -402
  549. amps-python-client-5.3.4.1/docs/user-guide/html/_images/SOWQuery2.svg +0 -505
  550. amps-python-client-5.3.4.1/docs/user-guide/html/_images/UseCaseFig1.svg +0 -1
  551. amps-python-client-5.3.4.1/docs/user-guide/html/_images/UseCaseFig2.svg +0 -1
  552. amps-python-client-5.3.4.1/docs/user-guide/html/_images/UseCaseFig3.svg +0 -1
  553. amps-python-client-5.3.4.1/docs/user-guide/html/_images/UseCaseFig4.svg +0 -1
  554. amps-python-client-5.3.4.1/docs/user-guide/html/_images/caution.png +0 -0
  555. amps-python-client-5.3.4.1/docs/user-guide/html/_images/caution.svg +0 -25
  556. amps-python-client-5.3.4.1/docs/user-guide/html/_images/chicago_group.png +0 -0
  557. amps-python-client-5.3.4.1/docs/user-guide/html/_images/delta_original_messages.png +0 -0
  558. amps-python-client-5.3.4.1/docs/user-guide/html/_images/delta_update_message.png +0 -0
  559. amps-python-client-5.3.4.1/docs/user-guide/html/_images/important.png +0 -0
  560. amps-python-client-5.3.4.1/docs/user-guide/html/_images/important.svg +0 -25
  561. amps-python-client-5.3.4.1/docs/user-guide/html/_images/inline_view_conflation.svg +0 -1
  562. amps-python-client-5.3.4.1/docs/user-guide/html/_images/paginated_subs_pub.png +0 -0
  563. amps-python-client-5.3.4.1/docs/user-guide/html/_images/paginated_subs_sub.png +0 -0
  564. amps-python-client-5.3.4.1/docs/user-guide/html/_images/queue_usage_overview.svg +0 -627
  565. amps-python-client-5.3.4.1/docs/user-guide/html/_images/replication_hub.png +0 -0
  566. amps-python-client-5.3.4.1/docs/user-guide/html/_images/replication_scenario_with_ha.png +0 -0
  567. amps-python-client-5.3.4.1/docs/user-guide/html/_images/sow_overview_1.svg +0 -248
  568. amps-python-client-5.3.4.1/docs/user-guide/html/_images/sow_overview_2.svg +0 -183
  569. amps-python-client-5.3.4.1/docs/user-guide/html/_images/sow_update_sequence.svg +0 -1
  570. amps-python-client-5.3.4.1/docs/user-guide/html/_images/tip.png +0 -0
  571. amps-python-client-5.3.4.1/docs/user-guide/html/_images/tip.svg +0 -31
  572. amps-python-client-5.3.4.1/docs/user-guide/html/_images/warning.png +0 -0
  573. amps-python-client-5.3.4.1/docs/user-guide/html/_images/warning.svg +0 -23
  574. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/acks.rst.txt +0 -232
  575. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/actions.rst.txt +0 -111
  576. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/amps-statistics.rst.txt +0 -358
  577. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/amps_expressions.rst.txt +0 -83
  578. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/amps_functions.rst.txt +0 -11
  579. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/auxiliary_modules.rst.txt +0 -86
  580. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/config-file-shortcuts.rst.txt +0 -9
  581. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/conflated_topics.rst.txt +0 -111
  582. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/constructing-fields.rst.txt +0 -269
  583. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/daemon.rst.txt +0 -232
  584. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/delta.rst.txt +0 -556
  585. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/distribution.rst.txt +0 -186
  586. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/enrichment.rst.txt +0 -191
  587. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/events.rst.txt +0 -39
  588. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/file_format_versions.rst.txt +0 -203
  589. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/glossary.rst.txt +0 -101
  590. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/ha.rst.txt +0 -465
  591. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/installing_and_starting.rst.txt +0 -23
  592. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/intro.rst.txt +0 -116
  593. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/logging.rst.txt +0 -34
  594. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/messageTypes.rst.txt +0 -1398
  595. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/monitoring.rst.txt +0 -326
  596. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/oof.rst.txt +0 -312
  597. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/operation.rst.txt +0 -27
  598. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/pub_sub.rst.txt +0 -49
  599. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/queues.rst.txt +0 -1351
  600. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/replication.rst.txt +0 -1228
  601. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/securing.rst.txt +0 -657
  602. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/sow.rst.txt +0 -57
  603. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/sow_queries.rst.txt +0 -25
  604. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/transports.rst.txt +0 -291
  605. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/troubleshooting.rst.txt +0 -517
  606. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/txlog.rst.txt +0 -62
  607. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/usecases.rst.txt +0 -21
  608. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/utilities.rst.txt +0 -62
  609. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/chapters/views.rst.txt +0 -175
  610. amps-python-client-5.3.4.1/docs/user-guide/html/_sources/index.rst.txt +0 -110
  611. amps-python-client-5.3.4.1/docs/user-guide/html/_static/custom.css +0 -192
  612. amps-python-client-5.3.4.1/docs/user-guide/html/_static/custom.css.backup +0 -161
  613. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/acks.html +0 -289
  614. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/actions.html +0 -3782
  615. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/amps-statistics.html +0 -439
  616. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/amps_expressions.html +0 -1552
  617. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/amps_functions.html +0 -1626
  618. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/auxiliary_modules.html +0 -2548
  619. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/config-file-shortcuts.html +0 -508
  620. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/conflated_topics.html +0 -328
  621. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/constructing-fields.html +0 -447
  622. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/daemon.html +0 -295
  623. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/delta.html +0 -609
  624. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/distribution.html +0 -246
  625. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/enrichment.html +0 -264
  626. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/events.html +0 -449
  627. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/file_format_versions.html +0 -229
  628. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/glossary.html +0 -215
  629. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/ha.html +0 -978
  630. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/installing_and_starting.html +0 -357
  631. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/intro.html +0 -572
  632. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/logging.html +0 -972
  633. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/messageTypes.html +0 -1280
  634. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/monitoring.html +0 -718
  635. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/oof.html +0 -341
  636. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/operation.html +0 -1515
  637. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/pub_sub.html +0 -934
  638. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/queues.html +0 -1767
  639. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/replication.html +0 -1777
  640. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/securing.html +0 -697
  641. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/sow.html +0 -1038
  642. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/sow_queries.html +0 -621
  643. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/spark.html +0 -819
  644. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/transports.html +0 -352
  645. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/troubleshooting.html +0 -530
  646. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/txlog.html +0 -1013
  647. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/usecases.html +0 -288
  648. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/utilities.html +0 -133
  649. amps-python-client-5.3.4.1/docs/user-guide/html/chapters/views.html +0 -1120
  650. amps-python-client-5.3.4.1/docs/user-guide/html/genindex.html +0 -1261
  651. amps-python-client-5.3.4.1/docs/user-guide/html/index.html +0 -163
  652. amps-python-client-5.3.4.1/docs/user-guide/html/objects.inv +0 -0
  653. amps-python-client-5.3.4.1/docs/user-guide/html/search.html +0 -106
  654. amps-python-client-5.3.4.1/docs/user-guide/html/searchindex.js +0 -1
  655. amps-python-client-5.3.4.1/include/ampspy_bookmarkstore.hpp +0 -63
  656. amps-python-client-5.3.4.1/include/ampspy_compat.h +0 -63
  657. amps-python-client-5.3.4.1/include/ampspy_defs.hpp +0 -181
  658. amps-python-client-5.3.4.1/include/ampspy_recoverypointadapter.hpp +0 -52
  659. amps-python-client-5.3.4.1/include/ampspy_shims.hpp +0 -113
  660. amps-python-client-5.3.4.1/include/ampspy_type_object.hpp +0 -242
  661. amps-python-client-5.3.4.1/include/ampspy_types.hpp +0 -1139
  662. amps-python-client-5.3.4.1/include/ampspyver.h +0 -30
  663. amps-python-client-5.3.4.1/index.html +0 -66
  664. amps-python-client-5.3.4.1/samples/AMPSConsolePublisher.py +0 -59
  665. amps-python-client-5.3.4.1/samples/AMPSConsoleSubscriber.py +0 -63
  666. amps-python-client-5.3.4.1/samples/AMPSFIXBuilderPublisher.py +0 -71
  667. amps-python-client-5.3.4.1/samples/AMPSFIXShredderSubscriber.py +0 -69
  668. amps-python-client-5.3.4.1/samples/AMPSNVFIXBuilderPublisher.py +0 -71
  669. amps-python-client-5.3.4.1/samples/AMPSNVFIXShredderSubscriber.py +0 -67
  670. amps-python-client-5.3.4.1/samples/AMPSPublishForReplay.py +0 -81
  671. amps-python-client-5.3.4.1/samples/AMPSQueueConsumer.py +0 -69
  672. amps-python-client-5.3.4.1/samples/AMPSQueuePublisher.py +0 -59
  673. amps-python-client-5.3.4.1/samples/AMPSSOWConsolePublisher.py +0 -67
  674. amps-python-client-5.3.4.1/samples/AMPSSOWConsoleSubscriber.py +0 -77
  675. amps-python-client-5.3.4.1/samples/AMPSSOWandSubscribeConsoleSubscriber.py +0 -79
  676. amps-python-client-5.3.4.1/samples/AMPSSOWandSubscribeWithOOF.py +0 -108
  677. amps-python-client-5.3.4.1/samples/AMPSSubscribeForReplay.py +0 -128
  678. amps-python-client-5.3.4.1/samples/AMPSUpdateForOOF.py +0 -123
  679. amps-python-client-5.3.4.1/samples/CompositeMessagePublisher.py +0 -84
  680. amps-python-client-5.3.4.1/samples/CompositeMessageSubscriber.py +0 -87
  681. amps-python-client-5.3.4.1/samples/RandomServerChooser.py +0 -41
  682. amps-python-client-5.3.4.1/samples/sample.xml +0 -335
  683. amps-python-client-5.3.4.1/setup.py +0 -209
  684. amps-python-client-5.3.4.1/setup_amps.py +0 -94
  685. amps-python-client-5.3.4.1/src/ampspy_shims.cpp +0 -203
  686. amps-python-client-5.3.4.1/src/ampspy_type_object.cpp +0 -484
  687. amps-python-client-5.3.4.1/src/authenticator.cpp +0 -128
  688. amps-python-client-5.3.4.1/src/bookmarkstore.cpp +0 -238
  689. amps-python-client-5.3.4.1/src/client.cpp +0 -2430
  690. amps-python-client-5.3.4.1/src/client_docs.h +0 -956
  691. amps-python-client-5.3.4.1/src/cmessagehandler.cpp +0 -151
  692. amps-python-client-5.3.4.1/src/command.cpp +0 -164
  693. amps-python-client-5.3.4.1/src/command_docs.h +0 -194
  694. amps-python-client-5.3.4.1/src/compositemessagebuilder.cpp +0 -111
  695. amps-python-client-5.3.4.1/src/compositemessageparser.cpp +0 -146
  696. amps-python-client-5.3.4.1/src/conflatingrecoverypointadapter.cpp +0 -194
  697. amps-python-client-5.3.4.1/src/cpp/include/amps/BlockPublishStore.hpp +0 -2053
  698. amps-python-client-5.3.4.1/src/cpp/include/amps/BlockStore.hpp +0 -677
  699. amps-python-client-5.3.4.1/src/cpp/include/amps/BookmarkStore.hpp +0 -542
  700. amps-python-client-5.3.4.1/src/cpp/include/amps/Buffer.hpp +0 -214
  701. amps-python-client-5.3.4.1/src/cpp/include/amps/CompositeMessageBuilder.hpp +0 -174
  702. amps-python-client-5.3.4.1/src/cpp/include/amps/CompositeMessageParser.hpp +0 -151
  703. amps-python-client-5.3.4.1/src/cpp/include/amps/DefaultServerChooser.hpp +0 -162
  704. amps-python-client-5.3.4.1/src/cpp/include/amps/Field.hpp +0 -719
  705. amps-python-client-5.3.4.1/src/cpp/include/amps/HAClient.hpp +0 -370
  706. amps-python-client-5.3.4.1/src/cpp/include/amps/HAClientImpl.hpp +0 -460
  707. amps-python-client-5.3.4.1/src/cpp/include/amps/HybridPublishStore.hpp +0 -481
  708. amps-python-client-5.3.4.1/src/cpp/include/amps/LoggedBookmarkStore.hpp +0 -1255
  709. amps-python-client-5.3.4.1/src/cpp/include/amps/MMapBookmarkStore.hpp +0 -1283
  710. amps-python-client-5.3.4.1/src/cpp/include/amps/MMapStoreBuffer.hpp +0 -290
  711. amps-python-client-5.3.4.1/src/cpp/include/amps/MemoryBookmarkStore.hpp +0 -1622
  712. amps-python-client-5.3.4.1/src/cpp/include/amps/MemoryPublishStore.hpp +0 -66
  713. amps-python-client-5.3.4.1/src/cpp/include/amps/MemoryStoreBuffer.hpp +0 -244
  714. amps-python-client-5.3.4.1/src/cpp/include/amps/MemorySubscriptionManager.hpp +0 -850
  715. amps-python-client-5.3.4.1/src/cpp/include/amps/Message.hpp +0 -1819
  716. amps-python-client-5.3.4.1/src/cpp/include/amps/MessageRouter.hpp +0 -618
  717. amps-python-client-5.3.4.1/src/cpp/include/amps/PublishStore.hpp +0 -158
  718. amps-python-client-5.3.4.1/src/cpp/include/amps/ReconnectDelayStrategy.hpp +0 -106
  719. amps-python-client-5.3.4.1/src/cpp/include/amps/ReconnectDelayStrategyImpl.hpp +0 -317
  720. amps-python-client-5.3.4.1/src/cpp/include/amps/RecoveryPoint.hpp +0 -323
  721. amps-python-client-5.3.4.1/src/cpp/include/amps/RecoveryPointAdapter.hpp +0 -501
  722. amps-python-client-5.3.4.1/src/cpp/include/amps/RingBookmarkStore.hpp +0 -669
  723. amps-python-client-5.3.4.1/src/cpp/include/amps/SOWRecoveryPointAdapter.hpp +0 -490
  724. amps-python-client-5.3.4.1/src/cpp/include/amps/ServerChooser.hpp +0 -145
  725. amps-python-client-5.3.4.1/src/cpp/include/amps/ServerChooserImpl.hpp +0 -95
  726. amps-python-client-5.3.4.1/src/cpp/include/amps/amps.h +0 -775
  727. amps-python-client-5.3.4.1/src/cpp/include/amps/amps_impl.h +0 -204
  728. amps-python-client-5.3.4.1/src/cpp/include/amps/amps_ssl.h +0 -78
  729. amps-python-client-5.3.4.1/src/cpp/include/amps/ampscrc.hpp +0 -210
  730. amps-python-client-5.3.4.1/src/cpp/include/amps/ampsplusplus.hpp +0 -8817
  731. amps-python-client-5.3.4.1/src/cpp/include/amps/ampsuri.h +0 -84
  732. amps-python-client-5.3.4.1/src/cpp/include/amps/ampsver.h +0 -41
  733. amps-python-client-5.3.4.1/src/cpp/include/amps/ampsver.h.in +0 -41
  734. amps-python-client-5.3.4.1/src/cpp/include/amps/constants.hpp +0 -194
  735. amps-python-client-5.3.4.1/src/cpp/include/amps/util.hpp +0 -1692
  736. amps-python-client-5.3.4.1/src/cpp/src/amps_protocol.c +0 -688
  737. amps-python-client-5.3.4.1/src/cpp/src/amps_ssl.c +0 -489
  738. amps-python-client-5.3.4.1/src/cpp/src/atfork.c +0 -446
  739. amps-python-client-5.3.4.1/src/cpp/src/client.c +0 -483
  740. amps-python-client-5.3.4.1/src/cpp/src/message.c +0 -837
  741. amps-python-client-5.3.4.1/src/cpp/src/message_generated.h +0 -611
  742. amps-python-client-5.3.4.1/src/cpp/src/tcp.c +0 -1489
  743. amps-python-client-5.3.4.1/src/cpp/src/tcps.c +0 -1894
  744. amps-python-client-5.3.4.1/src/cpp/src/transports.c +0 -123
  745. amps-python-client-5.3.4.1/src/cpp/src/unix.c +0 -984
  746. amps-python-client-5.3.4.1/src/cpp/src/uri.c +0 -301
  747. amps-python-client-5.3.4.1/src/exponentialdelaystrategy.cpp +0 -137
  748. amps-python-client-5.3.4.1/src/failedwritehandler.cpp +0 -116
  749. amps-python-client-5.3.4.1/src/fixbuilder.cpp +0 -146
  750. amps-python-client-5.3.4.1/src/fixeddelaystrategy.cpp +0 -114
  751. amps-python-client-5.3.4.1/src/fixshredder.cpp +0 -105
  752. amps-python-client-5.3.4.1/src/fixshredder_docs.h +0 -38
  753. amps-python-client-5.3.4.1/src/haclient.cpp +0 -691
  754. amps-python-client-5.3.4.1/src/haclient_docs.h +0 -132
  755. amps-python-client-5.3.4.1/src/hybridpublishstore.cpp +0 -137
  756. amps-python-client-5.3.4.1/src/hybridpublishstore_docs.h +0 -31
  757. amps-python-client-5.3.4.1/src/memorybookmarkstore.cpp +0 -373
  758. amps-python-client-5.3.4.1/src/memorybookmarkstore_docs.h +0 -39
  759. amps-python-client-5.3.4.1/src/memorypublishstore.cpp +0 -160
  760. amps-python-client-5.3.4.1/src/memorypublishstore_docs.h +0 -32
  761. amps-python-client-5.3.4.1/src/message.cpp +0 -765
  762. amps-python-client-5.3.4.1/src/message_docs.h +0 -306
  763. amps-python-client-5.3.4.1/src/messagestream.cpp +0 -623
  764. amps-python-client-5.3.4.1/src/messagestream_docs.h +0 -45
  765. amps-python-client-5.3.4.1/src/mmapbookmarkstore.cpp +0 -422
  766. amps-python-client-5.3.4.1/src/nvfixbuilder.cpp +0 -160
  767. amps-python-client-5.3.4.1/src/nvfixbuilder_docs.h +0 -33
  768. amps-python-client-5.3.4.1/src/nvfixshredder.cpp +0 -99
  769. amps-python-client-5.3.4.1/src/nvfixshredder_docs.h +0 -39
  770. amps-python-client-5.3.4.1/src/publishstore.cpp +0 -183
  771. amps-python-client-5.3.4.1/src/raw_wrapper.cpp +0 -756
  772. amps-python-client-5.3.4.1/src/reason.cpp +0 -71
  773. amps-python-client-5.3.4.1/src/recoverypoint.cpp +0 -135
  774. amps-python-client-5.3.4.1/src/recoverypointadapter.cpp +0 -171
  775. amps-python-client-5.3.4.1/src/ringbookmarkstore.cpp +0 -360
  776. amps-python-client-5.3.4.1/src/serverchooser.cpp +0 -245
  777. amps-python-client-5.3.4.1/src/serverchooser_docs.h +0 -39
  778. amps-python-client-5.3.4.1/src/sowrecoverypointadapter.cpp +0 -248
  779. amps-python-client-5.3.4.1/src/store.cpp +0 -62
  780. amps-python-client-5.3.4.1/src/versioninfo.cpp +0 -175
  781. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/HISTORY +0 -0
  782. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/README.md +0 -0
  783. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/ajax-loader.gif +0 -0
  784. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/alabaster.css +0 -0
  785. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/basic.css +0 -0
  786. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/comment-bright.png +0 -0
  787. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/comment-close.png +0 -0
  788. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/comment.png +0 -0
  789. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/doctools.js +0 -0
  790. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/down-pressed.png +0 -0
  791. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/down.png +0 -0
  792. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/file.png +0 -0
  793. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/flag_logo.png +0 -0
  794. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/flag_logo.svg +0 -0
  795. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/jquery-3.1.0.js +0 -0
  796. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/jquery.js +0 -0
  797. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/minus.png +0 -0
  798. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/plus.png +0 -0
  799. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/pygments.css +0 -0
  800. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/searchtools.js +0 -0
  801. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/underscore-1.3.1.js +0 -0
  802. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/underscore.js +0 -0
  803. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/up-pressed.png +0 -0
  804. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/up.png +0 -0
  805. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/command-reference/html/_static/websupport.js +0 -0
  806. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_sources/code.rst.txt +0 -0
  807. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_sources/index.rst.txt +0 -0
  808. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/ajax-loader.gif +0 -0
  809. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/basic.css +0 -0
  810. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/classic.css +0 -0
  811. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/comment-bright.png +0 -0
  812. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/comment-close.png +0 -0
  813. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/comment.png +0 -0
  814. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/default.css +0 -0
  815. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/doctools.js +0 -0
  816. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/down-pressed.png +0 -0
  817. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/down.png +0 -0
  818. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/file.png +0 -0
  819. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/jquery-3.1.0.js +0 -0
  820. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/jquery.js +0 -0
  821. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/minus.png +0 -0
  822. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/plus.png +0 -0
  823. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/pygments.css +0 -0
  824. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/searchtools.js +0 -0
  825. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/sidebar.js +0 -0
  826. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/underscore-1.3.1.js +0 -0
  827. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/underscore.js +0 -0
  828. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/up-pressed.png +0 -0
  829. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/up.png +0 -0
  830. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/html/_static/websupport.js +0 -0
  831. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/caution.png +0 -0
  832. {amps-python-client-5.3.4.1/docs/command-reference → amps-python-client-5.3.4.3/docs/python}/html/_images/caution.svg +0 -0
  833. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/connection_string.svg +0 -0
  834. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/important.png +0 -0
  835. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/important.svg +0 -0
  836. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/tip.png +0 -0
  837. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/tip.svg +0 -0
  838. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_images/warning.png +0 -0
  839. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_sources/chapters/cpp-compiler-list.rst.txt +0 -0
  840. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_sources/index.rst.txt +0 -0
  841. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/ajax-loader.gif +0 -0
  842. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/alabaster.css +0 -0
  843. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/basic.css +0 -0
  844. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/comment-bright.png +0 -0
  845. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/comment-close.png +0 -0
  846. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/comment.png +0 -0
  847. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/doctools.js +0 -0
  848. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/down-pressed.png +0 -0
  849. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/down.png +0 -0
  850. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/file.png +0 -0
  851. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/flag_logo.png +0 -0
  852. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/flag_logo.svg +0 -0
  853. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/jquery-3.1.0.js +0 -0
  854. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/jquery.js +0 -0
  855. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/minus.png +0 -0
  856. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/plus.png +0 -0
  857. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/pygments.css +0 -0
  858. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/searchtools.js +0 -0
  859. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/underscore-1.3.1.js +0 -0
  860. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/underscore.js +0 -0
  861. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/up-pressed.png +0 -0
  862. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/up.png +0 -0
  863. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python/html/_static/websupport.js +0 -0
  864. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_sources/chapters/crankitup.rst.txt +0 -0
  865. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_sources/chapters/equipment.rst.txt +0 -0
  866. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_sources/index.rst.txt +0 -0
  867. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/ajax-loader.gif +0 -0
  868. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/alabaster.css +0 -0
  869. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/basic.css +0 -0
  870. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/comment-bright.png +0 -0
  871. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/comment-close.png +0 -0
  872. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/comment.png +0 -0
  873. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/doctools.js +0 -0
  874. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/down-pressed.png +0 -0
  875. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/down.png +0 -0
  876. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/file.png +0 -0
  877. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/flag_logo.png +0 -0
  878. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/flag_logo.svg +0 -0
  879. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/jquery-3.1.0.js +0 -0
  880. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/jquery.js +0 -0
  881. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/minus.png +0 -0
  882. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/plus.png +0 -0
  883. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/pygments.css +0 -0
  884. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/searchtools.js +0 -0
  885. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/underscore-1.3.1.js +0 -0
  886. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/underscore.js +0 -0
  887. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/up-pressed.png +0 -0
  888. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/up.png +0 -0
  889. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/python-quickstart/html/_static/websupport.js +0 -0
  890. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/resources/custom.css +0 -0
  891. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/resources/flag_logo.svg +0 -0
  892. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_sources/chapters/spark.rst.txt +0 -0
  893. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/ajax-loader.gif +0 -0
  894. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/alabaster.css +0 -0
  895. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/basic.css +0 -0
  896. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/comment-bright.png +0 -0
  897. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/comment-close.png +0 -0
  898. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/comment.png +0 -0
  899. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/doctools.js +0 -0
  900. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/down-pressed.png +0 -0
  901. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/down.png +0 -0
  902. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/file.png +0 -0
  903. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/flag_logo.png +0 -0
  904. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/flag_logo.svg +0 -0
  905. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/jquery-3.1.0.js +0 -0
  906. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/jquery.js +0 -0
  907. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/minus.png +0 -0
  908. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/plus.png +0 -0
  909. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/pygments.css +0 -0
  910. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/searchtools.js +0 -0
  911. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/underscore-1.3.1.js +0 -0
  912. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/underscore.js +0 -0
  913. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/up-pressed.png +0 -0
  914. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/up.png +0 -0
  915. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/docs/user-guide/html/_static/websupport.js +0 -0
  916. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/src/cpp/include/amps/amps_generated.h +0 -0
  917. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/src/cpp/src/amps_protocol_generated.h +0 -0
  918. {amps-python-client-5.3.4.1 → amps-python-client-5.3.4.3}/src/cpp/src/makefile +0 -0
@@ -0,0 +1,2005 @@
1
+ /*//////////////////////////////////////////////////////////////////////////
2
+ //
3
+ // Copyright (c) 2010-2024 60East Technologies Inc., All Rights Reserved.
4
+ //
5
+ // This computer software is owned by 60East Technologies Inc. and is
6
+ // protected by U.S. copyright laws and other laws and by international
7
+ // treaties. This computer software is furnished by 60East Technologies
8
+ // Inc. pursuant to a written license agreement and may be used, copied,
9
+ // transmitted, and stored only in accordance with the terms of such
10
+ // license agreement and with the inclusion of the above copyright notice.
11
+ // This computer software or any other copies thereof may not be provided
12
+ // or otherwise made available to any other person.
13
+ //
14
+ // U.S. Government Restricted Rights. This computer software: (a) was
15
+ // developed at private expense and is in all respects the proprietary
16
+ // information of 60East Technologies Inc.; (b) was not developed with
17
+ // government funds; (c) is a trade secret of 60East Technologies Inc.
18
+ // for all purposes of the Freedom of Information Act; and (d) is a
19
+ // commercial item and thus, pursuant to Section 12.212 of the Federal
20
+ // Acquisition Regulations (FAR) and DFAR Supplement Section 227.7202,
21
+ // Government's use, duplication or disclosure of the computer software
22
+ // is subject to the restrictions set forth by 60East Technologies Inc..
23
+ //
24
+ ///////////////////////////////////////////////////////////////////////// */
25
+ #if _MSC_VER < 1400
26
+ /*support for visual c++ 2003 */
27
+ #define _WIN32_WINNT 0x0400
28
+ #endif
29
+ #include <amps/amps_impl.h>
30
+ #include <amps/amps_ssl.h>
31
+ #include <amps/ampsuri.h>
32
+ #if __STDC_VERSION__ >= 201100
33
+ #include <stdatomic.h>
34
+ #include <stdbool.h>
35
+ #define AMPS_IEX(ptr, value) atomic_exchange_explicit((ptr), (value), memory_order_acq_rel)
36
+ #define AMPS_IEX_GET(ptr, value) atomic_exchange_explicit((ptr), (value), memory_order_acq_rel)
37
+ #define AMPS_IEX_LONG(ptr, value) atomic_exchange_explicit((ptr), (value), memory_order_acq_rel)
38
+ #define AMPS_FETCH_ADD(ptr, value) atomic_fetch_add_explicit((ptr), (value), memory_order_acq_rel)
39
+ #define AMPS_FETCH_SUB(ptr, value) atomic_fetch_sub_explicit((ptr), (value), memory_order_acq_rel)
40
+ #elif defined(_WIN32)
41
+ #ifdef _WIN64
42
+ #define AMPS_IEX(ptr,value) _InterlockedExchange64((LONG64*)(ptr), (LONG64)(value))
43
+ #define AMPS_IEX_GET(ptr,value) _InterlockedExchange64((LONG64*)(ptr), (LONG64)(value))
44
+ #define AMPS_IEX_LONG(ptr,value) _InterlockedExchange((ptr), (value))
45
+ #define AMPS_FETCH_ADD(ptr, value) InterlockedExchangeAdd64((LONGLONG volatile*)(ptr), (LONGLONG)(value))
46
+ #define AMPS_FETCH_SUB(ptr, value) InterlockedExchangeAdd64((LONGLONG volatile*)(ptr), (LONGLONG)(-1 * (value)))
47
+ #else
48
+ #define AMPS_IEX(ptr,value) _InterlockedExchange((long*)(ptr), (LONG)(value))
49
+ #define AMPS_IEX_GET(ptr,value) _InterlockedExchange((long*)(ptr), (LONG)(value))
50
+ #define AMPS_IEX_LONG(ptr,value) _InterlockedExchange((ptr), (LONG)(value))
51
+ #define AMPS_FETCH_ADD(ptr, value) InterlockedExchangeAdd((LONG volatile*)(ptr), (LONG)(value))
52
+ #define AMPS_FETCH_SUB(ptr, value) InterlockedExchangeAdd((LONG volatile*)(ptr), (LONG)(-1 * (value)))
53
+ #endif
54
+ #else
55
+ #define AMPS_IEX(ptr, value) (void)__sync_lock_test_and_set((ptr), (value))
56
+ #define AMPS_IEX_GET(ptr, value) __sync_lock_test_and_set((ptr), (value))
57
+ #define AMPS_IEX_LONG(ptr, value) (void)__sync_lock_test_and_set((ptr), (value))
58
+ #define AMPS_FETCH_ADD(ptr, value) __sync_fetch_and_add((ptr), (value))
59
+ #define AMPS_FETCH_SUB(ptr, value) __sync_fetch_and_sub((ptr), (value))
60
+ #endif
61
+
62
+ #ifdef _WIN32
63
+
64
+ /* Causes linked programs to add ws2_32.lib which is required by
65
+ * this module. If you'd like to turn this off, define the macro
66
+ * AMPS_WINDOWS_NO_DEFAULT_LIBS.
67
+ */
68
+ #ifndef AMPS_WINDOWS_NO_DEFAULT_LIBS
69
+ #pragma comment(lib,"ws2_32.lib")
70
+ #endif
71
+
72
+ #include <Ws2tcpip.h>
73
+ #define GET_ERRNO (WSAGetLastError())
74
+ #define SOCK_ERRORCODE(x) WSA##x
75
+ #define AMPS_INITLOCK(x) InitializeCriticalSection(x)
76
+ #define AMPS_LOCK(x) EnterCriticalSection(x)
77
+ /* defined in tcp.c */
78
+ int amps_win_spin_lock(LPCRITICAL_SECTION x);
79
+ #define AMPS_SPIN_LOCK(x) amps_win_spin_lock(x)
80
+ #define AMPS_SPIN_LOCK_UNLIMITED(x) EnterCriticalSection(x)
81
+ #define AMPS_UNLOCK(x) LeaveCriticalSection(x)
82
+ #define AMPS_KILLLOCK(x) DeleteCriticalSection(x)
83
+ #else
84
+ #define GET_ERRNO (errno)
85
+ #define SOCK_ERRORCODE(x) x
86
+ #include <pthread.h>
87
+
88
+ static pthread_mutexattr_t _mutexattr_recursive;
89
+ #define AMPS_INITLOCK(x) { \
90
+ pthread_mutexattr_init(&_mutexattr_recursive); \
91
+ pthread_mutexattr_settype(&_mutexattr_recursive, PTHREAD_MUTEX_RECURSIVE);\
92
+ pthread_mutex_init(x, &_mutexattr_recursive); }
93
+ #define AMPS_LOCK(x) pthread_mutex_lock(x)
94
+ #define AMPS_SPIN_LOCK(x) amps_spin_lock_counted(x)
95
+ #define AMPS_SPIN_LOCK_UNLIMITED(x) amps_spin_lock_unlimited(x)
96
+ #define AMPS_UNLOCK(x) pthread_mutex_unlock(x)
97
+ #define AMPS_KILLLOCK(x) pthread_mutex_destroy(x)
98
+ #endif
99
+
100
+ #ifdef AMPS_CPP_COUNT_THREADS
101
+ #define AMPS_INC_THREAD_COUNT(x) AMPS_FETCH_ADD(x, 1)
102
+ #else
103
+ #define AMPS_INC_THREAD_COUNT(x)
104
+ #endif
105
+
106
+ #ifdef _WIN32
107
+ INIT_ONCE ampsTcpsThreadKeyOnce = INIT_ONCE_STATIC_INIT;
108
+ DWORD ampsTcpsThreadKey = TLS_OUT_OF_INDEXES;
109
+
110
+ void amps_tcps_delete_key(void)
111
+ {
112
+ TlsFree(ampsTcpsThreadKey);
113
+ }
114
+
115
+ BOOL CALLBACK amps_tcps_init_key(PINIT_ONCE pKeyOnce, PVOID unused, PVOID* unused2)
116
+ {
117
+ if ((ampsTcpsThreadKey = TlsAlloc()) == TLS_OUT_OF_INDEXES)
118
+ {
119
+ return FALSE;
120
+ }
121
+ atexit(amps_tcps_delete_key);
122
+ return TRUE;
123
+ }
124
+
125
+ DWORD amps_tcps_get_thread_key(void)
126
+ {
127
+ InitOnceExecuteOnce(&ampsTcpsThreadKeyOnce, amps_tcps_init_key, NULL, NULL);
128
+ return ampsTcpsThreadKey;
129
+ }
130
+
131
+ void amps_tcps_set_thread_key(void* pVal)
132
+ {
133
+ InitOnceExecuteOnce(&ampsTcpsThreadKeyOnce, amps_tcps_init_key, NULL, NULL);
134
+ TlsSetValue(ampsTcpsThreadKey, pVal);
135
+ }
136
+
137
+ int tcpsThreadTimeoutMillis = 10000;
138
+
139
+ #define AMPS_JOIN_DECLARE() \
140
+ DWORD tid = (DWORD)0; \
141
+ HANDLE tidH = (HANDLE)0
142
+
143
+ #define AMPS_JOIN(x) \
144
+ tid = (DWORD)AMPS_IEX(&x, 0); \
145
+ tidH = (HANDLE)AMPS_IEX(&x##H, 0); \
146
+ if (tid != 0) \
147
+ { \
148
+ if (tid != GetCurrentThreadId()) \
149
+ { \
150
+ AMPS_INC_THREAD_COUNT(&amps_thread_join_count); \
151
+ WaitForSingleObject(tidH, tcpsThreadTimeoutMillis); \
152
+ CloseHandle(tidH); \
153
+ } \
154
+ else \
155
+ { \
156
+ amps_tcps_set_thread_key((void*)tidH); \
157
+ } \
158
+ }
159
+ #define AMPS_SLEEP(x) \
160
+ Sleep(x)
161
+ #define SHUT_RDWR SD_BOTH
162
+ #else
163
+ pthread_once_t ampsTcpsThreadKeyOnce = PTHREAD_ONCE_INIT;
164
+ pthread_key_t ampsTcpsThreadKey;
165
+
166
+ void amps_tcps_detach_thread(void* vpSelf)
167
+ {
168
+ pthread_detach((pthread_t)vpSelf);
169
+ AMPS_INC_THREAD_COUNT(&amps_thread_detach_count);
170
+ }
171
+
172
+ void amps_tcps_delete_thread_key(void)
173
+ {
174
+ pthread_key_delete(ampsTcpsThreadKey);
175
+ }
176
+
177
+ void amps_tcps_init_thread_key()
178
+ {
179
+ pthread_key_create(&ampsTcpsThreadKey, amps_tcps_detach_thread);
180
+ atexit(amps_tcps_delete_thread_key);
181
+ }
182
+
183
+ void amps_tcps_set_thread_key(void* pVal)
184
+ {
185
+ (void) pthread_once(&ampsTcpsThreadKeyOnce, amps_tcps_init_thread_key);
186
+ pthread_setspecific(ampsTcpsThreadKey, pVal);
187
+ }
188
+
189
+ #define AMPS_JOIN_DECLARE() \
190
+ pthread_t tid = (pthread_t)0;
191
+
192
+ #if __STDC_VERSION__ >= 201100
193
+ #define AMPS_JOIN(x) \
194
+ tid = atomic_exchange((&x), (pthread_t)0); \
195
+ if(tid != (pthread_t)0) \
196
+ { \
197
+ if(tid != pthread_self()) \
198
+ { \
199
+ AMPS_INC_THREAD_COUNT(&amps_thread_join_count); \
200
+ pthread_join(tid, NULL); \
201
+ } \
202
+ else \
203
+ { \
204
+ amps_tcps_set_thread_key((void*)tid); \
205
+ } \
206
+ } \
207
+ else \
208
+ { \
209
+ /* Give recv thread a chance to exit in case it hasn't yet */ \
210
+ usleep(10); \
211
+ }
212
+ #else
213
+ #define AMPS_JOIN(x) \
214
+ tid = AMPS_FETCH_ADD(&x, (pthread_t)0); \
215
+ if(tid != (pthread_t)0) \
216
+ { \
217
+ if(__sync_bool_compare_and_swap(&x, tid, 0)) \
218
+ { \
219
+ if(tid != pthread_self()) \
220
+ { \
221
+ AMPS_INC_THREAD_COUNT(&amps_thread_join_count); \
222
+ pthread_join(tid, NULL); \
223
+ } \
224
+ else \
225
+ { \
226
+ amps_tcps_set_thread_key((void*)tid); \
227
+ } \
228
+ } \
229
+ } \
230
+ else \
231
+ { \
232
+ /* Give recv thread a chance to exit in case it hasn't yet */ \
233
+ usleep(10); \
234
+ }
235
+ #endif
236
+
237
+ #define AMPS_SLEEP(x) { \
238
+ static struct timespec ts = { x/1000, (x%1000) * 1000000 }; \
239
+ nanosleep(&ts, NULL); }
240
+ #endif
241
+
242
+ typedef struct
243
+ {
244
+ amps_thread_created_callback threadCreatedCallback;
245
+ void* threadCreatedCallbackUserData;
246
+ char* buf;
247
+ amps_int64_t serializer;
248
+ amps_handler messageHandler;
249
+ void* messageHandlerUserData;
250
+ amps_transport_filter_function filterFunction;
251
+ void* filterUserData;
252
+
253
+ amps_predisconnect_handler predisconnectHandler;
254
+ void* predisconnectHandlerUserData;
255
+ amps_handler disconnectHandler;
256
+ void* disconnectHandlerUserData;
257
+ amps_uint64_t readTimeoutMillis;
258
+ amps_uint64_t idleTimeMillis;
259
+ #if __STDC_VERSION__ >= 201100
260
+ atomic_int_fast64_t threadCreatedCallbackResult;
261
+ _Atomic unsigned connectionVersion;
262
+ #else
263
+ #if defined(_WIN32) && !defined(_WIN64)
264
+ volatile long threadCreatedCallbackResult;
265
+ #else
266
+ volatile amps_int64_t threadCreatedCallbackResult;
267
+ #endif
268
+ volatile unsigned connectionVersion;
269
+ #endif
270
+
271
+ size_t capacity;
272
+ #if __STDC_VERSION__ >= 201100
273
+ _Atomic AMPS_SOCKET fd;
274
+ _Atomic(_amps_SSL*) ssl;
275
+ atomic_bool disconnecting;
276
+ atomic_bool destroying;
277
+ #else
278
+ volatile AMPS_SOCKET fd;
279
+ _amps_SSL* ssl;
280
+ volatile long disconnecting;
281
+ volatile long destroying;
282
+ #endif
283
+ #ifdef _WIN32
284
+ CRITICAL_SECTION lock;
285
+ CRITICAL_SECTION sendLock;
286
+ #if __STDC_VERSION__ >= 201100
287
+ _Atomic DWORD thread;
288
+ _Atomic HANDLE threadH;
289
+ #else
290
+ volatile DWORD thread;
291
+ volatile HANDLE threadH;
292
+ #endif
293
+ #else
294
+ pthread_mutex_t lock;
295
+ pthread_mutex_t sendLock;
296
+ #if __STDC_VERSION__ >= 201100
297
+ _Atomic pthread_t thread;
298
+ #else
299
+ volatile pthread_t thread;
300
+ #endif
301
+ #endif
302
+ char lastErrorBuf[1024];
303
+ amps_thread_exit_callback threadExitCallback;
304
+ void* threadExitCallbackUserData;
305
+ }
306
+ amps_tcps_t;
307
+
308
+ const amps_char* amps_tcps_get_last_error(
309
+ amps_handle transport)
310
+ {
311
+ return ((amps_tcps_t*)transport)->lastErrorBuf;
312
+ }
313
+
314
+ void amps_tcps_set_error(
315
+ amps_tcps_t* transport,
316
+ const amps_char* buffer)
317
+ {
318
+ _AMPS_SNPRINTF(transport->lastErrorBuf, sizeof(transport->lastErrorBuf), "%s", buffer);
319
+ transport->lastErrorBuf[sizeof(transport->lastErrorBuf) - 1] = '\0';
320
+ }
321
+
322
+ void amps_tcps_set_socket_error(
323
+ amps_tcps_t* transport,
324
+ int errorCode)
325
+ {
326
+ #ifdef _WIN32
327
+ char localBuf[256];
328
+ FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM, NULL, errorCode, 0, localBuf, sizeof(localBuf), NULL);
329
+ amps_tcps_set_error(transport, localBuf);
330
+ #else
331
+ amps_tcps_set_error(transport, strerror(errorCode));
332
+ #endif
333
+ }
334
+
335
+ void amps_tcps_set_hostname_error(
336
+ amps_tcps_t* transport,
337
+ int rc,
338
+ int errorCode)
339
+ {
340
+ #ifdef _WIN32
341
+ amps_tcps_set_socket_error(transport, errorCode);
342
+ #else
343
+ strncpy(transport->lastErrorBuf, gai_strerror(rc), sizeof(transport->lastErrorBuf));
344
+ transport->lastErrorBuf[sizeof(transport->lastErrorBuf) - 1] = '\0';
345
+ #endif
346
+ }
347
+
348
+ void amps_tcps_set_error_stack_error(amps_tcps_t* transport)
349
+ {
350
+ char buffer[256];
351
+ _amps_ERR_error_string_n(_amps_ERR_get_error(), buffer, 256);
352
+ amps_tcps_set_error(transport, buffer);
353
+ }
354
+
355
+ void amps_tcps_set_ssl_error(amps_tcps_t* transport,
356
+ int rc,
357
+ int sysError)
358
+ {
359
+ char buffer[256];
360
+ if (!transport->ssl)
361
+ {
362
+ _AMPS_SNPRINTF(buffer, 256, "SSL error, SSL is closing");
363
+ amps_tcps_set_error(transport, buffer);
364
+ return;
365
+ }
366
+ int sslError = _amps_SSL_get_error(transport->ssl, rc);
367
+ unsigned long errorQueue = 0;
368
+ switch (sslError)
369
+ {
370
+ case AMPS_SSL_ERROR_SSL:
371
+ amps_tcps_set_error_stack_error(transport);
372
+ break;
373
+ case AMPS_SSL_ERROR_SYSCALL:
374
+ errorQueue = _amps_ERR_get_error();
375
+ if (errorQueue)
376
+ {
377
+ _amps_ERR_error_string_n(errorQueue, buffer, 256);
378
+ amps_tcps_set_error(transport, buffer);
379
+ }
380
+ else if (rc == 0 || sysError == 0)
381
+ {
382
+ amps_tcps_set_error(transport, "An unexpected disconnect occurred.");
383
+ }
384
+ else
385
+ {
386
+ amps_tcps_set_socket_error(transport, sysError);
387
+ }
388
+ break;
389
+ default:
390
+ _AMPS_SNPRINTF(buffer, 256, "Unexpected SSL error %d", sslError);
391
+ amps_tcps_set_error(transport, buffer);
392
+ return;
393
+ }
394
+ }
395
+
396
+ void
397
+ amps_tcps_noop_filter_function(const unsigned char* data, size_t length, short direction, void* userdata)
398
+ {;}
399
+
400
+ void amps_tcps_atfork_handler(amps_tcps_t* transport_, int code_)
401
+ {
402
+ switch (code_)
403
+ {
404
+ case 0:
405
+ break;
406
+ case 1:
407
+ break;
408
+ case 2:
409
+ /* Reinitialize the transport lock in the forked child */
410
+ AMPS_INITLOCK(&transport_->lock);
411
+ break;
412
+ }
413
+ }
414
+
415
+ amps_handle amps_tcps_create(void)
416
+ {
417
+ amps_tcps_t* transport = (amps_tcps_t*)malloc(sizeof(amps_tcps_t));
418
+
419
+ if (transport != NULL)
420
+ {
421
+ memset(transport, 0, sizeof(amps_tcps_t));
422
+ transport->fd = AMPS_INVALID_SOCKET;
423
+ transport->ssl = NULL;
424
+ AMPS_INITLOCK(&transport->lock);
425
+ AMPS_INITLOCK(&transport->sendLock);
426
+ #if __STDC_VERSION__ >= 201100
427
+ transport->disconnecting = false;
428
+ transport->destroying = false;
429
+ #endif
430
+ transport->filterFunction = &amps_tcps_noop_filter_function;
431
+ amps_atfork_add(transport, (_amps_atfork_callback_function)amps_tcps_atfork_handler);
432
+ }
433
+
434
+ return transport;
435
+ }
436
+ #ifdef _WIN32
437
+ DWORD amps_tcps_threaded_reader(void* userData);
438
+ #else
439
+ void* amps_tcps_threaded_reader(void* userData);
440
+ #endif
441
+
442
+ int
443
+ amps_tcps_opt_parse(const char* val, size_t valLen, int* parsed)
444
+ {
445
+ size_t i;
446
+ if (valLen == 4 && memcmp(val, "true", 4) == 0)
447
+ {
448
+ *parsed = 1;
449
+ return 1;
450
+ }
451
+ else if (valLen == 5 && memcmp(val, "false", 5) == 0)
452
+ {
453
+ *parsed = 0;
454
+ return 1;
455
+ }
456
+ else
457
+ {
458
+ *parsed = 0;
459
+ for (i = 0; i < valLen ; i++)
460
+ {
461
+ *parsed *= 10;
462
+ if (val[i] >= '0' && val[i] <= '9')
463
+ {
464
+ *parsed += val[i] - '0';
465
+ }
466
+ else
467
+ {
468
+ return 0;
469
+ }
470
+ }
471
+ }
472
+ return 1;
473
+ }
474
+
475
+ amps_result
476
+ amps_tcps_apply_socket_property(AMPS_SOCKET fd, const char* key, size_t keyLen, const
477
+ char* val, size_t valLen)
478
+ {
479
+ int value = 0, level = SOL_SOCKET, optname;
480
+ unsigned int optValueSize = sizeof(int);
481
+ char* optValuePtr = (char*)&value;
482
+ struct linger lingerStruct;
483
+ if (keyLen == 4 && memcmp(key, "bind", keyLen) == 0)
484
+ {
485
+ struct addrinfo* pAddrInfo = NULL, addrhints;
486
+ char addr[256] = { 0 };
487
+ char port[256] = { 0 };
488
+ size_t addrLen = valLen, portLen = 0;
489
+ char* portStr = (char*)(memchr((void*)val, ':', valLen));
490
+ char* ipv6Str = (char*)(memchr((void*)val, '[', valLen));
491
+
492
+ #ifdef _WIN32
493
+ int addrFamily = 0;
494
+ WSAPROTOCOL_INFOW localProto;
495
+ int localProtoLen = sizeof(WSAPROTOCOL_INFO);
496
+ if (getsockopt(fd, SOL_SOCKET, SO_PROTOCOL_INFO, (char*)&localProto, &localProtoLen) == SOCKET_ERROR)
497
+ {
498
+ return AMPS_E_URI;
499
+ }
500
+ addrFamily = localProto.iAddressFamily;
501
+ #elif !defined(__APPLE__)
502
+ int addrFamily = 0;
503
+ socklen_t addrFamilyLen = sizeof(addrFamily);
504
+ if (getsockopt(fd, SOL_SOCKET, AMPS_SO_DOMAIN, (void*)&addrFamily, &addrFamilyLen) < 0)
505
+ {
506
+ return AMPS_E_URI;
507
+ }
508
+ #endif
509
+
510
+ if (ipv6Str)
511
+ {
512
+ ++ipv6Str;
513
+ char* ipv6StrEnd = (char*)(memchr((void*)ipv6Str, ']', (size_t)(val + valLen - ipv6Str)));
514
+ if (!ipv6StrEnd)
515
+ {
516
+ return AMPS_E_URI;
517
+ }
518
+ addrLen = (size_t)(ipv6StrEnd - ipv6Str);
519
+ memcpy(addr, ipv6Str, addrLen);
520
+ addr[addrLen] = '\0';
521
+
522
+ if ((size_t)(val + valLen - ++ipv6StrEnd) < valLen && *ipv6StrEnd == ':')
523
+ {
524
+ portLen = (size_t)(val + valLen - ++ipv6StrEnd);
525
+ memcpy(port, ipv6StrEnd, portLen);
526
+ port[portLen] = '\0';
527
+ }
528
+ }
529
+ else if (portStr)
530
+ {
531
+ addrLen = (size_t)(portStr - val);
532
+ portLen = (size_t)(val + valLen - ++portStr);
533
+ memcpy(addr, val, addrLen);
534
+ addr[addrLen] = '\0';
535
+ memcpy(port, portStr, portLen);
536
+ port[portLen] = '\0';
537
+ }
538
+ else
539
+ {
540
+ memcpy(addr, val, addrLen);
541
+ addr[addrLen] = '\0';
542
+ }
543
+
544
+ /* use getaddrinfo() to find an appropriate address */
545
+ memset(&addrhints, 0, sizeof(struct addrinfo));
546
+ addrhints.ai_socktype = SOCK_STREAM;
547
+ addrhints.ai_protocol = 0;
548
+ #ifndef __APPLE__
549
+ addrhints.ai_family = addrFamily; // match the family of the socket
550
+ #else
551
+ if (ipv6Str)
552
+ {
553
+ addrhints.ai_family = AF_INET6;
554
+ }
555
+ else
556
+ {
557
+ addrhints.ai_family = AF_INET;
558
+ }
559
+ #endif
560
+ addrhints.ai_flags = (AI_V4MAPPED | AI_ADDRCONFIG | AI_PASSIVE);
561
+
562
+ int rc = getaddrinfo(addr, port, &addrhints, &pAddrInfo);
563
+ if (rc != 0 || pAddrInfo == NULL)
564
+ {
565
+ if (pAddrInfo)
566
+ {
567
+ freeaddrinfo(pAddrInfo);
568
+ }
569
+ return AMPS_E_URI;
570
+ }
571
+
572
+ if (bind(fd, pAddrInfo->ai_addr, (socklen_t)pAddrInfo->ai_addrlen) != 0)
573
+ {
574
+ freeaddrinfo(pAddrInfo);
575
+ return AMPS_E_URI;
576
+ }
577
+ freeaddrinfo(pAddrInfo);
578
+ return AMPS_E_OK;
579
+ }
580
+ else if (keyLen == 18 && memcmp(key, "ip_protocol_prefer", keyLen) == 0)
581
+ {
582
+ // no-op; handled in the connect function
583
+ return AMPS_E_OK;
584
+ }
585
+ else if (keyLen == 3 && memcmp(key, "sni", keyLen) == 0)
586
+ {
587
+ // no-op; handled in amps_tcps_apply_ssl_properties
588
+ return AMPS_E_OK;
589
+ }
590
+ // properties after this point must only be boolean or numeric
591
+ if (!amps_tcps_opt_parse(val, valLen, &value))
592
+ {
593
+ return AMPS_E_URI;
594
+ }
595
+ if (keyLen == 10 && memcmp(key, "tcp_rcvbuf", keyLen) == 0)
596
+ {
597
+ optname = SO_RCVBUF;
598
+ }
599
+ else if (keyLen == 13 && memcmp(key, "tcp_keepalive", keyLen) == 0 )
600
+ {
601
+ optname = SO_KEEPALIVE;
602
+ }
603
+ else if (keyLen == 10 && memcmp(key, "tcp_sndbuf", keyLen) == 0)
604
+ {
605
+ optname = SO_SNDBUF;
606
+ }
607
+ else if (keyLen == 11 && memcmp(key, "tcp_nodelay", keyLen) == 0)
608
+ {
609
+ optname = TCP_NODELAY;
610
+ level = IPPROTO_TCP;
611
+ }
612
+ else if (keyLen == 10 && memcmp(key, "tcp_linger", keyLen) == 0)
613
+ {
614
+ optname = SO_LINGER;
615
+ lingerStruct.l_onoff = value != 0;
616
+ lingerStruct.l_linger = (u_short)value;
617
+ optValuePtr = (char*)&lingerStruct;
618
+ optValueSize = sizeof(struct linger);
619
+ }
620
+ else if (keyLen == 6 && memcmp(key, "pretty", keyLen) == 0)
621
+ {
622
+ // no-op; handled in C++ layer
623
+ return AMPS_E_OK;
624
+ }
625
+ else
626
+ {
627
+ return AMPS_E_URI;
628
+ }
629
+
630
+ /* set it */
631
+ if (setsockopt(fd, level, optname, optValuePtr, optValueSize))
632
+ {
633
+ return AMPS_E_URI;
634
+ }
635
+ return AMPS_E_OK;
636
+ }
637
+
638
+ amps_result
639
+ amps_tcps_apply_socket_properties(AMPS_SOCKET fd, const char* uri,
640
+ size_t uriLength, amps_uri_state* uriState)
641
+ {
642
+ const char* key = NULL;
643
+ size_t keyLength = 0;
644
+ /* First, enable tcp_keepalive by default */
645
+ int value = 1;
646
+ unsigned int optValueSize = sizeof(int);
647
+ char* optValuePtr = (char*)&value;
648
+ if (setsockopt(fd, SOL_SOCKET, SO_KEEPALIVE, optValuePtr, optValueSize))
649
+ {
650
+ return AMPS_E_URI;
651
+ }
652
+ /* Now, parse the rest of the URI */
653
+ while (uriState->part_id < AMPS_URI_ERROR)
654
+ {
655
+ amps_uri_parse(uri, uriLength, uriState);
656
+ if (uriState->part_id == AMPS_URI_OPTION_KEY)
657
+ {
658
+ key = uriState->part;
659
+ keyLength = uriState->part_length;
660
+ }
661
+ else if (uriState->part_id == AMPS_URI_OPTION_VALUE)
662
+ {
663
+ if (amps_tcps_apply_socket_property(fd, key, keyLength,
664
+ uriState->part, uriState->part_length) != AMPS_E_OK)
665
+ {
666
+ return AMPS_E_URI;
667
+ }
668
+ }
669
+ }
670
+ if (uriState->part_id == AMPS_URI_ERROR)
671
+ {
672
+ return AMPS_E_URI;
673
+ }
674
+ return AMPS_E_OK;
675
+ }
676
+
677
+ int
678
+ amps_tcps_apply_ssl_properties(_amps_SSL* ssl, const char* uri,
679
+ size_t uriLength, amps_uri_state* uriState)
680
+ {
681
+ int rc = 1;
682
+ const char* key = NULL;
683
+ size_t keyLength = 0;
684
+ while (uriState->part_id < AMPS_URI_ERROR)
685
+ {
686
+ amps_uri_parse(uri, uriLength, uriState);
687
+ if (uriState->part_id == AMPS_URI_OPTION_KEY)
688
+ {
689
+ key = uriState->part;
690
+ keyLength = uriState->part_length;
691
+ }
692
+ else if (uriState->part_id == AMPS_URI_OPTION_VALUE)
693
+ {
694
+ if (keyLength == 3 && memcmp(key, "sni", keyLength) == 0)
695
+ {
696
+ char* hostname = (char*)malloc(uriState->part_length + 1);
697
+ memcpy(hostname, uriState->part, uriState->part_length);
698
+ hostname[uriState->part_length] = '\0';
699
+ rc = _amps_SSL_ctrl(ssl, AMPS_SSL_CTRL_SET_TLSEXT_HOSTNAME, AMPS_TLSEXT_NAMETYPE_host_name, hostname);
700
+ free(hostname);
701
+ if (rc != 1)
702
+ {
703
+ return rc;
704
+ }
705
+ }
706
+ }
707
+ }
708
+ return rc;
709
+ }
710
+
711
+ amps_result amps_tcps_set_idle_time(amps_handle transport, int idleTimeMillis);
712
+ amps_result amps_tcps_connect(amps_handle transport, const amps_char* address)
713
+ {
714
+ AMPS_JOIN_DECLARE();
715
+ amps_tcps_t* me = (amps_tcps_t*)transport;
716
+ char* host = NULL, *port = NULL, *protocol = NULL;
717
+ amps_uri_state uri_state_socket_props, uri_state_addr_props, uri_state_ssl_props;
718
+ amps_ip_protocol_preference ip_proto_prefer = AMPS_DEFAULT_IP_PROTOCOL_PREFERENCE;
719
+ int ip_proto_pref_override = 0;
720
+ int rc, sysError, i;
721
+ amps_result result = AMPS_E_OK;
722
+ struct addrinfo* pAddrInfo = NULL, addrhints;
723
+ size_t address_length = 0;
724
+ AMPS_SOCKET fd = AMPS_INVALID_SOCKET;
725
+ _amps_SSL* ssl = 0;
726
+
727
+ #ifdef _WIN32
728
+ WSADATA wsaData;
729
+ rc = WSAStartup(MAKEWORD(2, 2), &wsaData);
730
+ if (rc != 0)
731
+ {
732
+ amps_tcps_set_error(me, "Windows Sockets could not be started.");
733
+ return AMPS_E_MEMORY;
734
+ }
735
+ #endif
736
+
737
+ AMPS_LOCK(&me->lock);
738
+ #ifndef _WIN32
739
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->lock);
740
+ #endif
741
+ /* if we were previously marked as disconnecting, forget that. */
742
+ AMPS_IEX_LONG(&me->disconnecting, 0);
743
+ AMPS_LOCK(&me->sendLock);
744
+ #ifndef _WIN32
745
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->sendLock);
746
+ #endif
747
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
748
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
749
+
750
+ /* were we previously connected? go ahead and close that. */
751
+ if (ssl)
752
+ {
753
+ rc = _amps_SSL_shutdown(ssl);
754
+ sysError = GET_ERRNO;
755
+ if (rc < 0)
756
+ {
757
+ amps_tcps_set_ssl_error(me, rc, sysError);
758
+ }
759
+ }
760
+ if (fd != AMPS_INVALID_SOCKET)
761
+ {
762
+ /* this is a reconnect */
763
+ shutdown(fd, SHUT_RDWR);
764
+ closesocket(fd);
765
+ fd = AMPS_INVALID_SOCKET;
766
+ }
767
+ AMPS_JOIN(me->thread);
768
+ if (ssl)
769
+ {
770
+ _amps_SSL_free(ssl);
771
+ ssl = 0;
772
+ }
773
+
774
+ /* parse out the address */
775
+ memset(&uri_state_socket_props, 0, sizeof(amps_uri_state));
776
+ memset(&uri_state_addr_props, 0, sizeof(amps_uri_state));
777
+ memset(&uri_state_ssl_props, 0, sizeof(amps_uri_state));
778
+ address_length = strlen(address);
779
+ while (uri_state_addr_props.part_id < AMPS_URI_ERROR)
780
+ {
781
+ amps_uri_parse(address, address_length, &uri_state_addr_props);
782
+ switch (uri_state_addr_props.part_id)
783
+ {
784
+ case AMPS_URI_PROTOCOL:
785
+ protocol = _AMPS_STRNDUP(uri_state_addr_props.part, uri_state_addr_props.part_length);
786
+ me->serializer = amps_message_get_protocol(protocol);
787
+ if (me->serializer == -1)
788
+ {
789
+ amps_tcps_set_error(me,
790
+ "The URI specified an unavailable protocol.");
791
+ result = AMPS_E_URI;
792
+ goto error;
793
+ }
794
+ memcpy(&uri_state_socket_props, &uri_state_addr_props, sizeof(amps_uri_state));
795
+ memcpy(&uri_state_ssl_props, &uri_state_addr_props, sizeof(amps_uri_state));
796
+ break;
797
+ case AMPS_URI_HOST:
798
+ host = _AMPS_STRNDUP(uri_state_addr_props.part, uri_state_addr_props.part_length);
799
+ break;
800
+ case AMPS_URI_PORT:
801
+ port = _AMPS_STRNDUP(uri_state_addr_props.part, uri_state_addr_props.part_length);
802
+ break;
803
+ case AMPS_URI_OPTION_KEY:
804
+ if (uri_state_addr_props.part_length == 18 && memcmp(uri_state_addr_props.part, "ip_protocol_prefer", uri_state_addr_props.part_length) == 0)
805
+ {
806
+ ip_proto_pref_override = 1;
807
+ }
808
+ break;
809
+ case AMPS_URI_OPTION_VALUE:
810
+ if (ip_proto_pref_override)
811
+ {
812
+ if (uri_state_addr_props.part_length == 4 && memcmp(uri_state_addr_props.part, "ipv4", uri_state_addr_props.part_length) == 0)
813
+ {
814
+ ip_proto_prefer = AMPS_PREFER_IPV4;
815
+ }
816
+ else if (uri_state_addr_props.part_length == 4 && memcmp(uri_state_addr_props.part, "ipv6", uri_state_addr_props.part_length) == 0)
817
+ {
818
+ ip_proto_prefer = AMPS_PREFER_IPV6;
819
+ }
820
+ else
821
+ {
822
+ amps_tcps_set_error(me,
823
+ "The URI specified an invalid ip protocol preference.");
824
+ result = AMPS_E_URI;
825
+ goto error;
826
+ }
827
+ }
828
+ break;
829
+ default:
830
+ break;
831
+ }
832
+ }
833
+ if (uri_state_addr_props.part_id == AMPS_URI_ERROR)
834
+ {
835
+ amps_tcps_set_error(me, "URI format invalid.");
836
+ result = AMPS_E_URI;
837
+ goto error;
838
+ }
839
+
840
+ /* use getaddrinfo() to find an appropriate address */
841
+ memset(&addrhints, 0, sizeof(struct addrinfo));
842
+ addrhints.ai_socktype = SOCK_STREAM;
843
+ addrhints.ai_protocol = 0;
844
+ addrhints.ai_flags = (AI_V4MAPPED | AI_ADDRCONFIG);
845
+ addrhints.ai_family = ip_proto_prefer == AMPS_PREFER_IPV6 ? AF_INET6 : AF_INET; /* Try the preferred protocol first */
846
+
847
+ rc = getaddrinfo(host, port, &addrhints, &pAddrInfo);
848
+ sysError = GET_ERRNO;
849
+ #ifdef _WIN32
850
+ if (rc == EAI_FAMILY || rc == EAI_NONAME || rc == EAI_AGAIN || rc == EAI_SERVICE)
851
+ #else
852
+ if (rc == EAI_ADDRFAMILY || rc == EAI_NONAME || rc == EAI_AGAIN || rc == EAI_SERVICE)
853
+ #endif
854
+ {
855
+ // didn't find any addresses of the preferred protocol, try the other one.
856
+ addrhints.ai_family = ip_proto_prefer == AMPS_PREFER_IPV6 ? AF_INET : AF_INET6;
857
+ rc = getaddrinfo(host, port, &addrhints, &pAddrInfo);
858
+ sysError = GET_ERRNO;
859
+ if (rc != 0)
860
+ {
861
+ /* Try preferred protocol again without AI_ADDRCONFIG */
862
+ addrhints.ai_flags = AI_V4MAPPED;
863
+ addrhints.ai_family = ip_proto_prefer == AMPS_PREFER_IPV6 ? AF_INET6 : AF_INET;
864
+ rc = getaddrinfo(host, port, &addrhints, &pAddrInfo);
865
+ sysError = GET_ERRNO;
866
+ }
867
+ }
868
+ if (rc != 0)
869
+ {
870
+ result = AMPS_E_CONNECTION_REFUSED;
871
+ amps_tcps_set_hostname_error(me, rc, sysError);
872
+ freeaddrinfo(pAddrInfo);
873
+ goto error;
874
+ }
875
+
876
+ me->fd = socket(pAddrInfo->ai_family, pAddrInfo->ai_socktype, pAddrInfo->ai_protocol);
877
+ sysError = GET_ERRNO;
878
+ if (me->fd == AMPS_INVALID_SOCKET)
879
+ {
880
+ freeaddrinfo(pAddrInfo);
881
+ amps_tcps_set_socket_error(me, sysError);
882
+ result = AMPS_E_CONNECTION_REFUSED;
883
+ goto error;
884
+ }
885
+
886
+ /* apply socket properties */
887
+ if (amps_tcps_apply_socket_properties(me->fd, address, address_length, &uri_state_socket_props) != AMPS_E_OK)
888
+ {
889
+ freeaddrinfo(pAddrInfo);
890
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
891
+ amps_tcps_set_error(me, "The URI specified invalid properties.");
892
+ result = AMPS_E_URI;
893
+ goto error;
894
+ }
895
+ #ifdef __APPLE__
896
+ rc = 1; /* Set NOSIGPIPE to ON */
897
+ if (setsockopt(me->fd, SOL_SOCKET, SO_NOSIGPIPE, &rc, sizeof(rc)) < 0)
898
+ {
899
+ freeaddrinfo(pAddrInfo);
900
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
901
+ amps_tcps_set_error(me, "Failed to set no SIGPIPE.");
902
+ result = AMPS_E_CONNECTION;
903
+ goto error;
904
+ }
905
+ #endif
906
+
907
+ rc = connect(me->fd, pAddrInfo->ai_addr,
908
+ (socklen_t)pAddrInfo->ai_addrlen);
909
+ sysError = GET_ERRNO;
910
+ freeaddrinfo(pAddrInfo);
911
+ if (rc == -1)
912
+ {
913
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
914
+ amps_tcps_set_socket_error(me, sysError);
915
+ result = AMPS_E_CONNECTION_REFUSED;
916
+ goto error;
917
+ }
918
+
919
+ /* On first use, initialize an SSL context if one hasn't been created. */
920
+ if (!_amps_ssl_ctx)
921
+ {
922
+ rc = amps_ssl_init(NULL);
923
+ if (rc)
924
+ {
925
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
926
+ amps_tcps_set_error(me, "Could not initialize an SSL context.");
927
+ result = AMPS_E_SSL;
928
+ goto error;
929
+ }
930
+ }
931
+ /* Handshake via SSL */
932
+ _amps_ERR_clear_error();
933
+ if (!me->ssl)
934
+ {
935
+ me->ssl = _amps_SSL_new(_amps_ssl_ctx);
936
+ }
937
+ if (me->ssl == 0)
938
+ {
939
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
940
+ amps_tcps_set_error_stack_error(me);
941
+ result = AMPS_E_SSL;
942
+ goto error;
943
+ }
944
+
945
+ rc = _amps_SSL_set_fd(me->ssl, (int)me->fd);
946
+ sysError = GET_ERRNO;
947
+ if (rc != 1)
948
+ {
949
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
950
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
951
+ amps_tcps_set_ssl_error(me, rc, sysError);
952
+ result = AMPS_E_SSL;
953
+ goto error;
954
+ }
955
+
956
+ rc = amps_tcps_apply_ssl_properties(me->ssl, address, address_length, &uri_state_ssl_props);
957
+ sysError = GET_ERRNO;
958
+ if (rc != 1)
959
+ {
960
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
961
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
962
+ amps_tcps_set_ssl_error(me, rc, sysError);
963
+ result = AMPS_E_SSL;
964
+ goto error;
965
+ }
966
+
967
+ _amps_SSL_ctrl(me->ssl, AMPS_SSL_CTRL_MODE, AMPS_SSL_AUTO_RETRY, NULL);
968
+
969
+ rc = _amps_SSL_connect(me->ssl);
970
+ sysError = GET_ERRNO;
971
+ if (rc != 1)
972
+ {
973
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
974
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
975
+ amps_tcps_set_ssl_error(me, rc, sysError);
976
+ result = AMPS_E_SSL;
977
+ goto error;
978
+ }
979
+
980
+ // tcps transport must use read with a timeout.
981
+ amps_tcps_set_idle_time(transport, 100);
982
+
983
+ /* Increase the connection version now, so that anyone else attempting a reconnect knows
984
+ * that they may not need to. */
985
+ me->connectionVersion++;
986
+ result = AMPS_E_OK;
987
+
988
+ /* and, start up a new reader thread */
989
+ if (me->threadCreatedCallback)
990
+ {
991
+ AMPS_IEX(&me->threadCreatedCallbackResult, -1);
992
+ }
993
+ #ifdef _WIN32
994
+ me->threadH = CreateThread(NULL, 0,
995
+ (LPTHREAD_START_ROUTINE)amps_tcps_threaded_reader,
996
+ me, CREATE_SUSPENDED, (LPDWORD)&me->thread);
997
+ /* Now that me->thread is populated, we can start the thread.
998
+ * important to do it in two steps, since we use me->thread as a poor-man's cancellation mechanism */
999
+ if (me->threadH)
1000
+ {
1001
+ AMPS_INC_THREAD_COUNT(&amps_thread_create_count);
1002
+ ResumeThread(me->threadH);
1003
+ }
1004
+ else
1005
+ {
1006
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1007
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
1008
+ amps_tcps_set_error(me, "Failed to create thread for receive");
1009
+ result = AMPS_E_MEMORY;
1010
+ goto error;
1011
+ }
1012
+
1013
+ #else
1014
+ rc = pthread_create((pthread_t*)(&me->thread), NULL,
1015
+ &amps_tcps_threaded_reader, me);
1016
+ if (rc != 0)
1017
+ {
1018
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1019
+ ssl = AMPS_IEX_GET(&me->ssl, 0);
1020
+ amps_tcps_set_error(me, "Failed to create thread for receive");
1021
+ result = AMPS_E_MEMORY;
1022
+ goto error;
1023
+ }
1024
+ AMPS_INC_THREAD_COUNT(&amps_thread_create_count);
1025
+ #endif
1026
+ for (i = 0; i < AMPS_THREAD_START_TIMEOUT && me->threadCreatedCallbackResult == -1; ++i)
1027
+ {
1028
+ AMPS_SLEEP(4);
1029
+ }
1030
+ result = (amps_result)me->threadCreatedCallbackResult;
1031
+ if (me->threadCreatedCallbackResult == -1)
1032
+ {
1033
+ amps_tcps_set_error(me, "Thread created callback failed to return in a timely manner or returned -1.");
1034
+ result = AMPS_E_MEMORY;
1035
+ }
1036
+ if (result != AMPS_E_OK)
1037
+ {
1038
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1039
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
1040
+ AMPS_JOIN(me->thread);
1041
+ amps_tcps_set_error(me, "Thread creation callback failed");
1042
+ }
1043
+
1044
+ error:
1045
+ if (result != AMPS_E_OK)
1046
+ {
1047
+ if (ssl)
1048
+ {
1049
+ rc = _amps_SSL_shutdown(ssl);
1050
+ sysError = GET_ERRNO;
1051
+ if (rc < 0)
1052
+ {
1053
+ amps_tcps_set_ssl_error(me, rc, sysError);
1054
+ }
1055
+ }
1056
+ if (fd != AMPS_INVALID_SOCKET)
1057
+ {
1058
+ shutdown(fd, SHUT_RDWR);
1059
+ closesocket(fd);
1060
+ }
1061
+ if (ssl)
1062
+ {
1063
+ _amps_SSL_free(ssl);
1064
+ ssl = 0;
1065
+ }
1066
+ #ifdef _WIN32
1067
+ me->thread = 0;
1068
+ #else
1069
+ me->thread = (pthread_t)0;
1070
+ #endif
1071
+ }
1072
+ free(protocol);
1073
+ free(host);
1074
+ free(port);
1075
+ AMPS_UNLOCK(&me->sendLock);
1076
+ AMPS_UNLOCK(&me->lock);
1077
+ #ifndef _WIN32
1078
+ pthread_cleanup_pop(0);
1079
+ pthread_cleanup_pop(0);
1080
+ #endif
1081
+ return result;
1082
+
1083
+ }
1084
+
1085
+ amps_result amps_tcps_set_receiver(amps_handle transport, amps_handler receiver, void* userData)
1086
+ {
1087
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1088
+ me->messageHandlerUserData = userData;
1089
+ me->messageHandler = receiver;
1090
+ return AMPS_E_OK;
1091
+ }
1092
+
1093
+ amps_result amps_tcps_set_predisconnect(amps_handle transport,
1094
+ amps_predisconnect_handler receiver,
1095
+ void* userData)
1096
+ {
1097
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1098
+ me->predisconnectHandlerUserData = userData;
1099
+ me->predisconnectHandler = receiver;
1100
+ return AMPS_E_OK;
1101
+ }
1102
+
1103
+ amps_result amps_tcps_set_disconnect(amps_handle transport, amps_handler receiver, void* userData)
1104
+ {
1105
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1106
+ me->disconnectHandlerUserData = userData;
1107
+ me->disconnectHandler = receiver;
1108
+ return AMPS_E_OK;
1109
+ }
1110
+
1111
+ void amps_tcps_close(amps_handle transport)
1112
+ {
1113
+ AMPS_JOIN_DECLARE();
1114
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1115
+ AMPS_SOCKET fd = AMPS_INVALID_SOCKET;
1116
+ _amps_SSL* ssl = 0;
1117
+ AMPS_IEX_LONG(&me->disconnecting, 1);
1118
+ AMPS_LOCK(&me->sendLock);
1119
+ #ifndef _WIN32
1120
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->sendLock);
1121
+ #endif
1122
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1123
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
1124
+ AMPS_UNLOCK(&me->sendLock);
1125
+ #ifndef _WIN32
1126
+ pthread_cleanup_pop(0);
1127
+ #endif
1128
+ AMPS_SPIN_LOCK_UNLIMITED(&me->lock);
1129
+ #ifndef _WIN32
1130
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->lock);
1131
+ #endif
1132
+ if (ssl)
1133
+ {
1134
+ int rc = _amps_SSL_shutdown(ssl);
1135
+ int sysError = GET_ERRNO;
1136
+ if (rc == 0 && fd != AMPS_INVALID_SOCKET)
1137
+ {
1138
+ // attempt to wait for the server to send back the matching close notify.
1139
+ struct timeval tv;
1140
+ fd_set readfds, exceptfds;
1141
+ tv.tv_sec = 0;
1142
+ tv.tv_usec = 10000;
1143
+ FD_ZERO(&readfds);
1144
+ FD_SET(fd, &readfds);
1145
+ FD_ZERO(&exceptfds);
1146
+ FD_SET(fd, &exceptfds);
1147
+ #ifdef _WIN32
1148
+ select(1, &readfds, 0, &exceptfds, &tv);
1149
+ #else
1150
+ select(fd + 1, &readfds, 0, &exceptfds, &tv);
1151
+ #endif
1152
+ rc = _amps_SSL_shutdown(ssl);
1153
+ }
1154
+ if (rc < 0)
1155
+ {
1156
+ amps_tcps_set_ssl_error(me, rc, sysError);
1157
+ }
1158
+ }
1159
+ if (fd != AMPS_INVALID_SOCKET)
1160
+ {
1161
+ shutdown(fd, SHUT_RDWR);
1162
+ closesocket(fd);
1163
+ }
1164
+ if (ssl)
1165
+ {
1166
+ _amps_SSL_free(ssl);
1167
+ }
1168
+ AMPS_UNLOCK(&me->lock);
1169
+ #ifndef _WIN32
1170
+ pthread_cleanup_pop(0);
1171
+ #endif
1172
+ AMPS_JOIN(me->thread);
1173
+ }
1174
+
1175
+ void amps_tcps_destroy(amps_handle transport)
1176
+ {
1177
+ AMPS_JOIN_DECLARE();
1178
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1179
+ AMPS_SOCKET fd = AMPS_INVALID_SOCKET;
1180
+ _amps_SSL* ssl = 0;
1181
+ amps_atfork_remove(me, (_amps_atfork_callback_function)amps_tcps_atfork_handler);
1182
+ AMPS_LOCK(&me->sendLock);
1183
+ #ifndef _WIN32
1184
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->sendLock);
1185
+ #endif
1186
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1187
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
1188
+ AMPS_UNLOCK(&me->sendLock);
1189
+ #ifndef _WIN32
1190
+ pthread_cleanup_pop(0);
1191
+ #endif
1192
+ AMPS_LOCK(&me->lock);
1193
+ #ifndef _WIN32
1194
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->lock);
1195
+ #endif
1196
+ #if __STDC_VERSION__ >= 201100
1197
+ me->destroying = true;
1198
+ me->disconnecting = true;
1199
+ #else
1200
+ AMPS_IEX_LONG(&me->destroying, 1);
1201
+ AMPS_IEX_LONG(&me->disconnecting, 1);
1202
+ #endif
1203
+ if (ssl)
1204
+ {
1205
+ int rc = _amps_SSL_shutdown(ssl);
1206
+ int sysError = GET_ERRNO;
1207
+ if (rc == 0 && fd != AMPS_INVALID_SOCKET)
1208
+ {
1209
+ // attempt to wait for the server to send back the matching close notify.
1210
+ struct timeval tv;
1211
+ fd_set readfds, exceptfds;
1212
+ tv.tv_sec = 0;
1213
+ tv.tv_usec = 10000;
1214
+ FD_ZERO(&readfds);
1215
+ FD_SET(fd, &readfds);
1216
+ FD_ZERO(&exceptfds);
1217
+ FD_SET(fd, &exceptfds);
1218
+ #ifdef _WIN32
1219
+ select(1, &readfds, 0, &exceptfds, &tv);
1220
+ #else
1221
+ select(fd + 1, &readfds, 0, &exceptfds, &tv);
1222
+ #endif
1223
+ rc = _amps_SSL_shutdown(ssl);
1224
+ }
1225
+ if (rc < 0)
1226
+ {
1227
+ amps_tcps_set_ssl_error(me, rc, sysError);
1228
+ }
1229
+ }
1230
+ if (fd != AMPS_INVALID_SOCKET)
1231
+ {
1232
+ shutdown(fd, SHUT_RDWR);
1233
+ closesocket(fd);
1234
+ }
1235
+ if (ssl)
1236
+ {
1237
+ _amps_SSL_free(ssl);
1238
+ }
1239
+
1240
+ AMPS_UNLOCK(&me->lock);
1241
+ #ifndef _WIN32
1242
+ pthread_cleanup_pop(0);
1243
+ #endif
1244
+ AMPS_JOIN(me->thread);
1245
+ AMPS_SLEEP(1);
1246
+ free(me->buf);
1247
+ /* Hopefully, nobody else is using me right now. */
1248
+
1249
+ AMPS_KILLLOCK(&me->lock);
1250
+ AMPS_KILLLOCK(&me->sendLock);
1251
+
1252
+ free(me);
1253
+ }
1254
+
1255
+ /* called with me->lock not already taken */
1256
+ amps_result amps_tcps_handle_disconnect(
1257
+ amps_tcps_t* me, unsigned failedConnectionVersion)
1258
+ {
1259
+ AMPS_SOCKET fd = AMPS_INVALID_SOCKET;
1260
+ _amps_SSL* ssl = 0;
1261
+ #ifndef _WIN32
1262
+ int cancelState = 0;
1263
+ int unusedCancelState = 0;
1264
+ #endif
1265
+ amps_result result = AMPS_E_OK;
1266
+ AMPS_LOCK(&me->sendLock);
1267
+ #ifndef _WIN32
1268
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->sendLock);
1269
+ #endif
1270
+ fd = AMPS_IEX_GET(&me->fd, AMPS_INVALID_SOCKET);
1271
+ ssl = (_amps_SSL*)AMPS_IEX_GET(&me->ssl, 0);
1272
+ AMPS_UNLOCK(&me->sendLock);
1273
+ #ifndef _WIN32
1274
+ pthread_cleanup_pop(0);
1275
+ #endif
1276
+ /* close what we have right now. */
1277
+ if (ssl)
1278
+ {
1279
+ int rc = _amps_SSL_shutdown(ssl);
1280
+ int sysError = GET_ERRNO;
1281
+ if (rc == 0 && fd != AMPS_INVALID_SOCKET)
1282
+ {
1283
+ // attempt to wait for the server to send back the matching close notify.
1284
+ struct timeval tv;
1285
+ fd_set readfds, exceptfds;
1286
+ tv.tv_sec = 0;
1287
+ tv.tv_usec = 10000;
1288
+ FD_ZERO(&readfds);
1289
+ FD_SET(fd, &readfds);
1290
+ FD_ZERO(&exceptfds);
1291
+ FD_SET(fd, &exceptfds);
1292
+ #ifdef _WIN32
1293
+ select(1, &readfds, 0, &exceptfds, &tv);
1294
+ #else
1295
+ select(fd + 1, &readfds, 0, &exceptfds, &tv);
1296
+ #endif
1297
+ rc = _amps_SSL_shutdown(ssl);
1298
+ }
1299
+ if (rc < 0)
1300
+ {
1301
+ amps_tcps_set_ssl_error(me, rc, sysError);
1302
+ }
1303
+ }
1304
+ if (fd != AMPS_INVALID_SOCKET)
1305
+ {
1306
+ shutdown(fd, SHUT_RDWR);
1307
+ closesocket(fd);
1308
+ }
1309
+ if (ssl)
1310
+ {
1311
+ _amps_SSL_free(ssl);
1312
+ }
1313
+
1314
+ /* first let waiters know that we've failed. */
1315
+ me->predisconnectHandler(me, failedConnectionVersion, me->predisconnectHandlerUserData);
1316
+
1317
+ /* Now take the lock on self.
1318
+ * Use a spin, the only case where it might fail should be if a recv
1319
+ * thread ends up here while a send thread is already handling disconnect
1320
+ * and it is trying to join this thread in disconnect. */
1321
+ if (AMPS_SPIN_LOCK(&me->lock) == 0)
1322
+ {
1323
+ return AMPS_E_RETRY;
1324
+ }
1325
+ #ifndef _WIN32
1326
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->lock);
1327
+ #endif
1328
+
1329
+ /* if we're being destroyed, get out of here; don't worry about unlocking */
1330
+ if (me->destroying)
1331
+ {
1332
+ result = AMPS_E_DISCONNECTED; return result;
1333
+ }
1334
+
1335
+ /* a new connection is available. let someone else try. */
1336
+ if (failedConnectionVersion != me->connectionVersion)
1337
+ {
1338
+ result = AMPS_E_RETRY;
1339
+ goto error;
1340
+ }
1341
+
1342
+ /* if we're disconnecting, get out of here; don't reconnect */
1343
+ if (me->disconnecting)
1344
+ {
1345
+ result = AMPS_E_DISCONNECTED;
1346
+ goto error;
1347
+ }
1348
+
1349
+ #ifdef _WIN32
1350
+ HANDLE tidH = (AMPS_CURRENT_THREAD() == me->thread) ? me->threadH : NULL;
1351
+ #else
1352
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1353
+ void* vpTid = (void*)(pthread_self());
1354
+ #endif
1355
+ /* Call the disconect handler. */
1356
+ result = me->disconnectHandler(me, me->disconnectHandlerUserData);
1357
+ if (result == AMPS_E_OK)
1358
+ {
1359
+ #ifdef _WIN32
1360
+ if (tidH)
1361
+ {
1362
+ amps_tcps_set_thread_key(tidH);
1363
+ }
1364
+ #else
1365
+ amps_tcps_set_thread_key(vpTid);
1366
+ #endif
1367
+ }
1368
+
1369
+ error:
1370
+ AMPS_UNLOCK(&me->lock);
1371
+ #ifndef _WIN32
1372
+ pthread_cleanup_pop(0);
1373
+ pthread_setcancelstate(cancelState, &unusedCancelState);
1374
+ #endif
1375
+
1376
+ return result;
1377
+ }
1378
+
1379
+ void amps_tcps_handle_stream_corruption(
1380
+ amps_tcps_t* me, unsigned failedConnectionVersion)
1381
+ {
1382
+ amps_tcps_set_error(me, "The connection appears corrupt. Disconnecting.");
1383
+ amps_tcps_handle_disconnect(me, failedConnectionVersion);
1384
+ }
1385
+
1386
+
1387
+ amps_result
1388
+ amps_tcps_send_with_version(amps_handle transport,
1389
+ amps_handle message,
1390
+ unsigned* version_out)
1391
+ {
1392
+ amps_result result = AMPS_E_OK;
1393
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1394
+ size_t len = 16 * 1024;
1395
+ int bytesWritten = -1;
1396
+ unsigned int bytesWrittenN = 0;
1397
+ int bytesSent = 0;
1398
+
1399
+ *version_out = me->connectionVersion;
1400
+
1401
+ if (me->disconnecting)
1402
+ {
1403
+ amps_tcps_set_error(me, "Disconnecting.");
1404
+ return AMPS_E_DISCONNECTED;
1405
+ }
1406
+
1407
+ if (me->fd == AMPS_INVALID_SOCKET)
1408
+ {
1409
+ amps_tcps_set_error(me, "Not connected.");
1410
+ return AMPS_E_DISCONNECTED;
1411
+ }
1412
+
1413
+ /* serialize */
1414
+ AMPS_LOCK(&me->sendLock);
1415
+ #ifndef _WIN32
1416
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me->sendLock);
1417
+ #endif
1418
+ if (me->ssl == 0)
1419
+ {
1420
+ amps_tcps_set_error(me, "Not connected.");
1421
+ result = AMPS_E_CONNECTION;
1422
+ goto error;
1423
+ }
1424
+ while (bytesWritten < 0)
1425
+ {
1426
+ if (me->buf == NULL)
1427
+ {
1428
+ me->buf = (char*)malloc(len);
1429
+ if (me->buf == NULL)
1430
+ {
1431
+ amps_tcps_set_error(me, "Unable to allocate memory to send message.");
1432
+ result = AMPS_E_MEMORY;
1433
+ goto error;
1434
+ }
1435
+ me->capacity = len;
1436
+ }
1437
+ else
1438
+ {
1439
+ len = me->capacity;
1440
+ }
1441
+ /* reserve 4 bytes for the length of the message */
1442
+ bytesWritten = amps_message_serialize(message, me->serializer, (me->buf) + 4, len - 4);
1443
+ /* amps_message_serialize could have written 0 bytes.
1444
+ * who are we to judge? If it returns less than 0,
1445
+ * there wasn't enough room. */
1446
+ if (bytesWritten >= 0)
1447
+ {
1448
+ break;
1449
+ }
1450
+ /* free this buffer, allocate a larger buffer next time */
1451
+ free(me->buf);
1452
+ me->capacity = 0;
1453
+ me->buf = NULL;
1454
+ len = (size_t)((double)len * 1.5);
1455
+ }
1456
+ /* once we're done, we don't free buf -- it hangs around until we need it next time.
1457
+ * record the message length all up in the first 4 bytes. */
1458
+ bytesWrittenN = htonl((unsigned int)bytesWritten);
1459
+ me->filterFunction((const unsigned char*)(me->buf + 4), (size_t)bytesWritten, 0, me->filterUserData);
1460
+ *((unsigned int*)(me->buf)) = bytesWrittenN;
1461
+ bytesWritten += 4;
1462
+ /*now, send */
1463
+ while (bytesSent < bytesWritten)
1464
+ {
1465
+ int bytesWrittenThisTime;
1466
+ bytesWrittenThisTime = _amps_SSL_write(me->ssl, (me->buf) + bytesSent, bytesWritten - bytesSent);
1467
+ if (bytesWrittenThisTime <= 0)
1468
+ {
1469
+ // If error code is want read or want write, this is retryable
1470
+ int errorcode_ = _amps_SSL_get_error(me->ssl, bytesWrittenThisTime);
1471
+ if (errorcode_ == AMPS_SSL_ERROR_WANT_READ
1472
+ || errorcode_ == AMPS_SSL_ERROR_WANT_WRITE)
1473
+ {
1474
+ AMPS_UNLOCK(&me->sendLock);
1475
+ if (me->disconnecting)
1476
+ {
1477
+ amps_tcps_set_error(me, "Disconnecting.");
1478
+ result = AMPS_E_DISCONNECTED;
1479
+ AMPS_LOCK(&me->sendLock);
1480
+ goto error;
1481
+ }
1482
+ if (me->fd == AMPS_INVALID_SOCKET)
1483
+ {
1484
+ amps_tcps_set_error(me, "Not connected.");
1485
+ result = AMPS_E_DISCONNECTED;
1486
+ AMPS_LOCK(&me->sendLock);
1487
+ goto error;
1488
+ }
1489
+ AMPS_LOCK(&me->sendLock);
1490
+ if (me->ssl == 0)
1491
+ {
1492
+ amps_tcps_set_error(me, "Not connected.");
1493
+ result = AMPS_E_CONNECTION;
1494
+ goto error;
1495
+ }
1496
+ continue;
1497
+ }
1498
+ /* record the error */
1499
+ amps_tcps_set_error(me, "The connection is closed.");
1500
+ result = AMPS_E_DISCONNECTED;
1501
+ goto error;
1502
+ }
1503
+ bytesSent += bytesWrittenThisTime;
1504
+ }
1505
+ error:
1506
+ AMPS_UNLOCK(&me->sendLock);
1507
+ #ifndef _WIN32
1508
+ pthread_cleanup_pop(0);
1509
+ #endif
1510
+
1511
+ return result;
1512
+ }
1513
+
1514
+ amps_result
1515
+ amps_tcps_send(amps_handle transport,
1516
+ amps_handle message)
1517
+ {
1518
+ unsigned version_out;
1519
+ return amps_tcps_send_with_version(transport, message, &version_out);
1520
+ }
1521
+
1522
+ /* Returns # bytes read, 0 if a timeout occurred without a read,
1523
+ * and <0 if an error occurred.
1524
+ */
1525
+ int amps_tcps_locked_read(amps_tcps_t* me_,
1526
+ char* readPoint_,
1527
+ int bytes_,
1528
+ int* pErrorcode_)
1529
+ {
1530
+ int rc = 0;
1531
+ int fd = (int)me_->fd;
1532
+ int locked = 0;
1533
+
1534
+ while (locked == 0)
1535
+ {
1536
+ if (me_->disconnecting || fd != me_->fd || !me_->ssl
1537
+ || me_->thread != AMPS_CURRENT_THREAD() /* our cancellation mechanism on win32 */
1538
+ || me_->destroying || fd == AMPS_INVALID_SOCKET)
1539
+ {
1540
+ return 0;
1541
+ }
1542
+ locked = (int)AMPS_SPIN_LOCK(&me_->sendLock);
1543
+ }
1544
+ if (me_->disconnecting || fd != me_->fd || !me_->ssl
1545
+ || me_->thread != AMPS_CURRENT_THREAD() /* our cancellation mechanism on win32 */
1546
+ || me_->destroying || fd == AMPS_INVALID_SOCKET)
1547
+ {
1548
+ AMPS_UNLOCK(&me_->sendLock);
1549
+ return 0;
1550
+ }
1551
+ // Use select to wait for data if none already exists on the ssl.
1552
+ if (!_amps_SSL_pending(me_->ssl))
1553
+ {
1554
+ struct timeval tv;
1555
+ fd_set readfds, exceptfds;
1556
+ tv.tv_sec = 0;
1557
+ tv.tv_usec = 1000;
1558
+ FD_ZERO(&readfds);
1559
+ FD_SET(fd, &readfds);
1560
+ FD_ZERO(&exceptfds);
1561
+ FD_SET(fd, &exceptfds);
1562
+ AMPS_UNLOCK(&me_->sendLock);
1563
+ #ifdef _WIN32
1564
+ if (select(1, &readfds, 0, &exceptfds, &tv) == 0)
1565
+ #else
1566
+ if (select(fd + 1, &readfds, 0, &exceptfds, &tv) == 0)
1567
+ #endif
1568
+ {
1569
+ return 0;
1570
+ }
1571
+ AMPS_LOCK(&me_->sendLock);
1572
+ if (me_->disconnecting || fd != me_->fd || !me_->ssl
1573
+ || me_->thread != AMPS_CURRENT_THREAD() /* our cancellation mechanism on win32 */
1574
+ || me_->destroying || fd == AMPS_INVALID_SOCKET)
1575
+ {
1576
+ AMPS_UNLOCK(&me_->sendLock);
1577
+ return 0;
1578
+ }
1579
+ }
1580
+
1581
+ #ifndef _WIN32
1582
+ pthread_cleanup_push(amps_cleanup_unlock_mutex, (void*)&me_->sendLock);
1583
+ #endif
1584
+ rc = _amps_SSL_read(me_->ssl, readPoint_, bytes_);
1585
+ *pErrorcode_ = rc <= 0 ? _amps_SSL_get_error(me_->ssl, rc) : 0;
1586
+
1587
+ AMPS_UNLOCK(&me_->sendLock);
1588
+ #ifndef _WIN32
1589
+ pthread_cleanup_pop(0);
1590
+ #endif
1591
+
1592
+ if (rc <= 0)
1593
+ {
1594
+ if (*pErrorcode_ == AMPS_SSL_ERROR_WANT_READ)
1595
+ {
1596
+ return 0;
1597
+ }
1598
+ // End of stream
1599
+ return -1;
1600
+ }
1601
+ return rc;
1602
+ }
1603
+
1604
+ #ifdef _WIN32
1605
+ DWORD amps_tcps_threaded_reader(void* userData)
1606
+ {
1607
+ AMPS_THREAD_ID tid = AMPS_CURRENT_THREAD();
1608
+ HANDLE tidH = GetCurrentThread();
1609
+ amps_tcps_t* me = (amps_tcps_t*)userData;
1610
+ if (me->threadCreatedCallback)
1611
+ {
1612
+ amps_result result = me->threadCreatedCallback(tidH,
1613
+ me->threadCreatedCallbackUserData);
1614
+ AMPS_IEX(&me->threadCreatedCallbackResult, (long)result);
1615
+ if (result != AMPS_E_OK)
1616
+ {
1617
+ return (DWORD)0;
1618
+ }
1619
+ }
1620
+ else
1621
+ {
1622
+ AMPS_IEX(&me->threadCreatedCallbackResult, (long)AMPS_E_OK);
1623
+ }
1624
+ #else
1625
+ void* amps_tcps_threaded_reader(void* userData)
1626
+ {
1627
+ int unusedCancelState = 0;
1628
+ amps_tcps_t* me = (amps_tcps_t*)userData;
1629
+ AMPS_THREAD_ID tid = AMPS_CURRENT_THREAD();
1630
+ /* Wait for pthread_create to set me->thread */
1631
+ while (me->thread != tid
1632
+ && !me->disconnecting
1633
+ && !me->destroying)
1634
+ {
1635
+ AMPS_SLEEP(5);
1636
+ }
1637
+ if (me->threadCreatedCallback)
1638
+ {
1639
+ amps_result result = me->threadCreatedCallback(me->thread,
1640
+ me->threadCreatedCallbackUserData);
1641
+ AMPS_IEX(&me->threadCreatedCallbackResult, (long)result);
1642
+ if (result != AMPS_E_OK)
1643
+ {
1644
+ return NULL;
1645
+ }
1646
+ }
1647
+ else
1648
+ {
1649
+ AMPS_IEX(&me->threadCreatedCallbackResult, (long)AMPS_E_OK);
1650
+ }
1651
+ #endif
1652
+ unsigned char* buffer = 0, *newBuffer = 0, *end = 0, *readPoint = 0;
1653
+ unsigned char* parsePoint = 0;
1654
+
1655
+ unsigned int msglenN = 0;
1656
+ unsigned long msglen = 0, currentPosition = 0, bytesRead = 0;
1657
+ int received = 0;
1658
+ int cancelState = 0;
1659
+ const size_t BUFFER_SIZE = 16 * 1024;
1660
+ const unsigned MAX_MESSAGE_SIZE = 1024 * 1024 * 1024;
1661
+ amps_uint64_t lastReadTime = 0;
1662
+ amps_uint64_t lastIdleTime = 0;
1663
+ amps_handle message = 0;
1664
+
1665
+ /* capture the connection version we are using now. */
1666
+ unsigned connectionVersion = me->connectionVersion;
1667
+ AMPS_SOCKET fd = me->fd;
1668
+
1669
+ lastReadTime = amps_now();
1670
+ lastIdleTime = lastReadTime;
1671
+
1672
+ #ifndef _WIN32
1673
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1674
+ #endif
1675
+ message = amps_message_create(NULL);
1676
+ buffer = (unsigned char*)malloc(BUFFER_SIZE);
1677
+ #ifndef _WIN32
1678
+ pthread_cleanup_push(amps_message_destroy, (void*)message);
1679
+ pthread_cleanup_push(amps_cleanup_free_buffer, (void*)(&buffer));
1680
+ pthread_setcancelstate(cancelState, &unusedCancelState);
1681
+ #endif
1682
+ if (!buffer)
1683
+ {
1684
+ amps_tcps_handle_disconnect(me, connectionVersion);
1685
+ goto cleanup;
1686
+ }
1687
+
1688
+ end = buffer + BUFFER_SIZE;
1689
+ readPoint = buffer;
1690
+ parsePoint = buffer;
1691
+
1692
+ /* while we're open and not disconnecting */
1693
+ while (connectionVersion == me->connectionVersion
1694
+ && !me->disconnecting
1695
+ && fd == me->fd
1696
+ && me->thread == AMPS_CURRENT_THREAD() /* our cancellation mechanism on win32 */
1697
+ )
1698
+ {
1699
+ int errorcode = 0;
1700
+ if (me->destroying)
1701
+ {
1702
+ goto cleanup;
1703
+ }
1704
+ if (me->idleTimeMillis > 0 &&
1705
+ (amps_now() - lastIdleTime) > me->idleTimeMillis)
1706
+ {
1707
+ lastIdleTime = amps_now();
1708
+ #ifndef _WIN32
1709
+ cancelState = 0;
1710
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1711
+ #endif
1712
+ me->messageHandler(0L,
1713
+ me->messageHandlerUserData);
1714
+ #ifndef _WIN32
1715
+ pthread_setcancelstate(cancelState, &unusedCancelState);
1716
+ #endif
1717
+ }
1718
+
1719
+ received = amps_tcps_locked_read(me, (char*) readPoint,
1720
+ (int)(end - readPoint), &errorcode);
1721
+
1722
+ if (received > 0)
1723
+ {
1724
+ /* Call filter function without the 4 byte size */
1725
+ me->filterFunction(readPoint, (size_t)received, 1, me->filterUserData);
1726
+ readPoint += received;
1727
+ lastReadTime = amps_now();
1728
+ }
1729
+ else
1730
+ {
1731
+ // errorcode could be an ssl error code, so check for errno
1732
+ int sysError = GET_ERRNO;
1733
+ if (sysError)
1734
+ {
1735
+ errorcode = sysError;
1736
+ }
1737
+ if (errorcode == SOCK_ERRORCODE(EINTR))
1738
+ {
1739
+ continue;
1740
+ }
1741
+ /* disconnect if not a timeout error, or the user only set a read timeout, or the
1742
+ * read timeout has been exceeded. */
1743
+ if ( (errorcode != 0
1744
+ && ((errorcode != SOCK_ERRORCODE(ETIMEDOUT)
1745
+ && errorcode != SOCK_ERRORCODE(EWOULDBLOCK))
1746
+ || me->idleTimeMillis == 0))
1747
+ || (me->readTimeoutMillis && amps_now() - lastReadTime > me->readTimeoutMillis))
1748
+ {
1749
+ if (!me->disconnecting)
1750
+ {
1751
+ amps_tcps_handle_disconnect(me, connectionVersion);
1752
+ }
1753
+ goto cleanup;
1754
+ }
1755
+ continue;
1756
+ }
1757
+
1758
+ while (readPoint >= parsePoint + 4 &&
1759
+ fd == me->fd &&
1760
+ me->connectionVersion == connectionVersion)
1761
+ {
1762
+ msglenN = *(unsigned int*)parsePoint;
1763
+ msglen = ntohl(msglenN);
1764
+ if (msglen > MAX_MESSAGE_SIZE)
1765
+ {
1766
+ amps_tcps_handle_stream_corruption(me, connectionVersion);
1767
+ goto cleanup;
1768
+ }
1769
+ if (readPoint >= (parsePoint + msglen + 4))
1770
+ {
1771
+ /* there are enough bytes to parse this guy. */
1772
+ parsePoint += 4;
1773
+ if (amps_message_pre_deserialize(message, me->serializer,
1774
+ (amps_char*)parsePoint, msglen) == AMPS_E_OK)
1775
+ {
1776
+ currentPosition = 0;
1777
+ while (currentPosition < msglen &&
1778
+ fd == me->fd &&
1779
+ me->connectionVersion == connectionVersion)
1780
+ {
1781
+ if (amps_message_deserialize(message, me->serializer,
1782
+ currentPosition,
1783
+ &bytesRead) != AMPS_E_OK)
1784
+ {
1785
+ amps_tcps_handle_stream_corruption(me, connectionVersion);
1786
+ goto cleanup;
1787
+ }
1788
+ if (me->messageHandler)
1789
+ {
1790
+ #ifndef _WIN32
1791
+ cancelState = 0;
1792
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1793
+ #endif
1794
+ me->messageHandler(message,
1795
+ me->messageHandlerUserData);
1796
+ #ifndef _WIN32
1797
+ pthread_setcancelstate(cancelState, &unusedCancelState);
1798
+ #endif
1799
+ }
1800
+ currentPosition += bytesRead;
1801
+ }
1802
+ }
1803
+ else
1804
+ {
1805
+ amps_tcps_handle_stream_corruption(me, connectionVersion);
1806
+ goto cleanup;
1807
+ }
1808
+ parsePoint += msglen;
1809
+ }
1810
+ else if (end < buffer + msglen + 4)
1811
+ {
1812
+ /* this message is larger than the buffer
1813
+ * resize to 2* larger of this message or current buffer size */
1814
+ size_t newLength = end < buffer + (msglen * 2) ?
1815
+ msglen * 2 : (size_t)(end - buffer);
1816
+ newBuffer = (unsigned char*)malloc( newLength );
1817
+ if (newBuffer == NULL)
1818
+ {
1819
+ assert(readPoint >= parsePoint);
1820
+ /* stream broken */
1821
+ amps_tcps_handle_disconnect(me, connectionVersion);
1822
+ goto cleanup;
1823
+ }
1824
+ memcpy(newBuffer, parsePoint, (size_t)(readPoint - parsePoint));
1825
+ readPoint = newBuffer + (readPoint - parsePoint);
1826
+ parsePoint = newBuffer;
1827
+ #ifndef _WIN32
1828
+ cancelState = 0;
1829
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1830
+ #endif
1831
+ free(buffer);
1832
+ buffer = newBuffer;
1833
+ #ifndef _WIN32
1834
+ pthread_setcancelstate(cancelState, &unusedCancelState);
1835
+ #endif
1836
+ end = newBuffer + newLength;
1837
+ assert(readPoint >= parsePoint);
1838
+ break;
1839
+ }
1840
+ else
1841
+ {
1842
+ /* Need to read more data to finish this message
1843
+ * Move what we have to the front of the buffer. */
1844
+ break;
1845
+ }
1846
+ } /*while(readPoint >= parsePoint + 4) */
1847
+ if (readPoint > parsePoint)
1848
+ {
1849
+ memmove(buffer, parsePoint, (size_t)(readPoint - parsePoint));
1850
+ }
1851
+ readPoint = buffer + (readPoint - parsePoint);
1852
+ parsePoint = buffer;
1853
+ } /* while(fd == me->fd) */
1854
+ cleanup:
1855
+ #ifndef _WIN32
1856
+ cancelState = 0;
1857
+ pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cancelState);
1858
+ pthread_cleanup_pop(0);
1859
+ pthread_cleanup_pop(0);
1860
+ #endif
1861
+ amps_message_destroy(message);
1862
+ free(buffer);
1863
+ // If exiting as the reader thread, clear me->thread
1864
+ // Unless me-thread is 0, we're not getting joined, so detach
1865
+ if (me->threadExitCallback)
1866
+ {
1867
+ me->threadExitCallback(tid, me->threadExitCallbackUserData);
1868
+ }
1869
+ #if __STDC_VERSION__ >= 201100
1870
+ AMPS_THREAD_ID mytid = tid;
1871
+ bool swapped = atomic_compare_exchange_strong(&(me->thread), &tid, 0);
1872
+ if (swapped || me->thread != 0)
1873
+ #elif defined(_WIN32)
1874
+ // This returns the initial value of me->thread
1875
+ if (InterlockedCompareExchange((volatile unsigned int*)(&(me->thread)),
1876
+ (unsigned int)tid, (unsigned int)0) != 0)
1877
+ #else
1878
+ AMPS_THREAD_ID mytid = tid;
1879
+ int swapped = (int)__sync_bool_compare_and_swap(&(me->thread), tid, 0);
1880
+ if (swapped || me->thread != 0)
1881
+ #endif
1882
+ {
1883
+ AMPS_INC_THREAD_COUNT(&amps_thread_detach_count);
1884
+ #ifdef _WIN32
1885
+ CloseHandle((HANDLE)(AMPS_IEX(&(me->threadH), 0)));
1886
+ #else
1887
+ pthread_detach(mytid);
1888
+ #endif
1889
+ amps_tcps_set_thread_key(NULL);
1890
+ }
1891
+ #ifdef _WIN32
1892
+ else
1893
+ {
1894
+ tidH = TlsGetValue(amps_tcps_get_thread_key());
1895
+ if (tidH != NULL)
1896
+ {
1897
+ CloseHandle(tidH);
1898
+ }
1899
+ }
1900
+ #endif
1901
+
1902
+ return 0;
1903
+ }
1904
+
1905
+ amps_result
1906
+ amps_tcps_attempt_reconnect(amps_handle transport, unsigned version)
1907
+ {
1908
+ amps_result res;
1909
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1910
+ if (version == 0)
1911
+ {
1912
+ version = me->connectionVersion;
1913
+ }
1914
+ res = amps_tcps_handle_disconnect(me, version);
1915
+ if (res == AMPS_E_OK)
1916
+ {
1917
+ // We don't want non-receive threads detaching
1918
+ amps_tcps_set_thread_key(NULL);
1919
+ res = AMPS_E_RETRY;
1920
+ }
1921
+ return res;
1922
+ }
1923
+
1924
+ /* public-api -- get a socket */
1925
+ AMPS_SOCKET
1926
+ amps_tcps_get_socket(amps_handle transport)
1927
+ {
1928
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1929
+ return me->fd;
1930
+ }
1931
+
1932
+ void* amps_tcps_get_SSL(amps_handle transport)
1933
+ {
1934
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1935
+ return me->ssl;
1936
+ }
1937
+
1938
+ amps_result
1939
+ amps_tcps_update_read_timeout(amps_tcps_t* me)
1940
+ {
1941
+ int timeout = (int)((me->readTimeoutMillis && me->idleTimeMillis) ?
1942
+ AMPS_MIN(me->readTimeoutMillis, me->idleTimeMillis) :
1943
+ AMPS_MAX(me->readTimeoutMillis, me->idleTimeMillis));
1944
+ int rc = 0;
1945
+ #ifdef _WIN32
1946
+ DWORD timeoutMillis = timeout;
1947
+ rc = setsockopt(me->fd, SOL_SOCKET, SO_RCVTIMEO,
1948
+ (const char*)&timeoutMillis, sizeof(DWORD));
1949
+ #else
1950
+ struct timeval tv;
1951
+ tv.tv_sec = timeout / 1000;
1952
+ tv.tv_usec = (timeout % 1000) * 1000;
1953
+ rc = setsockopt(me->fd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(struct timeval));
1954
+ #endif
1955
+ int sysError = GET_ERRNO;
1956
+ if (rc == -1)
1957
+ {
1958
+ amps_tcps_set_socket_error(me, sysError);
1959
+ return AMPS_E_USAGE;
1960
+ }
1961
+ return AMPS_E_OK;
1962
+ }
1963
+ amps_result
1964
+ amps_tcps_set_read_timeout(amps_handle transport, int readTimeout)
1965
+ {
1966
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1967
+ me->readTimeoutMillis = (amps_uint64_t)readTimeout * 1000;
1968
+ return amps_tcps_update_read_timeout(me);
1969
+ }
1970
+
1971
+
1972
+ void
1973
+ amps_tcps_set_filter_function(amps_handle transport, amps_transport_filter_function filterFunction_, void* userdata_)
1974
+ {
1975
+ amps_tcps_t* me = (amps_tcps_t*)transport;
1976
+ me->filterUserData = userdata_;
1977
+ me->filterFunction = filterFunction_ ? filterFunction_ : amps_tcps_noop_filter_function;
1978
+ }
1979
+
1980
+ void
1981
+ amps_tcps_set_thread_created_callback(amps_handle transport_, amps_thread_created_callback threadCreatedCallback_, void* userdata_)
1982
+ {
1983
+ amps_tcps_t* me = (amps_tcps_t*)transport_;
1984
+ me->threadCreatedCallbackUserData = userdata_;
1985
+ me->threadCreatedCallback = threadCreatedCallback_;
1986
+ }
1987
+
1988
+ void
1989
+ amps_tcps_set_thread_exit_callback(amps_handle transport_, amps_thread_exit_callback threadExitCallback_, void* userdata_)
1990
+ {
1991
+ amps_tcps_t* me = (amps_tcps_t*)transport_;
1992
+ me->threadExitCallbackUserData = userdata_;
1993
+ me->threadExitCallback = threadExitCallback_;
1994
+ }
1995
+
1996
+ amps_result
1997
+ amps_tcps_set_idle_time(amps_handle transport, int millis)
1998
+ {
1999
+ amps_tcps_t* me = (amps_tcps_t*)transport;
2000
+ if (!me->idleTimeMillis || (amps_uint64_t)millis < me->idleTimeMillis)
2001
+ {
2002
+ me->idleTimeMillis = (amps_uint64_t)millis;
2003
+ }
2004
+ return amps_tcps_update_read_timeout(me);
2005
+ }