@privateaim/server-kit 0.7.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 (154) hide show
  1. package/CHANGELOG.md +205 -0
  2. package/LICENSE +202 -0
  3. package/dist/core/aggregator/index.d.ts +2 -0
  4. package/dist/core/aggregator/index.d.ts.map +1 -0
  5. package/dist/core/aggregator/type.d.ts +4 -0
  6. package/dist/core/aggregator/type.d.ts.map +1 -0
  7. package/dist/core/component/error.d.ts +6 -0
  8. package/dist/core/component/error.d.ts.map +1 -0
  9. package/dist/core/component/helper.d.ts +3 -0
  10. package/dist/core/component/helper.d.ts.map +1 -0
  11. package/dist/core/component/index.d.ts +4 -0
  12. package/dist/core/component/index.d.ts.map +1 -0
  13. package/dist/core/component/type.d.ts +17 -0
  14. package/dist/core/component/type.d.ts.map +1 -0
  15. package/dist/core/index.d.ts +5 -0
  16. package/dist/core/index.d.ts.map +1 -0
  17. package/dist/core/queue/index.d.ts +3 -0
  18. package/dist/core/queue/index.d.ts.map +1 -0
  19. package/dist/core/queue/type.d.ts +12 -0
  20. package/dist/core/queue/type.d.ts.map +1 -0
  21. package/dist/core/queue/utils.d.ts +3 -0
  22. package/dist/core/queue/utils.d.ts.map +1 -0
  23. package/dist/core/queue-router/constants.d.ts +5 -0
  24. package/dist/core/queue-router/constants.d.ts.map +1 -0
  25. package/dist/core/queue-router/helpers.d.ts +4 -0
  26. package/dist/core/queue-router/helpers.d.ts.map +1 -0
  27. package/dist/core/queue-router/index.d.ts +6 -0
  28. package/dist/core/queue-router/index.d.ts.map +1 -0
  29. package/dist/core/queue-router/module.d.ts +9 -0
  30. package/dist/core/queue-router/module.d.ts.map +1 -0
  31. package/dist/core/queue-router/singleton.d.ts +4 -0
  32. package/dist/core/queue-router/singleton.d.ts.map +1 -0
  33. package/dist/core/queue-router/types.d.ts +31 -0
  34. package/dist/core/queue-router/types.d.ts.map +1 -0
  35. package/dist/domain-event/index.d.ts +5 -0
  36. package/dist/domain-event/index.d.ts.map +1 -0
  37. package/dist/domain-event/publish.d.ts +5 -0
  38. package/dist/domain-event/publish.d.ts.map +1 -0
  39. package/dist/domain-event/redis/index.d.ts +2 -0
  40. package/dist/domain-event/redis/index.d.ts.map +1 -0
  41. package/dist/domain-event/redis/publish.d.ts +5 -0
  42. package/dist/domain-event/redis/publish.d.ts.map +1 -0
  43. package/dist/domain-event/socket/index.d.ts +2 -0
  44. package/dist/domain-event/socket/index.d.ts.map +1 -0
  45. package/dist/domain-event/socket/publish.d.ts +5 -0
  46. package/dist/domain-event/socket/publish.d.ts.map +1 -0
  47. package/dist/domain-event/type.d.ts +7 -0
  48. package/dist/domain-event/type.d.ts.map +1 -0
  49. package/dist/domain-event/utils.d.ts +4 -0
  50. package/dist/domain-event/utils.d.ts.map +1 -0
  51. package/dist/index.cjs +492 -0
  52. package/dist/index.cjs.map +1 -0
  53. package/dist/index.d.ts +6 -0
  54. package/dist/index.d.ts.map +1 -0
  55. package/dist/index.mjs +422 -0
  56. package/dist/index.mjs.map +1 -0
  57. package/dist/services/amqp/index.d.ts +2 -0
  58. package/dist/services/amqp/index.d.ts.map +1 -0
  59. package/dist/services/amqp/module.d.ts +6 -0
  60. package/dist/services/amqp/module.d.ts.map +1 -0
  61. package/dist/services/authup/helpers.d.ts +3 -0
  62. package/dist/services/authup/helpers.d.ts.map +1 -0
  63. package/dist/services/authup/index.d.ts +4 -0
  64. package/dist/services/authup/index.d.ts.map +1 -0
  65. package/dist/services/authup/module.d.ts +7 -0
  66. package/dist/services/authup/module.d.ts.map +1 -0
  67. package/dist/services/authup/singleton.d.ts +6 -0
  68. package/dist/services/authup/singleton.d.ts.map +1 -0
  69. package/dist/services/index.d.ts +6 -0
  70. package/dist/services/index.d.ts.map +1 -0
  71. package/dist/services/logger/index.d.ts +4 -0
  72. package/dist/services/logger/index.d.ts.map +1 -0
  73. package/dist/services/logger/module.d.ts +4 -0
  74. package/dist/services/logger/module.d.ts.map +1 -0
  75. package/dist/services/logger/singleton.d.ts +7 -0
  76. package/dist/services/logger/singleton.d.ts.map +1 -0
  77. package/dist/services/logger/types.d.ts +8 -0
  78. package/dist/services/logger/types.d.ts.map +1 -0
  79. package/dist/services/redis/helpers.d.ts +3 -0
  80. package/dist/services/redis/helpers.d.ts.map +1 -0
  81. package/dist/services/redis/index.d.ts +6 -0
  82. package/dist/services/redis/index.d.ts.map +1 -0
  83. package/dist/services/redis/module.d.ts +3 -0
  84. package/dist/services/redis/module.d.ts.map +1 -0
  85. package/dist/services/redis/singleton-publish.d.ts +3 -0
  86. package/dist/services/redis/singleton-publish.d.ts.map +1 -0
  87. package/dist/services/redis/singleton-subscribe.d.ts +3 -0
  88. package/dist/services/redis/singleton-subscribe.d.ts.map +1 -0
  89. package/dist/services/redis/singleton.d.ts +7 -0
  90. package/dist/services/redis/singleton.d.ts.map +1 -0
  91. package/dist/services/vault/index.d.ts +3 -0
  92. package/dist/services/vault/index.d.ts.map +1 -0
  93. package/dist/services/vault/module.d.ts +3 -0
  94. package/dist/services/vault/module.d.ts.map +1 -0
  95. package/dist/services/vault/singleton.d.ts +6 -0
  96. package/dist/services/vault/singleton.d.ts.map +1 -0
  97. package/dist/type.d.ts +2 -0
  98. package/dist/type.d.ts.map +1 -0
  99. package/dist/utils/has-property.d.ts +2 -0
  100. package/dist/utils/has-property.d.ts.map +1 -0
  101. package/dist/utils/index.d.ts +2 -0
  102. package/dist/utils/index.d.ts.map +1 -0
  103. package/package.json +54 -0
  104. package/rollup.config.mjs +14 -0
  105. package/src/core/aggregator/index.ts +8 -0
  106. package/src/core/aggregator/type.ts +10 -0
  107. package/src/core/component/error.ts +18 -0
  108. package/src/core/component/helper.ts +28 -0
  109. package/src/core/component/index.ts +10 -0
  110. package/src/core/component/type.ts +32 -0
  111. package/src/core/index.ts +11 -0
  112. package/src/core/queue/index.ts +9 -0
  113. package/src/core/queue/type.ts +23 -0
  114. package/src/core/queue/utils.ts +17 -0
  115. package/src/core/queue-router/constants.ts +11 -0
  116. package/src/core/queue-router/helpers.ts +33 -0
  117. package/src/core/queue-router/index.ts +12 -0
  118. package/src/core/queue-router/module.ts +111 -0
  119. package/src/core/queue-router/singleton.ts +27 -0
  120. package/src/core/queue-router/types.ts +58 -0
  121. package/src/domain-event/index.ts +11 -0
  122. package/src/domain-event/publish.ts +21 -0
  123. package/src/domain-event/redis/index.ts +8 -0
  124. package/src/domain-event/redis/publish.ts +41 -0
  125. package/src/domain-event/socket/index.ts +8 -0
  126. package/src/domain-event/socket/publish.ts +57 -0
  127. package/src/domain-event/type.ts +14 -0
  128. package/src/domain-event/utils.ts +34 -0
  129. package/src/index.ts +12 -0
  130. package/src/services/amqp/index.ts +8 -0
  131. package/src/services/amqp/module.ts +26 -0
  132. package/src/services/authup/helpers.ts +28 -0
  133. package/src/services/authup/index.ts +10 -0
  134. package/src/services/authup/module.ts +28 -0
  135. package/src/services/authup/singleton.ts +26 -0
  136. package/src/services/index.ts +12 -0
  137. package/src/services/logger/index.ts +10 -0
  138. package/src/services/logger/module.ts +56 -0
  139. package/src/services/logger/singleton.ts +29 -0
  140. package/src/services/logger/types.ts +19 -0
  141. package/src/services/redis/helpers.ts +12 -0
  142. package/src/services/redis/index.ts +12 -0
  143. package/src/services/redis/module.ts +22 -0
  144. package/src/services/redis/singleton-publish.ts +19 -0
  145. package/src/services/redis/singleton-subscribe.ts +19 -0
  146. package/src/services/redis/singleton.ts +30 -0
  147. package/src/services/vault/index.ts +9 -0
  148. package/src/services/vault/module.ts +13 -0
  149. package/src/services/vault/singleton.ts +26 -0
  150. package/src/type.ts +8 -0
  151. package/src/utils/has-property.ts +13 -0
  152. package/src/utils/index.ts +8 -0
  153. package/tsconfig.build.json +11 -0
  154. package/tsconfig.json +9 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,205 @@
