@geekmidas/events 9.0.2 → 10.0.0-alpha.0

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 (353) hide show
  1. package/dist/{PgBossConnection-B71ssr72.cjs → PgBossConnection-23soZ_aM.cjs} +2 -2
  2. package/dist/{PgBossConnection-B71ssr72.cjs.map → PgBossConnection-23soZ_aM.cjs.map} +1 -1
  3. package/dist/PgBossConnection-CCXhoNzb.cjs +4 -0
  4. package/dist/{PgBossConnection-Bj_Wo1lQ.mjs → PgBossConnection-DvNbd4Zk.mjs} +2 -2
  5. package/dist/{PgBossConnection-Bj_Wo1lQ.mjs.map → PgBossConnection-DvNbd4Zk.mjs.map} +1 -1
  6. package/dist/PgBossConnection-_gdM40JB.mjs +4 -0
  7. package/dist/{RabbitMQConnection-DmMMosT4.cjs → RabbitMQConnection-BKEdCUro.cjs} +2 -2
  8. package/dist/{RabbitMQConnection-DmMMosT4.cjs.map → RabbitMQConnection-BKEdCUro.cjs.map} +1 -1
  9. package/dist/RabbitMQConnection-CCOqDDnb.cjs +4 -0
  10. package/dist/RabbitMQConnection-DJEyM-Bu.mjs +4 -0
  11. package/dist/{RabbitMQConnection-BtKZjtZY.mjs → RabbitMQConnection-DJgUPc19.mjs} +2 -2
  12. package/dist/{RabbitMQConnection-BtKZjtZY.mjs.map → RabbitMQConnection-DJgUPc19.mjs.map} +1 -1
  13. package/dist/{SNSConnection-CAcbLQOy.cjs → SNSConnection-B2K86hpz.cjs} +7 -8
  14. package/dist/SNSConnection-B2K86hpz.cjs.map +1 -0
  15. package/dist/SNSConnection-BVo84FeW.mjs +5 -0
  16. package/dist/SNSConnection-DIHRjrQF.cjs +5 -0
  17. package/dist/{SNSConnection-CVjH93lb.mjs → SNSConnection-v9jjF99w.mjs} +7 -8
  18. package/dist/SNSConnection-v9jjF99w.mjs.map +1 -0
  19. package/dist/{SQSConnection-CT3S7_zP.mjs → SQSConnection-4tBMkVZE.mjs} +7 -8
  20. package/dist/SQSConnection-4tBMkVZE.mjs.map +1 -0
  21. package/dist/SQSConnection-BBLAvF-1.cjs +5 -0
  22. package/dist/{SQSConnection-Y0mdVTcB.cjs → SQSConnection-BaC7rGhI.cjs} +7 -8
  23. package/dist/SQSConnection-BaC7rGhI.cjs.map +1 -0
  24. package/dist/SQSConnection-DbavOq8_.mjs +5 -0
  25. package/dist/{SQSSubscriber-CQdSFzpe.mjs → SQSSubscriber-BMWZ3s5q.mjs} +1 -1
  26. package/dist/{SQSSubscriber-CQdSFzpe.mjs.map → SQSSubscriber-BMWZ3s5q.mjs.map} +1 -1
  27. package/dist/{SQSSubscriber-C4UA2hKq.cjs → SQSSubscriber-YXPlg2rm.cjs} +2 -2
  28. package/dist/{SQSSubscriber-C4UA2hKq.cjs.map → SQSSubscriber-YXPlg2rm.cjs.map} +1 -1
  29. package/dist/basic/index.cjs +71 -8
  30. package/dist/basic/index.cjs.map +1 -0
  31. package/dist/basic/index.d.cts +44 -5
  32. package/dist/basic/index.d.cts.map +1 -0
  33. package/dist/basic/index.d.mts +44 -5
  34. package/dist/basic/index.d.mts.map +1 -0
  35. package/dist/basic/index.mjs +67 -5
  36. package/dist/basic/index.mjs.map +1 -0
  37. package/dist/chunk-B9dir_RE.mjs +11 -0
  38. package/dist/{chunk-CUT6urMc.cjs → chunk-CsX-DzYB.cjs} +12 -0
  39. package/dist/index.cjs +189 -6
  40. package/dist/index.cjs.map +1 -0
  41. package/dist/index.d.cts +46 -5
  42. package/dist/index.d.cts.map +1 -0
  43. package/dist/index.d.mts +46 -5
  44. package/dist/index.d.mts.map +1 -0
  45. package/dist/index.mjs +188 -5
  46. package/dist/index.mjs.map +1 -0
  47. package/dist/pgboss/index.cjs +81 -5
  48. package/dist/pgboss/index.cjs.map +1 -0
  49. package/dist/pgboss/index.d.cts +65 -5
  50. package/dist/pgboss/index.d.cts.map +1 -0
  51. package/dist/pgboss/index.d.mts +65 -5
  52. package/dist/pgboss/index.d.mts.map +1 -0
  53. package/dist/pgboss/index.mjs +81 -5
  54. package/dist/pgboss/index.mjs.map +1 -0
  55. package/dist/rabbitmq/index.cjs +95 -5
  56. package/dist/rabbitmq/index.cjs.map +1 -0
  57. package/dist/rabbitmq/index.d.cts +83 -5
  58. package/dist/rabbitmq/index.d.cts.map +1 -0
  59. package/dist/rabbitmq/index.d.mts +83 -5
  60. package/dist/rabbitmq/index.d.mts.map +1 -0
  61. package/dist/rabbitmq/index.mjs +95 -5
  62. package/dist/rabbitmq/index.mjs.map +1 -0
  63. package/dist/sns/index.cjs +186 -7
  64. package/dist/sns/index.cjs.map +1 -0
  65. package/dist/sns/index.d.cts +109 -5
  66. package/dist/sns/index.d.cts.map +1 -0
  67. package/dist/sns/index.d.mts +109 -5
  68. package/dist/sns/index.d.mts.map +1 -0
  69. package/dist/sns/index.mjs +179 -7
  70. package/dist/sns/index.mjs.map +1 -0
  71. package/dist/sns/snsUrl.cjs +7 -0
  72. package/dist/sns/snsUrl.d.cts +2 -0
  73. package/dist/sns/snsUrl.d.mts +2 -0
  74. package/dist/sns/snsUrl.mjs +3 -0
  75. package/dist/snsUrl-ASdc0D1v.d.cts +61 -0
  76. package/dist/snsUrl-ASdc0D1v.d.cts.map +1 -0
  77. package/dist/snsUrl-CifYhPAa.mjs +79 -0
  78. package/dist/snsUrl-CifYhPAa.mjs.map +1 -0
  79. package/dist/snsUrl-FRbRcwF0.d.mts +61 -0
  80. package/dist/snsUrl-FRbRcwF0.d.mts.map +1 -0
  81. package/dist/snsUrl-f2gU3CzK.cjs +114 -0
  82. package/dist/snsUrl-f2gU3CzK.cjs.map +1 -0
  83. package/dist/sqs/index.cjs +67 -5
  84. package/dist/sqs/index.cjs.map +1 -0
  85. package/dist/sqs/index.d.cts +101 -5
  86. package/dist/sqs/index.d.cts.map +1 -0
  87. package/dist/sqs/index.d.mts +101 -5
  88. package/dist/sqs/index.d.mts.map +1 -0
  89. package/dist/sqs/index.mjs +60 -5
  90. package/dist/sqs/index.mjs.map +1 -0
  91. package/dist/sqs/sqsUrl.cjs +7 -0
  92. package/dist/sqs/sqsUrl.d.cts +2 -0
  93. package/dist/sqs/sqsUrl.d.mts +2 -0
  94. package/dist/sqs/sqsUrl.mjs +3 -0
  95. package/dist/sqsUrl-BV6zS-mi.d.mts +60 -0
  96. package/dist/sqsUrl-BV6zS-mi.d.mts.map +1 -0
  97. package/dist/sqsUrl-CbAsBFHI.mjs +80 -0
  98. package/dist/sqsUrl-CbAsBFHI.mjs.map +1 -0
  99. package/dist/sqsUrl-CdisN3GU.cjs +115 -0
  100. package/dist/sqsUrl-CdisN3GU.cjs.map +1 -0
  101. package/dist/sqsUrl-DZDPHxIk.d.cts +60 -0
  102. package/dist/sqsUrl-DZDPHxIk.d.cts.map +1 -0
  103. package/dist/{types-Dh9Jyinx.d.mts → types-BmixGrOD.d.cts} +1 -1
  104. package/dist/{types-Dh9Jyinx.d.mts.map → types-BmixGrOD.d.cts.map} +1 -1
  105. package/dist/{types-BrdcSEnd.mjs → types-CYDt-2RQ.mjs} +1 -1
  106. package/dist/{types-BrdcSEnd.mjs.map → types-CYDt-2RQ.mjs.map} +1 -1
  107. package/dist/{types-Dj23od3e.d.cts → types-DycjsYms.d.mts} +1 -1
  108. package/dist/{types-Dj23od3e.d.cts.map → types-DycjsYms.d.mts.map} +1 -1
  109. package/package.json +26 -3
  110. package/CHANGELOG.md +0 -109
  111. package/dist/BasicConnection-CQsJpx2J.d.cts +0 -27
  112. package/dist/BasicConnection-CQsJpx2J.d.cts.map +0 -1
  113. package/dist/BasicConnection-CxfNEvlb.cjs +0 -48
  114. package/dist/BasicConnection-CxfNEvlb.cjs.map +0 -1
  115. package/dist/BasicConnection-DcRelT64.d.mts +0 -27
  116. package/dist/BasicConnection-DcRelT64.d.mts.map +0 -1
  117. package/dist/BasicConnection-hl-Ogz3a.mjs +0 -42
  118. package/dist/BasicConnection-hl-Ogz3a.mjs.map +0 -1
  119. package/dist/BasicPublisher-C-hMX2Hy.d.mts +0 -14
  120. package/dist/BasicPublisher-C-hMX2Hy.d.mts.map +0 -1
  121. package/dist/BasicPublisher-CGMXg2I2.d.cts +0 -14
  122. package/dist/BasicPublisher-CGMXg2I2.d.cts.map +0 -1
  123. package/dist/BasicPublisher-CXAVKxgq.cjs +0 -20
  124. package/dist/BasicPublisher-CXAVKxgq.cjs.map +0 -1
  125. package/dist/BasicPublisher-DogbeHAH.mjs +0 -14
  126. package/dist/BasicPublisher-DogbeHAH.mjs.map +0 -1
  127. package/dist/BasicSubscriber-BJSZN22M.mjs +0 -16
  128. package/dist/BasicSubscriber-BJSZN22M.mjs.map +0 -1
  129. package/dist/BasicSubscriber-HzSJ_MbB.d.mts +0 -14
  130. package/dist/BasicSubscriber-HzSJ_MbB.d.mts.map +0 -1
  131. package/dist/BasicSubscriber-mVJRMXhZ.cjs +0 -22
  132. package/dist/BasicSubscriber-mVJRMXhZ.cjs.map +0 -1
  133. package/dist/BasicSubscriber-uW3IOyBj.d.cts +0 -14
  134. package/dist/BasicSubscriber-uW3IOyBj.d.cts.map +0 -1
  135. package/dist/EventConnection-4niMI6D8.d.mts +0 -13
  136. package/dist/EventConnection-4niMI6D8.d.mts.map +0 -1
  137. package/dist/EventConnection-BkA9FSVL.cjs +0 -45
  138. package/dist/EventConnection-BkA9FSVL.cjs.map +0 -1
  139. package/dist/EventConnection-Kr32GAzq.mjs +0 -40
  140. package/dist/EventConnection-Kr32GAzq.mjs.map +0 -1
  141. package/dist/EventConnection-dP42P87q.d.cts +0 -13
  142. package/dist/EventConnection-dP42P87q.d.cts.map +0 -1
  143. package/dist/EventConnection.cjs +0 -5
  144. package/dist/EventConnection.d.cts +0 -3
  145. package/dist/EventConnection.d.mts +0 -3
  146. package/dist/EventConnection.mjs +0 -4
  147. package/dist/PgBossConnection-DCfLGoHx.d.mts +0 -32
  148. package/dist/PgBossConnection-DCfLGoHx.d.mts.map +0 -1
  149. package/dist/PgBossConnection-oto_CAbP.d.cts +0 -32
  150. package/dist/PgBossConnection-oto_CAbP.d.cts.map +0 -1
  151. package/dist/PgBossPublisher-Bwo7qSoH.mjs +0 -35
  152. package/dist/PgBossPublisher-Bwo7qSoH.mjs.map +0 -1
  153. package/dist/PgBossPublisher-CqjigBVC.d.mts +0 -20
  154. package/dist/PgBossPublisher-CqjigBVC.d.mts.map +0 -1
  155. package/dist/PgBossPublisher-FTdYh58W.cjs +0 -41
  156. package/dist/PgBossPublisher-FTdYh58W.cjs.map +0 -1
  157. package/dist/PgBossPublisher-JIiB1zpA.d.cts +0 -20
  158. package/dist/PgBossPublisher-JIiB1zpA.d.cts.map +0 -1
  159. package/dist/PgBossSubscriber-BUiB1JKf.d.mts +0 -24
  160. package/dist/PgBossSubscriber-BUiB1JKf.d.mts.map +0 -1
  161. package/dist/PgBossSubscriber-BubVfuWm.cjs +0 -52
  162. package/dist/PgBossSubscriber-BubVfuWm.cjs.map +0 -1
  163. package/dist/PgBossSubscriber-Cozijfdj.d.cts +0 -24
  164. package/dist/PgBossSubscriber-Cozijfdj.d.cts.map +0 -1
  165. package/dist/PgBossSubscriber-DopATe80.mjs +0 -46
  166. package/dist/PgBossSubscriber-DopATe80.mjs.map +0 -1
  167. package/dist/Publisher-CKloIGh6.cjs +0 -79
  168. package/dist/Publisher-CKloIGh6.cjs.map +0 -1
  169. package/dist/Publisher-ChLTrUeP.mjs +0 -74
  170. package/dist/Publisher-ChLTrUeP.mjs.map +0 -1
  171. package/dist/Publisher-DDee6xau.d.cts +0 -21
  172. package/dist/Publisher-DDee6xau.d.cts.map +0 -1
  173. package/dist/Publisher-VHumMkrP.d.mts +0 -21
  174. package/dist/Publisher-VHumMkrP.d.mts.map +0 -1
  175. package/dist/Publisher.cjs +0 -4
  176. package/dist/Publisher.d.cts +0 -3
  177. package/dist/Publisher.d.mts +0 -3
  178. package/dist/Publisher.mjs +0 -4
  179. package/dist/RabbitMQConnection-DV9t3VYp.d.mts +0 -44
  180. package/dist/RabbitMQConnection-DV9t3VYp.d.mts.map +0 -1
  181. package/dist/RabbitMQConnection-jNME_eR7.d.cts +0 -44
  182. package/dist/RabbitMQConnection-jNME_eR7.d.cts.map +0 -1
  183. package/dist/RabbitMQPublisher-C94q6g8q.cjs +0 -45
  184. package/dist/RabbitMQPublisher-C94q6g8q.cjs.map +0 -1
  185. package/dist/RabbitMQPublisher-DKmgwqVj.d.mts +0 -25
  186. package/dist/RabbitMQPublisher-DKmgwqVj.d.mts.map +0 -1
  187. package/dist/RabbitMQPublisher-d257OHLa.d.cts +0 -25
  188. package/dist/RabbitMQPublisher-d257OHLa.d.cts.map +0 -1
  189. package/dist/RabbitMQPublisher-yUqWNq-P.mjs +0 -39
  190. package/dist/RabbitMQPublisher-yUqWNq-P.mjs.map +0 -1
  191. package/dist/RabbitMQSubscriber-BF7JGfYm.d.cts +0 -27
  192. package/dist/RabbitMQSubscriber-BF7JGfYm.d.cts.map +0 -1
  193. package/dist/RabbitMQSubscriber-BWniDtFs.mjs +0 -56
  194. package/dist/RabbitMQSubscriber-BWniDtFs.mjs.map +0 -1
  195. package/dist/RabbitMQSubscriber-CdbUy5mB.d.mts +0 -27
  196. package/dist/RabbitMQSubscriber-CdbUy5mB.d.mts.map +0 -1
  197. package/dist/RabbitMQSubscriber-DGEO-clQ.cjs +0 -62
  198. package/dist/RabbitMQSubscriber-DGEO-clQ.cjs.map +0 -1
  199. package/dist/SNSConnection-CAcbLQOy.cjs.map +0 -1
  200. package/dist/SNSConnection-CG4iEwA8.d.mts +0 -41
  201. package/dist/SNSConnection-CG4iEwA8.d.mts.map +0 -1
  202. package/dist/SNSConnection-CVjH93lb.mjs.map +0 -1
  203. package/dist/SNSConnection-Dol9FuxA.d.cts +0 -41
  204. package/dist/SNSConnection-Dol9FuxA.d.cts.map +0 -1
  205. package/dist/SNSPublisher-CjlMS3Z2.mjs +0 -41
  206. package/dist/SNSPublisher-CjlMS3Z2.mjs.map +0 -1
  207. package/dist/SNSPublisher-D50dPCEh.d.mts +0 -22
  208. package/dist/SNSPublisher-D50dPCEh.d.mts.map +0 -1
  209. package/dist/SNSPublisher-DQunY4NM.d.cts +0 -22
  210. package/dist/SNSPublisher-DQunY4NM.d.cts.map +0 -1
  211. package/dist/SNSPublisher-DV_8GGsi.cjs +0 -47
  212. package/dist/SNSPublisher-DV_8GGsi.cjs.map +0 -1
  213. package/dist/SNSSubscriber-BWaCQFl6.mjs +0 -139
  214. package/dist/SNSSubscriber-BWaCQFl6.mjs.map +0 -1
  215. package/dist/SNSSubscriber-CUgHK4W2.d.mts +0 -55
  216. package/dist/SNSSubscriber-CUgHK4W2.d.mts.map +0 -1
  217. package/dist/SNSSubscriber-ZE_-Hsps.cjs +0 -145
  218. package/dist/SNSSubscriber-ZE_-Hsps.cjs.map +0 -1
  219. package/dist/SNSSubscriber-ZGJjhXFQ.d.cts +0 -55
  220. package/dist/SNSSubscriber-ZGJjhXFQ.d.cts.map +0 -1
  221. package/dist/SQSConnection-BtEkDha8.d.cts +0 -41
  222. package/dist/SQSConnection-BtEkDha8.d.cts.map +0 -1
  223. package/dist/SQSConnection-CT3S7_zP.mjs.map +0 -1
  224. package/dist/SQSConnection-DVy43GCV.d.mts +0 -41
  225. package/dist/SQSConnection-DVy43GCV.d.mts.map +0 -1
  226. package/dist/SQSConnection-Y0mdVTcB.cjs.map +0 -1
  227. package/dist/SQSPublisher-B-32CC4G.mjs +0 -57
  228. package/dist/SQSPublisher-B-32CC4G.mjs.map +0 -1
  229. package/dist/SQSPublisher-CgUduk6H.cjs +0 -63
  230. package/dist/SQSPublisher-CgUduk6H.cjs.map +0 -1
  231. package/dist/SQSPublisher-kyl5HW3N.d.cts +0 -25
  232. package/dist/SQSPublisher-kyl5HW3N.d.cts.map +0 -1
  233. package/dist/SQSPublisher-qDE5Fp-N.d.mts +0 -25
  234. package/dist/SQSPublisher-qDE5Fp-N.d.mts.map +0 -1
  235. package/dist/SQSSubscriber-CDvaG4ij.d.cts +0 -44
  236. package/dist/SQSSubscriber-CDvaG4ij.d.cts.map +0 -1
  237. package/dist/SQSSubscriber-JfFuAAoP.d.mts +0 -44
  238. package/dist/SQSSubscriber-JfFuAAoP.d.mts.map +0 -1
  239. package/dist/Subscriber-CG_QUQZs.d.cts +0 -21
  240. package/dist/Subscriber-CG_QUQZs.d.cts.map +0 -1
  241. package/dist/Subscriber-CghW0A02.cjs +0 -88
  242. package/dist/Subscriber-CghW0A02.cjs.map +0 -1
  243. package/dist/Subscriber-DiYHmuF0.d.mts +0 -21
  244. package/dist/Subscriber-DiYHmuF0.d.mts.map +0 -1
  245. package/dist/Subscriber-bnkFtSvt.mjs +0 -83
  246. package/dist/Subscriber-bnkFtSvt.mjs.map +0 -1
  247. package/dist/Subscriber.cjs +0 -4
  248. package/dist/Subscriber.d.cts +0 -3
  249. package/dist/Subscriber.d.mts +0 -3
  250. package/dist/Subscriber.mjs +0 -4
  251. package/dist/basic/BasicConnection.cjs +0 -4
  252. package/dist/basic/BasicConnection.d.cts +0 -3
  253. package/dist/basic/BasicConnection.d.mts +0 -3
  254. package/dist/basic/BasicConnection.mjs +0 -4
  255. package/dist/basic/BasicPublisher.cjs +0 -3
  256. package/dist/basic/BasicPublisher.d.cts +0 -4
  257. package/dist/basic/BasicPublisher.d.mts +0 -4
  258. package/dist/basic/BasicPublisher.mjs +0 -3
  259. package/dist/basic/BasicSubscriber.cjs +0 -3
  260. package/dist/basic/BasicSubscriber.d.cts +0 -4
  261. package/dist/basic/BasicSubscriber.d.mts +0 -4
  262. package/dist/basic/BasicSubscriber.mjs +0 -3
  263. package/dist/pgboss/PgBossConnection.cjs +0 -4
  264. package/dist/pgboss/PgBossConnection.d.cts +0 -3
  265. package/dist/pgboss/PgBossConnection.d.mts +0 -3
  266. package/dist/pgboss/PgBossConnection.mjs +0 -4
  267. package/dist/pgboss/PgBossPublisher.cjs +0 -3
  268. package/dist/pgboss/PgBossPublisher.d.cts +0 -4
  269. package/dist/pgboss/PgBossPublisher.d.mts +0 -4
  270. package/dist/pgboss/PgBossPublisher.mjs +0 -3
  271. package/dist/pgboss/PgBossSubscriber.cjs +0 -3
  272. package/dist/pgboss/PgBossSubscriber.d.cts +0 -4
  273. package/dist/pgboss/PgBossSubscriber.d.mts +0 -4
  274. package/dist/pgboss/PgBossSubscriber.mjs +0 -3
  275. package/dist/rabbitmq/RabbitMQConnection.cjs +0 -4
  276. package/dist/rabbitmq/RabbitMQConnection.d.cts +0 -3
  277. package/dist/rabbitmq/RabbitMQConnection.d.mts +0 -3
  278. package/dist/rabbitmq/RabbitMQConnection.mjs +0 -4
  279. package/dist/rabbitmq/RabbitMQPublisher.cjs +0 -3
  280. package/dist/rabbitmq/RabbitMQPublisher.d.cts +0 -4
  281. package/dist/rabbitmq/RabbitMQPublisher.d.mts +0 -4
  282. package/dist/rabbitmq/RabbitMQPublisher.mjs +0 -3
  283. package/dist/rabbitmq/RabbitMQSubscriber.cjs +0 -3
  284. package/dist/rabbitmq/RabbitMQSubscriber.d.cts +0 -4
  285. package/dist/rabbitmq/RabbitMQSubscriber.d.mts +0 -4
  286. package/dist/rabbitmq/RabbitMQSubscriber.mjs +0 -3
  287. package/dist/sns/SNSConnection.cjs +0 -4
  288. package/dist/sns/SNSConnection.d.cts +0 -3
  289. package/dist/sns/SNSConnection.d.mts +0 -3
  290. package/dist/sns/SNSConnection.mjs +0 -4
  291. package/dist/sns/SNSPublisher.cjs +0 -3
  292. package/dist/sns/SNSPublisher.d.cts +0 -4
  293. package/dist/sns/SNSPublisher.d.mts +0 -4
  294. package/dist/sns/SNSPublisher.mjs +0 -3
  295. package/dist/sns/SNSSubscriber.cjs +0 -6
  296. package/dist/sns/SNSSubscriber.d.cts +0 -4
  297. package/dist/sns/SNSSubscriber.d.mts +0 -4
  298. package/dist/sns/SNSSubscriber.mjs +0 -6
  299. package/dist/sqs/SQSConnection.cjs +0 -4
  300. package/dist/sqs/SQSConnection.d.cts +0 -3
  301. package/dist/sqs/SQSConnection.d.mts +0 -3
  302. package/dist/sqs/SQSConnection.mjs +0 -4
  303. package/dist/sqs/SQSPublisher.cjs +0 -3
  304. package/dist/sqs/SQSPublisher.d.cts +0 -4
  305. package/dist/sqs/SQSPublisher.d.mts +0 -4
  306. package/dist/sqs/SQSPublisher.mjs +0 -3
  307. package/dist/sqs/SQSSubscriber.cjs +0 -3
  308. package/dist/sqs/SQSSubscriber.d.cts +0 -4
  309. package/dist/sqs/SQSSubscriber.d.mts +0 -4
  310. package/dist/sqs/SQSSubscriber.mjs +0 -3
  311. package/dist/types.cjs +0 -3
  312. package/dist/types.d.cts +0 -2
  313. package/dist/types.d.mts +0 -2
  314. package/dist/types.mjs +0 -3
  315. package/src/EventConnection.ts +0 -43
  316. package/src/Publisher.ts +0 -98
  317. package/src/Subscriber.ts +0 -113
  318. package/src/__tests__/EventConnection.spec.ts +0 -42
  319. package/src/__tests__/Publisher.spec.ts +0 -96
  320. package/src/__tests__/Subscriber.spec.ts +0 -109
  321. package/src/basic/BasicConnection.ts +0 -47
  322. package/src/basic/BasicPublisher.ts +0 -15
  323. package/src/basic/BasicSubscriber.ts +0 -21
  324. package/src/basic/__tests__/BasicSubscriber.spec.ts +0 -166
  325. package/src/basic/index.ts +0 -3
  326. package/src/index.ts +0 -25
  327. package/src/pgboss/PgBossConnection.ts +0 -91
  328. package/src/pgboss/PgBossPublisher.ts +0 -49
  329. package/src/pgboss/PgBossSubscriber.ts +0 -81
  330. package/src/pgboss/__tests__/pgboss.spec.ts +0 -196
  331. package/src/pgboss/__tests__/setup.ts +0 -21
  332. package/src/pgboss/index.ts +0 -5
  333. package/src/rabbitmq/RabbitMQConnection.ts +0 -148
  334. package/src/rabbitmq/RabbitMQPublisher.ts +0 -67
  335. package/src/rabbitmq/RabbitMQSubscriber.ts +0 -111
  336. package/src/rabbitmq/__tests__/RabbitMQPublisher.spec.ts +0 -378
  337. package/src/rabbitmq/__tests__/RabbitMQSubscriber.spec.ts +0 -292
  338. package/src/rabbitmq/index.ts +0 -6
  339. package/src/sns/SNSConnection.ts +0 -98
  340. package/src/sns/SNSPublisher.ts +0 -62
  341. package/src/sns/SNSSubscriber.ts +0 -218
  342. package/src/sns/__tests__/SNS-SQS-Integration.spec.ts +0 -389
  343. package/src/sns/__tests__/SNSPublisher.spec.ts +0 -449
  344. package/src/sns/__tests__/SNSSubscriber.spec.ts +0 -527
  345. package/src/sns/index.ts +0 -6
  346. package/src/sqs/SQSConnection.ts +0 -97
  347. package/src/sqs/SQSPublisher.ts +0 -105
  348. package/src/sqs/SQSSubscriber.ts +0 -181
  349. package/src/sqs/__tests__/SQSPublisher.spec.ts +0 -189
  350. package/src/sqs/index.ts +0 -6
  351. package/src/types.ts +0 -76
  352. package/tsconfig.json +0 -9
  353. package/tsdown.config.ts +0 -10