1
+ # Changelog
2
+
3
+ ## [0.7.0](https://github.com/PrivateAIM/hub/compare/v0.6.0...v0.7.0) (2024-06-26)
4
+
5
+
6
+ ### Features
7
+
8
+ * adjusted code references for core -> core-kit package renaming ([321b8ac](https://github.com/PrivateAIM/hub/commit/321b8acb33e4fdd93252c72da34fac34cc86cd9f))
9
+ * analysis-bucket implementation ([#433](https://github.com/PrivateAIM/hub/issues/433)) ([15329f4](https://github.com/PrivateAIM/hub/commit/15329f42c5f6ebbe4772715ff2e308e41ae9e91a))
10
+ * analysis-manager-kit package implementation ([#393](https://github.com/PrivateAIM/hub/issues/393)) ([d9faf4a](https://github.com/PrivateAIM/hub/commit/d9faf4a4580634a62ed58ec994369be1369e33ee))
11
+ * bump authup to v1.0.0-beta.5 ([13aeab2](https://github.com/PrivateAIM/hub/commit/13aeab2eb8a00069512eee17fc129d56a58309bc))
12
+ * cleanup component error handling ([e8869ef](https://github.com/PrivateAIM/hub/commit/e8869efddf658f695fb4c0e6cf8b9596306c123a))
13
+ * events for receiving user/robot connection count ([25e60d7](https://github.com/PrivateAIM/hub/commit/25e60d77ab0b3a6b4d598363b6563563e1dab7e6))
14
+ * extract utils and common consts, fns, ... to kit package ([258bbb2](https://github.com/PrivateAIM/hub/commit/258bbb21bfbf671a7cfad3e91740a1737eaf3f71))
15
+ * initial implementation & usage refactoring ([#426](https://github.com/PrivateAIM/hub/issues/426)) ([85ff83f](https://github.com/PrivateAIM/hub/commit/85ff83f40dc129f7f1e28b41f445f60bb6d6fcfe))
16
+ * integrated authup middleware in server-kit package ([#259](https://github.com/PrivateAIM/hub/issues/259)) ([a4b6871](https://github.com/PrivateAIM/hub/commit/a4b6871ffa7f43f49cceac3044b41bf622aa75d3))
17
+ * migrated to authup version v1.0.0-beta.18 ([06928f6](https://github.com/PrivateAIM/hub/commit/06928f681120b423f962a7869f8f6b12708d3047))
18
+ * move http request validation logic to kit package ([#104](https://github.com/PrivateAIM/hub/issues/104)) ([5c26e44](https://github.com/PrivateAIM/hub/commit/5c26e44fdd1df48c5c35756495df08423481770d))
19
+ * move redis singleton management to kit package ([285b073](https://github.com/PrivateAIM/hub/commit/285b073eede72ea342f1f4e75e5f00593c51fafd))
20
+ * move service factories/singletons to server-kit-package ([#387](https://github.com/PrivateAIM/hub/issues/387)) ([669d352](https://github.com/PrivateAIM/hub/commit/669d3526893c8bc2d2dd8fe78f423783c5d7e317))
21
+ * namespace separation + socket connection management (ink. subscription etc.) ([1dcb083](https://github.com/PrivateAIM/hub/commit/1dcb083962ace1b021b20855c45304e1be40c051))
22
+ * queue-router for components & aggregators ([#396](https://github.com/PrivateAIM/hub/issues/396)) ([0da6066](https://github.com/PrivateAIM/hub/commit/0da6066e378cc97ee8d7b98558e5281dda66cbc9))
23
+ * server-http-kit package with validation, authup & request utils/helpers ([#375](https://github.com/PrivateAIM/hub/issues/375)) ([7762a2f](https://github.com/PrivateAIM/hub/commit/7762a2f81ea8dfcd77fc8c7f8d64bb91ad2bcd4f))
24
+ * simplified authentication & authorization management ([0b19929](https://github.com/PrivateAIM/hub/commit/0b199297766780a4c5cfcd8eda02cefb9f226958))
25
+ * simplified logger usage across packages ([39ea90f](https://github.com/PrivateAIM/hub/commit/39ea90ffa6296f91ffb0f89a567036b0054f0135))
26
+ * updated authup, vuecs & ilingo ([66a5f7b](https://github.com/PrivateAIM/hub/commit/66a5f7ba1454fc5e432cd687a509ebf3bf4c4ab4))
27
+ * use envix for environment variable interaction ([cceb6f4](https://github.com/PrivateAIM/hub/commit/cceb6f4842b937ee02bbd1ba3dcaadb0e3b52131))
28
+
29
+
30
+ ### Bug Fixes
31
+
32
+ * consuming and publishing with queue-router ([1a461e7](https://github.com/PrivateAIM/hub/commit/1a461e7ce539cf19f5866783f3a58319318de137))
33
+ * **deps:** bump @authup/core from 1.0.0-beta.3 to 1.0.0-beta.4 ([#92](https://github.com/PrivateAIM/hub/issues/92)) ([b950c83](https://github.com/PrivateAIM/hub/commit/b950c838b0de3e647452145182f906472af2fd12))
34
+ * **deps:** bump @authup/core from 1.0.0-beta.5 to 1.0.0-beta.7 ([#155](https://github.com/PrivateAIM/hub/issues/155)) ([e0da3b4](https://github.com/PrivateAIM/hub/commit/e0da3b4ccabc30e8871cd01f373f3437a0f1928a))
35
+ * **deps:** bump @authup/core from 1.0.0-beta.7 to 1.0.0-beta.8 ([#210](https://github.com/PrivateAIM/hub/issues/210)) ([6e8adf2](https://github.com/PrivateAIM/hub/commit/6e8adf2c80dba69eb66a76250e1fc1acc1bb71dd))
36
+ * **deps:** bump @authup/core from 1.0.0-beta.8 to 1.0.0-beta.9 ([#277](https://github.com/PrivateAIM/hub/issues/277)) ([f9a8f59](https://github.com/PrivateAIM/hub/commit/f9a8f59a60990f8ffe6da044c18150a56f2e196c))
37
+ * **deps:** bump @authup/server-adapter from 1.0.0-beta.8 to 1.0.0-beta.9 ([#274](https://github.com/PrivateAIM/hub/issues/274)) ([ce80e33](https://github.com/PrivateAIM/hub/commit/ce80e331524a0d50632e99909587028c6d18b88a))
38
+ * **deps:** bump amqp-extension from 4.0.0-beta.1 to 4.0.0-beta.2 ([#450](https://github.com/PrivateAIM/hub/issues/450)) ([b65538a](https://github.com/PrivateAIM/hub/commit/b65538ac7e6a0b28ad87b966a01425c8bd86ea3d))
39
+ * **deps:** bump amqp-extension from 4.0.0-beta.2 to 4.0.0-beta.3 ([#457](https://github.com/PrivateAIM/hub/issues/457)) ([2585ea2](https://github.com/PrivateAIM/hub/commit/2585ea2b22b969c21e82b3b92b2e795198dd5f44))
40
+ * **deps:** bump redis-extension from 1.3.0 to 1.5.0 ([#293](https://github.com/PrivateAIM/hub/issues/293)) ([0f98e66](https://github.com/PrivateAIM/hub/commit/0f98e66e56df460d40edf640cff15c1094a3fa04))
41
+ * **deps:** bump typeorm-extension from 3.5.0 to 3.5.1 ([#271](https://github.com/PrivateAIM/hub/issues/271)) ([f4be3b9](https://github.com/PrivateAIM/hub/commit/f4be3b90b316e530306d16d8aee79a22c2955f7c))
42
+ * imports of ability manager ([d46fd8b](https://github.com/PrivateAIM/hub/commit/d46fd8b04d2b30224322aaaba391dbc075ac3089))
43
+ * minor issues in client components & applied linting rules ([b88e168](https://github.com/PrivateAIM/hub/commit/b88e168e0bf3f93e01887f91e9fdff7fe621aafd))
44
+ * pass redis client for publishing domain events ([5fb7417](https://github.com/PrivateAIM/hub/commit/5fb7417071e5864d460069de96d91a78424ebaa1))
45
+ * setting type on queue message publish + logging on publish/consume ([5430305](https://github.com/PrivateAIM/hub/commit/54303053ec0596217db0cce3c98871b7779fa65c))
46
+
47
+
48
+ ### Dependencies
49
+
50
+ * The following workspace dependencies were updated
51
+ * dependencies
52
+ * @privateaim/core-kit bumped from ^0.6.0 to ^0.7.0
53
+ * @privateaim/kit bumped from ^0.6.0 to ^0.7.0
54
+
55
+ ## [0.6.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.5.0...server-kit-v0.6.0) (2024-06-25)
56
+
57
+
58
+ ### Features
59
+
60
+ * adjusted code references for core -> core-kit package renaming ([321b8ac](https://github.com/PrivateAIM/hub/commit/321b8acb33e4fdd93252c72da34fac34cc86cd9f))
61
+ * migrated to authup version v1.0.0-beta.18 ([06928f6](https://github.com/PrivateAIM/hub/commit/06928f681120b423f962a7869f8f6b12708d3047))
62
+
63
+
64
+ ### Bug Fixes
65
+
66
+ * **deps:** bump amqp-extension from 4.0.0-beta.2 to 4.0.0-beta.3 ([#457](https://github.com/PrivateAIM/hub/issues/457)) ([2585ea2](https://github.com/PrivateAIM/hub/commit/2585ea2b22b969c21e82b3b92b2e795198dd5f44))
67
+
68
+
69
+ ### Dependencies
70
+
71
+ * The following workspace dependencies were updated
72
+ * dependencies
73
+ * @privateaim/core-kit bumped from ^0.5.0 to ^0.6.0
74
+ * @privateaim/kit bumped from ^0.5.0 to ^0.6.0
75
+
76
+ ## [0.5.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.4.0...server-kit-v0.5.0) (2024-06-12)
77
+
78
+
79
+ ### Features
80
+
81
+ * analysis-bucket implementation ([#433](https://github.com/PrivateAIM/hub/issues/433)) ([15329f4](https://github.com/PrivateAIM/hub/commit/15329f42c5f6ebbe4772715ff2e308e41ae9e91a))
82
+ * analysis-manager-kit package implementation ([#393](https://github.com/PrivateAIM/hub/issues/393)) ([d9faf4a](https://github.com/PrivateAIM/hub/commit/d9faf4a4580634a62ed58ec994369be1369e33ee))
83
+ * cleanup component error handling ([e8869ef](https://github.com/PrivateAIM/hub/commit/e8869efddf658f695fb4c0e6cf8b9596306c123a))
84
+ * extract utils and common consts, fns, ... to kit package ([258bbb2](https://github.com/PrivateAIM/hub/commit/258bbb21bfbf671a7cfad3e91740a1737eaf3f71))
85
+ * initial implementation & usage refactoring ([#426](https://github.com/PrivateAIM/hub/issues/426)) ([85ff83f](https://github.com/PrivateAIM/hub/commit/85ff83f40dc129f7f1e28b41f445f60bb6d6fcfe))
86
+ * move redis singleton management to kit package ([285b073](https://github.com/PrivateAIM/hub/commit/285b073eede72ea342f1f4e75e5f00593c51fafd))
87
+ * move service factories/singletons to server-kit-package ([#387](https://github.com/PrivateAIM/hub/issues/387)) ([669d352](https://github.com/PrivateAIM/hub/commit/669d3526893c8bc2d2dd8fe78f423783c5d7e317))
88
+ * queue-router for components & aggregators ([#396](https://github.com/PrivateAIM/hub/issues/396)) ([0da6066](https://github.com/PrivateAIM/hub/commit/0da6066e378cc97ee8d7b98558e5281dda66cbc9))
89
+ * server-http-kit package with validation, authup & request utils/helpers ([#375](https://github.com/PrivateAIM/hub/issues/375)) ([7762a2f](https://github.com/PrivateAIM/hub/commit/7762a2f81ea8dfcd77fc8c7f8d64bb91ad2bcd4f))
90
+
91
+
92
+ ### Bug Fixes
93
+
94
+ * consuming and publishing with queue-router ([1a461e7](https://github.com/PrivateAIM/hub/commit/1a461e7ce539cf19f5866783f3a58319318de137))
95
+ * **deps:** bump amqp-extension from 4.0.0-beta.1 to 4.0.0-beta.2 ([#450](https://github.com/PrivateAIM/hub/issues/450)) ([b65538a](https://github.com/PrivateAIM/hub/commit/b65538ac7e6a0b28ad87b966a01425c8bd86ea3d))
96
+ * setting type on queue message publish + logging on publish/consume ([5430305](https://github.com/PrivateAIM/hub/commit/54303053ec0596217db0cce3c98871b7779fa65c))
97
+
98
+
99
+ ### Dependencies
100
+
101
+ * The following workspace dependencies were updated
102
+ * dependencies
103
+ * @privateaim/core bumped from ^0.4.0 to ^0.5.0
104
+ * @privateaim/kit bumped from ^0.4.0 to ^0.5.0
105
+
106
+ ## [0.4.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.4.0...server-kit-v0.4.0) (2024-06-12)
107
+
108
+
109
+ ### Features
110
+
111
+ * analysis-bucket implementation ([#433](https://github.com/PrivateAIM/hub/issues/433)) ([15329f4](https://github.com/PrivateAIM/hub/commit/15329f42c5f6ebbe4772715ff2e308e41ae9e91a))
112
+ * analysis-manager-kit package implementation ([#393](https://github.com/PrivateAIM/hub/issues/393)) ([d9faf4a](https://github.com/PrivateAIM/hub/commit/d9faf4a4580634a62ed58ec994369be1369e33ee))
113
+ * cleanup component error handling ([e8869ef](https://github.com/PrivateAIM/hub/commit/e8869efddf658f695fb4c0e6cf8b9596306c123a))
114
+ * extract utils and common consts, fns, ... to kit package ([258bbb2](https://github.com/PrivateAIM/hub/commit/258bbb21bfbf671a7cfad3e91740a1737eaf3f71))
115
+ * initial implementation & usage refactoring ([#426](https://github.com/PrivateAIM/hub/issues/426)) ([85ff83f](https://github.com/PrivateAIM/hub/commit/85ff83f40dc129f7f1e28b41f445f60bb6d6fcfe))
116
+ * move redis singleton management to kit package ([285b073](https://github.com/PrivateAIM/hub/commit/285b073eede72ea342f1f4e75e5f00593c51fafd))
117
+ * move service factories/singletons to server-kit-package ([#387](https://github.com/PrivateAIM/hub/issues/387)) ([669d352](https://github.com/PrivateAIM/hub/commit/669d3526893c8bc2d2dd8fe78f423783c5d7e317))
118
+ * queue-router for components & aggregators ([#396](https://github.com/PrivateAIM/hub/issues/396)) ([0da6066](https://github.com/PrivateAIM/hub/commit/0da6066e378cc97ee8d7b98558e5281dda66cbc9))
119
+ * server-http-kit package with validation, authup & request utils/helpers ([#375](https://github.com/PrivateAIM/hub/issues/375)) ([7762a2f](https://github.com/PrivateAIM/hub/commit/7762a2f81ea8dfcd77fc8c7f8d64bb91ad2bcd4f))
120
+
121
+
122
+ ### Bug Fixes
123
+
124
+ * consuming and publishing with queue-router ([1a461e7](https://github.com/PrivateAIM/hub/commit/1a461e7ce539cf19f5866783f3a58319318de137))
125
+ * **deps:** bump amqp-extension from 4.0.0-beta.1 to 4.0.0-beta.2 ([#450](https://github.com/PrivateAIM/hub/issues/450)) ([b65538a](https://github.com/PrivateAIM/hub/commit/b65538ac7e6a0b28ad87b966a01425c8bd86ea3d))
126
+ * setting type on queue message publish + logging on publish/consume ([5430305](https://github.com/PrivateAIM/hub/commit/54303053ec0596217db0cce3c98871b7779fa65c))
127
+
128
+ ## [0.4.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.3.0...server-kit-v0.4.0) (2024-05-15)
129
+
130
+
131
+ ### Features
132
+
133
+ * integrated authup middleware in server-kit package ([#259](https://github.com/PrivateAIM/hub/issues/259)) ([a4b6871](https://github.com/PrivateAIM/hub/commit/a4b6871ffa7f43f49cceac3044b41bf622aa75d3))
134
+ * simplified authentication & authorization management ([0b19929](https://github.com/PrivateAIM/hub/commit/0b199297766780a4c5cfcd8eda02cefb9f226958))
135
+ * simplified logger usage across packages ([39ea90f](https://github.com/PrivateAIM/hub/commit/39ea90ffa6296f91ffb0f89a567036b0054f0135))
136
+ * updated authup, vuecs & ilingo ([66a5f7b](https://github.com/PrivateAIM/hub/commit/66a5f7ba1454fc5e432cd687a509ebf3bf4c4ab4))
137
+
138
+
139
+ ### Bug Fixes
140
+
141
+ * **deps:** bump @authup/core from 1.0.0-beta.7 to 1.0.0-beta.8 ([#210](https://github.com/PrivateAIM/hub/issues/210)) ([6e8adf2](https://github.com/PrivateAIM/hub/commit/6e8adf2c80dba69eb66a76250e1fc1acc1bb71dd))
142
+ * **deps:** bump @authup/core from 1.0.0-beta.8 to 1.0.0-beta.9 ([#277](https://github.com/PrivateAIM/hub/issues/277)) ([f9a8f59](https://github.com/PrivateAIM/hub/commit/f9a8f59a60990f8ffe6da044c18150a56f2e196c))
143
+ * **deps:** bump @authup/server-adapter from 1.0.0-beta.8 to 1.0.0-beta.9 ([#274](https://github.com/PrivateAIM/hub/issues/274)) ([ce80e33](https://github.com/PrivateAIM/hub/commit/ce80e331524a0d50632e99909587028c6d18b88a))
144
+ * **deps:** bump redis-extension from 1.3.0 to 1.5.0 ([#293](https://github.com/PrivateAIM/hub/issues/293)) ([0f98e66](https://github.com/PrivateAIM/hub/commit/0f98e66e56df460d40edf640cff15c1094a3fa04))
145
+ * **deps:** bump typeorm-extension from 3.5.0 to 3.5.1 ([#271](https://github.com/PrivateAIM/hub/issues/271)) ([f4be3b9](https://github.com/PrivateAIM/hub/commit/f4be3b90b316e530306d16d8aee79a22c2955f7c))
146
+ * imports of ability manager ([d46fd8b](https://github.com/PrivateAIM/hub/commit/d46fd8b04d2b30224322aaaba391dbc075ac3089))
147
+ * minor issues in client components & applied linting rules ([b88e168](https://github.com/PrivateAIM/hub/commit/b88e168e0bf3f93e01887f91e9fdff7fe621aafd))
148
+
149
+
150
+ ### Dependencies
151
+
152
+ * The following workspace dependencies were updated
153
+ * dependencies
154
+ * @privateaim/core bumped from ^0.3.0 to ^0.4.0
155
+
156
+ ## [0.3.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.2.0...server-kit-v0.3.0) (2024-03-11)
157
+
158
+
159
+ ### Bug Fixes
160
+
161
+ * **deps:** bump @authup/core from 1.0.0-beta.5 to 1.0.0-beta.7 ([#155](https://github.com/PrivateAIM/hub/issues/155)) ([e0da3b4](https://github.com/PrivateAIM/hub/commit/e0da3b4ccabc30e8871cd01f373f3437a0f1928a))
162
+
163
+
164
+ ### Dependencies
165
+
166
+ * The following workspace dependencies were updated
167
+ * dependencies
168
+ * @privateaim/core bumped from ^0.2.0 to ^0.3.0
169
+
170
+ ## [0.2.0](https://github.com/PrivateAIM/hub/compare/server-kit-v0.1.0...server-kit-v0.2.0) (2024-02-28)
171
+
172
+
173
+ ### Features
174
+
175
+ * bump authup to v1.0.0-beta.5 ([13aeab2](https://github.com/PrivateAIM/hub/commit/13aeab2eb8a00069512eee17fc129d56a58309bc))
176
+ * move http request validation logic to kit package ([#104](https://github.com/PrivateAIM/hub/issues/104)) ([5c26e44](https://github.com/PrivateAIM/hub/commit/5c26e44fdd1df48c5c35756495df08423481770d))
177
+
178
+
179
+ ### Dependencies
180
+
181
+ * The following workspace dependencies were updated
182
+ * dependencies
183
+ * @privateaim/core bumped from ^0.1.0 to ^0.2.0
184
+
185
+ ## 0.1.0 (2024-02-19)
186
+
187
+
188
+ ### Features
189
+
190
+ * events for receiving user/robot connection count ([25e60d7](https://github.com/PrivateAIM/hub/commit/25e60d77ab0b3a6b4d598363b6563563e1dab7e6))
191
+ * namespace separation + socket connection management (ink. subscription etc.) ([1dcb083](https://github.com/PrivateAIM/hub/commit/1dcb083962ace1b021b20855c45304e1be40c051))
192
+ * use envix for environment variable interaction ([cceb6f4](https://github.com/PrivateAIM/hub/commit/cceb6f4842b937ee02bbd1ba3dcaadb0e3b52131))
193
+
194
+
195
+ ### Bug Fixes
196
+
197
+ * **deps:** bump @authup/core from 1.0.0-beta.3 to 1.0.0-beta.4 ([#92](https://github.com/PrivateAIM/hub/issues/92)) ([b950c83](https://github.com/PrivateAIM/hub/commit/b950c838b0de3e647452145182f906472af2fd12))
198
+ * pass redis client for publishing domain events ([5fb7417](https://github.com/PrivateAIM/hub/commit/5fb7417071e5864d460069de96d91a78424ebaa1))
199
+
200
+
201
+ ### Dependencies
202
+
203
+ * The following workspace dependencies were updated
204
+ * dependencies
205
+ * @privateaim/core bumped from ^0.0.0 to ^0.1.0
package/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2024 PrivateAIM
190
+ Copyright 2020 - 2023 Peter Placzek
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,2 @@
1
+ export * from './type';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/aggregator/index.ts"],"names":[],"mappings":"AAOA,cAAc,QAAQ,CAAC"}
@@ -0,0 +1,4 @@
1
+ export type Aggregator = {
2
+ start: () => void;
3
+ };
4
+ //# sourceMappingURL=type.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../src/core/aggregator/type.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,UAAU,GAAG;IACrB,KAAK,EAAE,MAAM,IAAI,CAAA;CACpB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import type { ComponentErrorOptions } from './type';
2
+ export declare class ComponentError extends Error {
3
+ code?: string | null;
4
+ constructor(input: ComponentErrorOptions);
5
+ }
6
+ //# sourceMappingURL=error.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../../src/core/component/error.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,qBAAa,cAAe,SAAQ,KAAK;IAC9B,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;gBAEhB,KAAK,EAAE,qBAAqB;CAK3C"}
@@ -0,0 +1,3 @@
1
+ import type { ComponentError } from './error';
2
+ export declare function isComponentError(input: unknown): input is ComponentError;
3
+ //# sourceMappingURL=helper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["../../../src/core/component/helper.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAI,KAAK,IAAI,cAAc,CAiBzE"}
@@ -0,0 +1,4 @@
1
+ export * from './error';
2
+ export * from './helper';
3
+ export * from './type';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/component/index.ts"],"names":[],"mappings":"AAOA,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC"}
@@ -0,0 +1,17 @@
1
+ import type { ObjectLiteral } from '../../type';
2
+ import type { ComponentError } from './error';
3
+ export type Component = {
4
+ start: () => void;
5
+ };
6
+ export type ComponentErrorOptions = {
7
+ code?: string | null;
8
+ message?: string;
9
+ cause?: unknown;
10
+ };
11
+ export type ComponentContextWithError<T extends ObjectLiteral = ObjectLiteral> = T & {
12
+ error: ComponentError | Error;
13
+ };
14
+ export type ComponentContextWithCommand<T extends ObjectLiteral = ObjectLiteral, C extends string = string> = Omit<T, 'command'> & {
15
+ command: C;
16
+ };
17
+ //# sourceMappingURL=type.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../src/core/component/type.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,MAAM,MAAM,SAAS,GAAG;IACpB,KAAK,EAAE,MAAM,IAAI,CAAA;CACpB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAChC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,OAAO,CAAA;CAClB,CAAC;AAEF,MAAM,MAAM,yBAAyB,CACjC,CAAC,SAAS,aAAa,GAAG,aAAa,IACvC,CAAC,GAAG;IACJ,KAAK,EAAE,cAAc,GAAG,KAAK,CAAA;CAChC,CAAC;AAEF,MAAM,MAAM,2BAA2B,CACnC,CAAC,SAAS,aAAa,GAAG,aAAa,EACvC,CAAC,SAAS,MAAM,GAAG,MAAM,IACzB,IAAI,CAAC,CAAC,EAAE,SAAS,CAAC,GAAG;IACrB,OAAO,EAAE,CAAC,CAAA;CACb,CAAC"}
@@ -0,0 +1,5 @@
1
+ export * from './aggregator';
2
+ export * from './component';
3
+ export * from './queue';
4
+ export * from './queue-router';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAOA,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './type';
2
+ export * from './utils';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/queue/index.ts"],"names":[],"mappings":"AAOA,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC"}
@@ -0,0 +1,12 @@
1
+ import type { ObjectLiteral } from '../../type';
2
+ export type QueuePayloadError = {
3
+ code: string;
4
+ message: string;
5
+ step?: string | number;
6
+ };
7
+ export type QueuePayload<T extends ObjectLiteral = ObjectLiteral, M extends ObjectLiteral = ObjectLiteral> = {
8
+ data: T;
9
+ metadata: M;
10
+ error?: QueuePayloadError;
11
+ };
12
+ //# sourceMappingURL=type.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../src/core/queue/type.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAEhD,MAAM,MAAM,iBAAiB,GAAG;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;CAC1B,CAAC;AAEF,MAAM,MAAM,YAAY,CACpB,CAAC,SAAS,aAAa,GAAG,aAAa,EACvC,CAAC,SAAS,aAAa,GAAG,aAAa,IACvC;IACA,IAAI,EAAE,CAAC,CAAC;IACR,QAAQ,EAAE,CAAC,CAAC;IACZ,KAAK,CAAC,EAAE,iBAAiB,CAAA;CAC5B,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { QueuePayload } from './type';
2
+ export declare function isQueuePayload(input: unknown): input is QueuePayload;
3
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/core/queue/utils.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AAE3C,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAI,KAAK,IAAI,YAAY,CAMrE"}
@@ -0,0 +1,5 @@
1
+ export declare enum QueueRouterRoutingType {
2
+ WORK = "work",
3
+ PUB_SUB = "pubSub"
4
+ }
5
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/constants.ts"],"names":[],"mappings":"AAOA,oBAAY,sBAAsB;IAC9B,IAAI,SAAS;IACb,OAAO,WAAW;CACrB"}
@@ -0,0 +1,4 @@
1
+ import type { QueueRouterPayload, QueueRouterPayloadInput } from './types';
2
+ export declare function buildQueueRouterPublishPayload(input: QueueRouterPayloadInput): QueueRouterPayload;
3
+ export declare function isQueueRouterPayload(input: unknown): input is QueueRouterPayload;
4
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/helpers.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,kBAAkB,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAE3E,wBAAgB,8BAA8B,CAC1C,KAAK,EAAE,uBAAuB,GAC9B,kBAAkB,CAUrB;AAED,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,GAAI,KAAK,IAAI,kBAAkB,CAQjF"}
@@ -0,0 +1,6 @@
1
+ export * from './constants';
2
+ export * from './helpers';
3
+ export * from './module';
4
+ export * from './singleton';
5
+ export * from './types';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/index.ts"],"names":[],"mappings":"AAOA,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC"}
@@ -0,0 +1,9 @@
1
+ import type { Client } from 'amqp-extension';
2
+ import type { QueueRouterHandlers, QueueRouterPayload, QueueRouterRouting } from './types';
3
+ export declare class QueueRouter {
4
+ protected driver: Client;
5
+ constructor(driver: Client);
6
+ publish(message: QueueRouterPayload): Promise<boolean>;
7
+ consume(routing: QueueRouterRouting, handlers: QueueRouterHandlers): Promise<void>;
8
+ }
9
+ //# sourceMappingURL=module.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/module.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAI7C,OAAO,KAAK,EAER,mBAAmB,EACnB,kBAAkB,EAAE,kBAAkB,EACzC,MAAM,SAAS,CAAC;AAEjB,qBAAa,WAAW;IACpB,SAAS,CAAC,MAAM,EAAG,MAAM,CAAC;gBAId,MAAM,EAAE,MAAM;IAM1B,OAAO,CAAC,OAAO,EAAE,kBAAkB,GAAI,OAAO,CAAC,OAAO,CAAC;IA2BvD,OAAO,CAAC,OAAO,EAAE,kBAAkB,EAAE,QAAQ,EAAE,mBAAmB,GAAI,OAAO,CAAC,IAAI,CAAC;CAsDtF"}
@@ -0,0 +1,4 @@
1
+ import { QueueRouter } from './module';
2
+ export declare function isQueueRouterUsable(): boolean;
3
+ export declare function useQueueRouter(): QueueRouter;
4
+ //# sourceMappingURL=singleton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"singleton.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/singleton.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAWvC,wBAAgB,mBAAmB,YAElC;AAED,wBAAgB,cAAc,gBAE7B"}
@@ -0,0 +1,31 @@
1
+ import type { QueueRouterRoutingType } from './constants';
2
+ export type QueueRouterRouting = {
3
+ type: `${QueueRouterRoutingType}`;
4
+ key: string;
5
+ namespace?: string;
6
+ };
7
+ export type QueueRouterPayloadMetadata = {
8
+ timestamp: number;
9
+ redelivered?: boolean;
10
+ persistent?: boolean;
11
+ routing: QueueRouterRouting;
12
+ };
13
+ export type QueueRouterPayload<T = string, D = Record<string, any>> = {
14
+ id: string;
15
+ type: T;
16
+ data: D;
17
+ metadata: QueueRouterPayloadMetadata;
18
+ };
19
+ export type QueueRouterPayloadInput<T = string, D = Record<string, any>> = {
20
+ id?: string;
21
+ type: T;
22
+ data?: D;
23
+ metadata: Partial<Pick<QueueRouterPayloadMetadata, 'timestamp'>> & Omit<QueueRouterPayloadMetadata, 'timestamp'>;
24
+ };
25
+ export type QueueRouterHandler<T = string, D = Record<string, any>> = (message: QueueRouterPayload<T, D>) => Promise<void> | void;
26
+ export type QueueRouterHandlers<R extends Record<string, Record<string, any>> = Record<string, Record<string, any>>> = {
27
+ $any?: QueueRouterHandler;
28
+ } & {
29
+ [K in keyof R]: QueueRouterHandler<K, R[K]>;
30
+ };
31
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/core/queue-router/types.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAE1D,MAAM,MAAM,kBAAkB,GAAG;IAC7B,IAAI,EAAE,GAAG,sBAAsB,EAAE,CAAC;IAClC,GAAG,EAAE,MAAM,CAAC;IACZ,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,OAAO,EAAE,kBAAkB,CAAA;CAC9B,CAAC;AAEF,MAAM,MAAM,kBAAkB,CAC1B,CAAC,GAAG,MAAM,EACV,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,IACvB;IACA,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,CAAC,CAAC;IACR,IAAI,EAAE,CAAC,CAAC;IACR,QAAQ,EAAE,0BAA0B,CAAA;CACvC,CAAC;AAEF,MAAM,MAAM,uBAAuB,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,IAAI;IACvE,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,CAAC,CAAC;IACR,IAAI,CAAC,EAAE,CAAC,CAAC;IACT,QAAQ,EAAE,OAAO,CAAC,IAAI,CAAC,0BAA0B,EAAE,WAAW,CAAC,CAAC,GAChE,IAAI,CAAC,0BAA0B,EAAE,WAAW,CAAC,CAAA;CAChD,CAAC;AAEF,MAAM,MAAM,kBAAkB,CAC1B,CAAC,GAAG,MAAM,EACV,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,IACvB,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;AAEhE,MAAM,MAAM,mBAAmB,CAC3B,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,IACnF;IACA,IAAI,CAAC,EAAE,kBAAkB,CAAA;CAC5B,GAAG;KACC,CAAC,IAAI,MAAM,CAAC,GAAG,kBAAkB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;CAC9C,CAAC"}