@@ -1,81 +0,0 @@
1
- import type { EventSubscriber, PublishableMessage } from '../types';
2
- import type { PgBossConnection } from './PgBossConnection';
3
-
4
- export interface PgBossSubscriberOptions {
5
- batchSize?: number;
6
- pollingIntervalSeconds?: number;
7
- }
8
-
9
- export class PgBossSubscriber<TMessage extends PublishableMessage<string, any>>
10
- implements EventSubscriber<TMessage>
11
- {
12
- constructor(
13
- private connection: PgBossConnection,
14
- private options: PgBossSubscriberOptions = {},
15
- ) {}
16
-
17
- /**
18
- * Create a PgBossSubscriber from a connection string.
19
- * Format: pgboss://user:pass@host:5432/database?schema=pgboss&batchSize=5
20
- */
21
- static async fromConnectionString<
22
- TMessage extends PublishableMessage<string, any>,
23
- >(connectionString: string): Promise<PgBossSubscriber<TMessage>> {
24
- const url = new URL(connectionString);
25
- const params = url.searchParams;
26
-
27
- const { PgBossConnection } = await import('./PgBossConnection');
28
- const connection =
29
- await PgBossConnection.fromConnectionString(connectionString);
30
-
31
- const options: PgBossSubscriberOptions = {
32
- batchSize: params.get('batchSize')
33
- ? Number.parseInt(params.get('batchSize')!, 10)
34
- : undefined,
35
- pollingIntervalSeconds: params.get('pollingIntervalSeconds')
36
- ? Number.parseInt(params.get('pollingIntervalSeconds')!, 10)
37
- : undefined,
38
- };
39
-
40
- return new PgBossSubscriber<TMessage>(connection, options);
41
- }
42
-
43
- async subscribe(
44
- messages: TMessage['type'][],
45
- listener: (payload: TMessage) => Promise<void>,
46
- ): Promise<void> {
47
- if (!this.connection.isConnected()) {
48
- await this.connection.connect();
49
- }
50
-
51
- const boss = this.connection.instance;
52
- if (!boss) {
53
- throw new Error('PgBoss instance not initialized');
54
- }
55
-
56
- for (const messageType of messages) {
57
- await boss.createQueue(messageType);
58
- await boss.work(
59
- messageType,
60
- {
61
- ...(this.options.batchSize && {
62
- batchSize: this.options.batchSize,
63
- }),
64
- ...(this.options.pollingIntervalSeconds && {
65
- pollingIntervalSeconds: this.options.pollingIntervalSeconds,
66
- }),
67
- },
68
- async (jobs) => {
69
- for (const job of jobs) {
70
- const fullMessage = {
71
- type: job.name,
72
- payload: job.data,
73
- } as TMessage;
74
-
75
- await listener(fullMessage);
76
- }
77
- },
78
- );
79
- }
80
- }
81
- }
@@ -1,196 +0,0 @@
1
- import { afterAll, beforeAll, describe, expect, it } from 'vitest';
2
- import type { PublishableMessage } from '../../types';
3
- import { PgBossConnection } from '../PgBossConnection';
4
- import { PgBossPublisher } from '../PgBossPublisher';
5
- import { PgBossSubscriber } from '../PgBossSubscriber';
6
- import { dropSchemas } from './setup';
7
-
8
- type TestMessage =
9
- | PublishableMessage<'user.created', { userId: string }>
10
- | PublishableMessage<'user.updated', { userId: string; name: string }>;
11
-
12
- const POSTGRES_URL = 'postgres://geekmidas:geekmidas@localhost:5432/geekmidas';
13
- const PGBOSS_CONNECTION_STRING =
14
- 'pgboss://geekmidas:geekmidas@localhost:5432/geekmidas?schema=pgboss_test';
15
-
16
- const TEST_SCHEMAS = [
17
- 'pgboss_conn_test',
18
- 'pgboss_conn_test2',
19
- 'pgboss_test',
20
- 'pgboss_pub_test',
21
- 'pgboss_sub_test',
22
- ];
23
-
24
- beforeAll(async () => {
25
- await dropSchemas(POSTGRES_URL, TEST_SCHEMAS);
26
- });
27
-
28
- const uniqueQueue = () =>
29
- `test-${Date.now()}-${Math.random().toString(36).substring(7)}`;
30
-
31
- describe('PgBossConnection', () => {
32
- it('should connect and report connected status', async () => {
33
- const connection = new PgBossConnection({
34
- connectionString: POSTGRES_URL,
35
- schema: 'pgboss_conn_test',
36
- });
37
-
38
- expect(connection.isConnected()).toBe(false);
39
- expect(connection.instance).toBeUndefined();
40
-
41
- await connection.connect();
42
-
43
- expect(connection.isConnected()).toBe(true);
44
- expect(connection.instance).toBeDefined();
45
-
46
- await connection.close();
47
-
48
- expect(connection.isConnected()).toBe(false);
49
- });
50
-
51
- it('should not reconnect if already connected', async () => {
52
- const connection = new PgBossConnection({
53
- connectionString: POSTGRES_URL,
54
- schema: 'pgboss_conn_test2',
55
- });
56
-
57
- await connection.connect();
58
- const firstInstance = connection.instance;
59
-
60
- await connection.connect();
61
- expect(connection.instance).toBe(firstInstance);
62
-
63
- await connection.close();
64
- });
65
-
66
- it('should parse connection string correctly', async () => {
67
- const connection = await PgBossConnection.fromConnectionString(
68
- PGBOSS_CONNECTION_STRING,
69
- );
70
-
71
- expect(connection.isConnected()).toBe(true);
72
- expect(connection.instance).toBeDefined();
73
-
74
- await connection.close();
75
- });
76
- });
77
-
78
- describe('PgBossPublisher', () => {
79
- let connection: PgBossConnection;
80
-
81
- beforeAll(async () => {
82
- connection = new PgBossConnection({
83
- connectionString: POSTGRES_URL,
84
- schema: 'pgboss_pub_test',
85
- });
86
- await connection.connect();
87
- });
88
-
89
- afterAll(async () => {
90
- await connection.close();
91
- });
92
-
93
- it('should publish messages without errors', async () => {
94
- const publisher = new PgBossPublisher<TestMessage>(connection);
95
-
96
- await publisher.publish([
97
- { type: uniqueQueue() as any, payload: { userId: '1' } },
98
- ]);
99
- });
100
-
101
- it('should publish multiple messages with different types', async () => {
102
- const publisher = new PgBossPublisher<TestMessage>(connection);
103
- const queue1 = uniqueQueue() as any;
104
- const queue2 = uniqueQueue() as any;
105
-
106
- await publisher.publish([
107
- { type: queue1, payload: { userId: '1' } },
108
- { type: queue1, payload: { userId: '2' } },
109
- { type: queue2, payload: { userId: '3', name: 'Alice' } },
110
- ]);
111
- });
112
-
113
- it('should create publisher from connection string', async () => {
114
- const publisher = await PgBossPublisher.fromConnectionString<TestMessage>(
115
- PGBOSS_CONNECTION_STRING,
116
- );
117
-
118
- expect(publisher).toBeInstanceOf(PgBossPublisher);
119
- });
120
- });
121
-
122
- describe('PgBossSubscriber', () => {
123
- let connection: PgBossConnection;
124
-
125
- beforeAll(async () => {
126
- connection = new PgBossConnection({
127
- connectionString: POSTGRES_URL,
128
- schema: 'pgboss_sub_test',
129
- });
130
- await connection.connect();
131
- });
132
-
133
- afterAll(async () => {
134
- await connection.close();
135
- });
136
-
137
- it('should receive published messages', async () => {
138
- const queueName = uniqueQueue() as any;
139
- const publisher = new PgBossPublisher<TestMessage>(connection);
140
- const subscriber = new PgBossSubscriber<TestMessage>(connection, {
141
- pollingIntervalSeconds: 1,
142
- });
143
-
144
- const received: TestMessage[] = [];
145
-
146
- await subscriber.subscribe([queueName], async (message) => {
147
- received.push(message);
148
- });
149
-
150
- await publisher.publish([{ type: queueName, payload: { userId: '42' } }]);
151
-
152
- // Wait for pg-boss to poll and deliver
153
- await new Promise((resolve) => setTimeout(resolve, 3000));
154
-
155
- expect(received.length).toBe(1);
156
- expect(received[0]).toEqual({
157
- type: queueName,
158
- payload: { userId: '42' },
159
- });
160
- });
161
-
162
- it('should subscribe to multiple message types', async () => {
163
- const queue1 = uniqueQueue() as any;
164
- const queue2 = uniqueQueue() as any;
165
- const publisher = new PgBossPublisher<TestMessage>(connection);
166
- const subscriber = new PgBossSubscriber<TestMessage>(connection, {
167
- pollingIntervalSeconds: 1,
168
- });
169
-
170
- const received: TestMessage[] = [];
171
-
172
- await subscriber.subscribe([queue1, queue2], async (message) => {
173
- received.push(message);
174
- });
175
-
176
- await publisher.publish([
177
- { type: queue1, payload: { userId: '1' } },
178
- { type: queue2, payload: { userId: '2', name: 'Bob' } },
179
- ]);
180
-
181
- await new Promise((resolve) => setTimeout(resolve, 3000));
182
-
183
- expect(received.length).toBe(2);
184
- expect(received.map((m) => m.payload)).toEqual(
185
- expect.arrayContaining([{ userId: '1' }, { userId: '2', name: 'Bob' }]),
186
- );
187
- });
188
-
189
- it('should create subscriber from connection string with options', async () => {
190
- const subscriber = await PgBossSubscriber.fromConnectionString<TestMessage>(
191
- `${PGBOSS_CONNECTION_STRING}&batchSize=10`,
192
- );
193
-
194
- expect(subscriber).toBeInstanceOf(PgBossSubscriber);
195
- });
196
- });
@@ -1,21 +0,0 @@
1
- import { Client } from 'pg';
2
-
3
- /**
4
- * Drop the named schemas if they exist. Run before pg-boss tests so that
5
- * pg-boss's contractor performs a fresh `create` rather than attempting to
6
- * migrate from a stale layout left behind by an older pg-boss version.
7
- */
8
- export async function dropSchemas(
9
- connectionString: string,
10
- schemas: string[],
11
- ): Promise<void> {
12
- const client = new Client({ connectionString });
13
- await client.connect();
14
- try {
15
- for (const schema of schemas) {
16
- await client.query(`DROP SCHEMA IF EXISTS "${schema}" CASCADE`);
17
- }
18
- } finally {
19
- await client.end();
20
- }
21
- }
@@ -1,5 +0,0 @@
1
- export type { PgBossConnectionConfig } from './PgBossConnection';
2
- export { PgBossConnection } from './PgBossConnection';
3
- export { PgBossPublisher } from './PgBossPublisher';
4
- export type { PgBossSubscriberOptions } from './PgBossSubscriber';
5
- export { PgBossSubscriber } from './PgBossSubscriber';
@@ -1,148 +0,0 @@
1
- import amqplib from 'amqplib';
2
- import type { EventConnection } from '../types';
3
- import { EventPublisherType } from '../types';
4
-
5
- export interface RabbitMQConnectionConfig {
6
- url: string;
7
- exchange?: string;
8
- exchangeType?: 'topic' | 'direct' | 'fanout' | 'headers';
9
- exchangeOptions?: amqplib.Options.AssertExchange;
10
- timeout?: number; // Connection timeout in milliseconds (default: 5000)
11
- }
12
-
13
- export class RabbitMQConnection implements EventConnection {
14
- readonly type = EventPublisherType.RabbitMQ;
15
- private connection?: amqplib.ChannelModel;
16
- private channel?: amqplib.Channel;
17
- private connecting?: Promise<void>;
18
- private config: Required<
19
- Pick<RabbitMQConnectionConfig, 'exchange' | 'exchangeType' | 'timeout'>
20
- > &
21
- RabbitMQConnectionConfig;
22
-
23
- constructor(config: RabbitMQConnectionConfig) {
24
- this.config = {
25
- ...config,
26
- exchange: config.exchange || 'geekmidas.events',
27
- exchangeType: config.exchangeType || 'topic',
28
- timeout: config.timeout ?? 5000,
29
- exchangeOptions: {
30
- durable: true,
31
- ...config.exchangeOptions,
32
- },
33
- };
34
- }
35
-
36
- /**
37
- * Create a RabbitMQConnection from a connection string
38
- * Format: rabbitmq://user:pass@host:port/vhost?exchange=name&type=topic&timeout=5000
39
- */
40
- static async fromConnectionString(
41
- connectionString: string,
42
- ): Promise<RabbitMQConnection> {
43
- const url = new URL(connectionString);
44
- const params = url.searchParams;
45
-
46
- // Extract connection URL without query params
47
- const baseUrl = `amqp://${url.username ? `${url.username}:${url.password}@` : ''}${url.host}${url.pathname}`;
48
-
49
- const timeoutParam = params.get('timeout');
50
- const config: RabbitMQConnectionConfig = {
51
- url: baseUrl,
52
- exchange: params.get('exchange') || 'geekmidas.events',
53
- exchangeType: (params.get('type') as any) || 'topic',
54
- timeout: timeoutParam ? Number.parseInt(timeoutParam, 10) : undefined,
55
- };
56
-
57
- const connection = new RabbitMQConnection(config);
58
- await connection.connect();
59
- return connection;
60
- }
61
-
62
- async connect(): Promise<void> {
63
- if (this.channel) return;
64
-
65
- // Prevent multiple simultaneous connection attempts
66
- if (this.connecting) {
67
- await this.connecting;
68
- return;
69
- }
70
-
71
- this.connecting = (async () => {
72
- try {
73
- const connection = await amqplib.connect(this.config.url, {
74
- timeout: this.config.timeout,
75
- });
76
- const channel = await connection.createChannel();
77
-
78
- // Assert the exchange exists
79
- await channel.assertExchange(
80
- this.config.exchange!,
81
- this.config.exchangeType!,
82
- this.config.exchangeOptions,
83
- );
84
-
85
- // Handle connection errors
86
- connection.on('error', (_err: Error) => {
87
- this.cleanup();
88
- });
89
-
90
- connection.on('close', () => {
91
- this.cleanup();
92
- });
93
-
94
- // Only set after successful setup
95
- this.connection = connection;
96
- this.channel = channel;
97
- } catch (error) {
98
- this.cleanup();
99
- throw error;
100
- }
101
- })();
102
-
103
- await this.connecting;
104
- this.connecting = undefined;
105
- }
106
-
107
- async close(): Promise<void> {
108
- try {
109
- await this.channel?.close();
110
- await this.connection?.close();
111
- } catch (_error) {
112
- // Ignore errors during close
113
- } finally {
114
- this.cleanup();
115
- }
116
- }
117
-
118
- isConnected(): boolean {
119
- return !!this.channel;
120
- }
121
-
122
- private cleanup(): void {
123
- this.channel = undefined;
124
- this.connection = undefined;
125
- this.connecting = undefined;
126
- }
127
-
128
- /**
129
- * Get the underlying channel for publishing/subscribing
130
- */
131
- get amqpChannel(): amqplib.Channel | undefined {
132
- return this.channel;
133
- }
134
-
135
- /**
136
- * Get the exchange name for this connection
137
- */
138
- get exchangeName(): string {
139
- return this.config.exchange;
140
- }
141
-
142
- /**
143
- * Get the exchange type for this connection
144
- */
145
- get exchangeType(): string {
146
- return this.config.exchangeType;
147
- }
148
- }
@@ -1,67 +0,0 @@
1
- import type amqplib from 'amqplib';
2
- import type { EventPublisher, PublishableMessage } from '../types';
3
- import type { RabbitMQConnection } from './RabbitMQConnection';
4
-
5
- export interface RabbitMQPublisherOptions {
6
- publishOptions?: amqplib.Options.Publish;
7
- }
8
-
9
- export class RabbitMQPublisher<TMessage extends PublishableMessage<string, any>>
10
- implements EventPublisher<TMessage>
11
- {
12
- constructor(
13
- private connection: RabbitMQConnection,
14
- private options: RabbitMQPublisherOptions = {},
15
- ) {}
16
-
17
- /**
18
- * Create a RabbitMQPublisher from a connection string
19
- * Format: rabbitmq://user:pass@host:port/vhost?exchange=name&type=topic&timeout=5000
20
- */
21
- static async fromConnectionString<
22
- TMessage extends PublishableMessage<string, any>,
23
- >(connectionString: string): Promise<RabbitMQPublisher<TMessage>> {
24
- const { RabbitMQConnection } = await import('./RabbitMQConnection');
25
- const connection =
26
- await RabbitMQConnection.fromConnectionString(connectionString);
27
- return new RabbitMQPublisher<TMessage>(connection);
28
- }
29
-
30
- async publish(messages: TMessage[]): Promise<void> {
31
- if (!this.connection.isConnected()) {
32
- await this.connection.connect();
33
- }
34
-
35
- const channel = this.connection.amqpChannel;
36
- if (!channel) {
37
- throw new Error('Channel not initialized');
38
- }
39
-
40
- const exchange = this.connection.exchangeName;
41
-
42
- for (const message of messages) {
43
- const content = Buffer.from(JSON.stringify(message.payload));
44
-
45
- // Use message type as routing key for topic exchanges
46
- const routingKey = message.type;
47
-
48
- const published = channel.publish(exchange, routingKey, content, {
49
- contentType: 'application/json',
50
- timestamp: Date.now(),
51
- type: message.type,
52
- persistent: true,
53
- ...this.options.publishOptions,
54
- });
55
-
56
- // Handle backpressure
57
- if (!published) {
58
- await new Promise((resolve) => channel.once('drain', resolve));
59
- }
60
- }
61
- }
62
-
63
- async close(): Promise<void> {
64
- // Publisher doesn't own the connection
65
- // Connection should be closed by whoever created it
66
- }
67
- }
@@ -1,111 +0,0 @@
1
- import type amqplib from 'amqplib';
2
- import type { EventSubscriber, PublishableMessage } from '../types';
3
- import type { RabbitMQConnection } from './RabbitMQConnection';
4
-
5
- export interface RabbitMQSubscriberOptions {
6
- queueName?: string; // If not provided, a unique queue will be generated
7
- queueOptions?: amqplib.Options.AssertQueue;
8
- consumeOptions?: amqplib.Options.Consume;
9
- prefetch?: number; // Number of messages to prefetch (default: 1)
10
- }
11
-
12
- export class RabbitMQSubscriber<
13
- TMessage extends PublishableMessage<string, any>,
14
- > implements EventSubscriber<TMessage>
15
- {
16
- constructor(
17
- private connection: RabbitMQConnection,
18
- private options: RabbitMQSubscriberOptions = {},
19
- ) {}
20
-
21
- /**
22
- * Create a RabbitMQSubscriber from a connection string
23
- * Format: rabbitmq://user:pass@host:port/vhost?exchange=name&type=topic&queueName=myqueue&prefetch=10
24
- */
25
- static async fromConnectionString<
26
- TMessage extends PublishableMessage<string, any>,
27
- >(connectionString: string): Promise<RabbitMQSubscriber<TMessage>> {
28
- const url = new URL(connectionString);
29
- const params = url.searchParams;
30
-
31
- const { RabbitMQConnection } = await import('./RabbitMQConnection');
32
- const connection =
33
- await RabbitMQConnection.fromConnectionString(connectionString);
34
-
35
- const options: RabbitMQSubscriberOptions = {
36
- queueName: params.get('queueName') || undefined,
37
- prefetch: params.get('prefetch')
38
- ? Number.parseInt(params.get('prefetch')!, 10)
39
- : undefined,
40
- };
41
-
42
- return new RabbitMQSubscriber<TMessage>(connection, options);
43
- }
44
-
45
- async subscribe(
46
- messages: TMessage['type'][],
47
- listener: (payload: TMessage) => Promise<void>,
48
- ): Promise<void> {
49
- if (!this.connection.isConnected()) {
50
- await this.connection.connect();
51
- }
52
-
53
- const channel = this.connection.amqpChannel;
54
- if (!channel) {
55
- throw new Error('Channel not initialized');
56
- }
57
-
58
- const exchange = this.connection.exchangeName;
59
-
60
- // Set prefetch if specified
61
- if (this.options.prefetch) {
62
- await channel.prefetch(this.options.prefetch);
63
- }
64
-
65
- // Assert queue
66
- const queueName = this.options.queueName || '';
67
- const queueOptions: amqplib.Options.AssertQueue = {
68
- durable: true,
69
- ...this.options.queueOptions,
70
- };
71
-
72
- const { queue } = await channel.assertQueue(queueName, queueOptions);
73
-
74
- // Bind queue to exchange for each message type
75
- for (const messageType of messages) {
76
- await channel.bindQueue(queue, exchange, messageType);
77
- }
78
-
79
- // Consume messages
80
- await channel.consume(
81
- queue,
82
- async (msg) => {
83
- if (!msg) return;
84
-
85
- try {
86
- // Parse message payload
87
- const content = msg.content.toString();
88
- const payload = JSON.parse(content);
89
-
90
- // Get message type from properties
91
- const messageType = msg.properties.type;
92
-
93
- // Reconstruct full message
94
- const fullMessage: TMessage = {
95
- type: messageType,
96
- payload,
97
- } as TMessage;
98
-
99
- // Call listener
100
- await listener(fullMessage);
101
-
102
- // Ack message
103
- channel.ack(msg);
104
- } catch (_error) {
105
- channel.nack(msg, false, true);
106
- }
107
- },
108
- this.options.consumeOptions,
109
- );
110
- }
111
- }