{"_id":"@alexknips/nestjs-kafka-events","_rev":"3-ea1fd1a364cf51c74baf66da00b881b9","name":"@alexknips/nestjs-kafka-events","dist-tags":{"latest":"1.1.5"},"versions":{"1.1.1":{"name":"@alexknips/nestjs-kafka-events","version":"1.1.1","description":"Lightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry.","author":{"name":"Alexander Knips"},"private":false,"license":"MIT","main":"dist/index.js","types":"dist/index.d.ts","homepage":"https://github.com/alexknips/nestjs-kafka-events","bugs":{"url":"https://github.com/alexknips/nestjs-kafka-events/issues"},"keywords":["kafka","kafkajs","typescript","nestjs","kafka events","nest","nest events","nestjs events","confluent","schema registry","schema"],"scripts":{"prebuild":"rimraf dist","build":"nest build","prepare":"tsc --project tsconfig.build.json","format":"prettier --write \"src/**/*.ts\" \"test/**/*.ts\"","lint":"eslint \"{src,apps,libs,test}/**/*.ts\" --fix","test":"jest","test:watch":"jest --watch","test:cov":"jest --coverage","test:debug":"node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand","test:e2e":"jest --config ./test/jest-e2e.json"},"dependencies":{"@kafkajs/confluent-schema-registry":"^3.2.1","kafkajs":"^2.1.0","rimraf":"^3.0.2","rxjs":"^7.5.6"},"peerDependencies":{"@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","reflect-metadata":"^0.1.13"},"devDependencies":{"@nestjs/cli":"^9.0.0","@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","@nestjs/schematics":"^9.0.1","@nestjs/testing":"^9.0.4","@types/express":"^4.17.13","@types/jest":"^26.0.24","@types/node":"^14.18.22","@types/supertest":"^2.0.12","@typescript-eslint/eslint-plugin":"^4.33.0","@typescript-eslint/parser":"^4.33.0","eslint":"^7.32.0","eslint-config-prettier":"^8.5.0","eslint-plugin-prettier":"^3.4.1","jest":"^26.6.3","prettier":"^2.7.1","reflect-metadata":"^0.1.13","supertest":"^6.2.4","ts-jest":"^26.5.6","ts-loader":"^8.4.0","ts-node":"^9.1.1","tsconfig-paths":"^3.9.0","typescript":"^4.2.3"},"jest":{"moduleFileExtensions":["js","json","ts"],"rootDir":"src","testRegex":".*\\.spec\\.ts$","transform":{"^.+\\.(t|j)s$":"ts-jest"},"collectCoverageFrom":["**/*.(t|j)s"],"coverageDirectory":"../coverage","testEnvironment":"node"},"licenseText":"MIT License\n\nCopyright (c) 2022 Alexander Knips\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.","_id":"@alexknips/nestjs-kafka-events@1.1.1","dist":{"shasum":"e1f47b43086f2445612168bbdef39d20cbcb6aec","integrity":"sha512-tUG3ExthMlmH0pB4COMq0uqaz2vuUlGn8msRJ9jsAdTzE836cF6J3lk7urKHNvpIVIl8l0JqIi9WURyK7rAlhw==","tarball":"https://registry.npmjs.org/@alexknips/nestjs-kafka-events/-/nestjs-kafka-events-1.1.1.tgz","fileCount":76,"unpackedSize":178150,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDwLqewt/mXrtAzrtsVgCcfeJY8nNZAPDuqXfYe6ultGAiAS61XIglHP2kdCq4d6Poo4l16VRtsWI+CXSmxX3aSU7g=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi15MMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrFKw//c8++2xi6Nfmh/CwjcBWR/un9k/E9bUdqOZmHfWAI1B1NS18R\r\nJa2JLfjzpyUFEgKdoexCIYwvCoS01HUsK6MRqc3IVLk+VfD5Rsn/gRNBjEcB\r\nvn04dW58q8oayFS2+SAzMyGpjW3CDPwqnq0r0QCSxuLx3hCCQVI9c/rE1Rb7\r\n1TUfg2AqhOo0+jexMoBWMdFUsMWIzFyb1eXx284B8eOFOB6QS5+MdQe6K4Kq\r\nrkUkTfFUQMrGIfA/OKDh1LBCbsSwGMTGB0e7oU/pM7Am8OeUgZl+qzo5+IKl\r\nxSapWd8rUgMsS1XZtwxlqOiWoo6/lGBX3HlwIq6/gEMSZA4z+MINGyWIzZTX\r\nFniaZPSXsqz76EJzCVXCJCkV/ZLBQKpBn3z3XKKGAEdYRe5yT6hFTtKSzL8s\r\nUPtRTld1eQbeLmXkR8YhoSbDvuO+vwJrFp3Pk7WZfNomB6SQROnx/BbwIvF5\r\npXcZ95efhl7siwviHl0K3q0NjWH320ofYk2TLUlm5gkgBPpFrTCOJCQ8C8DW\r\nJ4Eaa6EmqB2EXzLgNr2H31f6M9S4P+UVveLtqPo8aKAhgLqRXuyRKzw+pRo5\r\nuNbCFwiPA8rLV6yuEng5GvwYs1sPH8ak1ejBrTKsypincwFyuVeF7LwWC4zz\r\nsHOvlll07buJeLnP4K0b9Kwq89VdK6GJTzg=\r\n=RwSx\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"alexknips","email":"alex.knips@gmail.com"},"directories":{},"maintainers":[{"name":"alexknips","email":"alex.knips@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/nestjs-kafka-events_1.1.1_1658295051944_0.16547439916104256"},"_hasShrinkwrap":false},"1.1.2":{"name":"@alexknips/nestjs-kafka-events","version":"1.1.2","description":"Lightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry.","author":{"name":"Alexander Knips"},"private":false,"license":"MIT","main":"dist/index.js","types":"dist/index.d.ts","homepage":"https://github.com/alexknips/nestjs-kafka-events","bugs":{"url":"https://github.com/alexknips/nestjs-kafka-events/issues"},"keywords":["kafka","kafkajs","typescript","nestjs","kafka events","nest","nest events","nestjs events","confluent","schema registry","schema"],"scripts":{"prebuild":"rimraf dist","build":"nest build","prepare":"tsc --project tsconfig.build.json","format":"prettier --write \"src/**/*.ts\" \"test/**/*.ts\"","lint":"eslint \"{src,apps,libs,test}/**/*.ts\" --fix","test":"jest","test:watch":"jest --watch","test:cov":"jest --coverage","test:debug":"node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand","test:e2e":"jest --config ./test/jest-e2e.json"},"dependencies":{"@kafkajs/confluent-schema-registry":"^3.2.1","kafkajs":"^2.1.0","rimraf":"^3.0.2","rxjs":"^7.5.6"},"peerDependencies":{"@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","reflect-metadata":"^0.1.13"},"devDependencies":{"@nestjs/cli":"^9.0.0","@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","@nestjs/schematics":"^9.0.1","@nestjs/testing":"^9.0.4","@types/express":"^4.17.13","@types/jest":"^26.0.24","@types/node":"^14.18.22","@types/supertest":"^2.0.12","@typescript-eslint/eslint-plugin":"^4.33.0","@typescript-eslint/parser":"^4.33.0","eslint":"^7.32.0","eslint-config-prettier":"^8.5.0","eslint-plugin-prettier":"^3.4.1","jest":"^26.6.3","prettier":"^2.7.1","reflect-metadata":"^0.1.13","supertest":"^6.2.4","ts-jest":"^26.5.6","ts-loader":"^8.4.0","ts-node":"^9.1.1","tsconfig-paths":"^3.9.0","typescript":"^4.2.3"},"jest":{"moduleFileExtensions":["js","json","ts"],"rootDir":"src","testRegex":".*\\.spec\\.ts$","transform":{"^.+\\.(t|j)s$":"ts-jest"},"collectCoverageFrom":["**/*.(t|j)s"],"coverageDirectory":"../coverage","testEnvironment":"node"},"licenseText":"MIT License\n\nCopyright (c) 2022 Alexander Knips\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.","_id":"@alexknips/nestjs-kafka-events@1.1.2","dist":{"shasum":"a8db9c6fec3bcd10efa263f295975446edca7be2","integrity":"sha512-sEAhJ6sY/rAecN+ccGIqzf5OlOjxrMXfvyhQStTMHGLIwANC1MvkZdlc5aoEvofDPbtUV/cI7+7QhAp4Di5i1A==","tarball":"https://registry.npmjs.org/@alexknips/nestjs-kafka-events/-/nestjs-kafka-events-1.1.2.tgz","fileCount":76,"unpackedSize":178012,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCsKPFhggqqIki9UkSs6u9iDkDhubCZdZM/e0bYR/5yGQIhAIBVVWnEllH66pekaYsa6Lp7jR1fpdkoRV3UCcArpBlg"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjDmrdACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpdSQ//bgPzV1ejiGyENVEs6jAMLEryN7tNs8L96Lt1Om3I+UEimF1J\r\n2KOjp2THO18lPbO1LWH14T6kaIFhutrqSopXHQaK6hU8vxmKZZtdvh/eLlba\r\nviSlcmctr9jNijCIA5i3VoP8lL5h4FNsQdmGlh/hBbPIbaEPVqcwED5YbKTs\r\npK+/3CyGJezSSGPKKfuzIQBjJbNdLHH8nG/0EedMO8wFX2OvLgc+gLILdCMG\r\nC+5/kCrg8WxQfSd0x4bvfBO+Oi7M4K99R26GHn2ApyUliO6FXiP2vXBjrjm3\r\nepCoSK/1oy3LflYsdQcUDjx9PDsuj/l7AymETfrcWZILjxpS2UWBPAWrUkIF\r\ntmCHvEvV+9oDv3+/IBEre2+8C1DWPDPp98266jFf4zJos7f+u4lJLPqc4xiE\r\npG7KrcEAgIPRFJ3CnlU5yQKQGEY8QINgwM1KfgqPrGJV+V4nqWG4rNmRj33z\r\nTAvyD+m0vfm7cyD0MJrJNtdtkx4OGpcZBmYRHp3jsgSsq3VOGWqAP0HmUPcW\r\nqEY6KBCdfwZ0rOsAg8EVz4mtXgY1P8CM7l1zxVSnGiFVnYYDfzgfOWAWJ/yU\r\nZoXWPpI5o4kccRnlpU3xVWw+sdJRUPx7pezfDhkdxoxJHOqvHua9zBUSo3FO\r\n5AxUarQBnTs0XvTlSdtGuSnZCij9b4iDW+I=\r\n=6Hq7\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"alexknips","email":"alex.knips@gmail.com"},"directories":{},"maintainers":[{"name":"alexknips","email":"alex.knips@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/nestjs-kafka-events_1.1.2_1661889245109_0.3845923357327463"},"_hasShrinkwrap":false},"1.1.4":{"name":"@alexknips/nestjs-kafka-events","version":"1.1.4","description":"Lightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry.","author":{"name":"Alexander Knips"},"private":false,"license":"MIT","main":"dist/index.js","types":"dist/index.d.ts","homepage":"https://github.com/alexknips/nestjs-kafka-events","bugs":{"url":"https://github.com/alexknips/nestjs-kafka-events/issues"},"keywords":["kafka","kafkajs","typescript","nestjs","kafka events","nest","nest events","nestjs events","confluent","schema registry","schema"],"scripts":{"prebuild":"rimraf dist","build":"nest build","prepare":"tsc --project tsconfig.build.json","format":"prettier --write \"src/**/*.ts\" \"test/**/*.ts\"","lint":"eslint \"{src,apps,libs,test}/**/*.ts\" --fix","test":"jest","test:watch":"jest --watch","test:cov":"jest --coverage","test:debug":"node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand","test:e2e":"jest --config ./test/jest-e2e.json"},"dependencies":{"@kafkajs/confluent-schema-registry":"^3.2.1","kafkajs":"^2.1.0","rimraf":"^3.0.2","rxjs":"^7.5.6"},"peerDependencies":{"@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","reflect-metadata":"^0.1.13"},"devDependencies":{"@nestjs/cli":"^9.0.0","@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","@nestjs/schematics":"^9.0.1","@nestjs/testing":"^9.0.4","@types/express":"^4.17.13","@types/jest":"^26.0.24","@types/node":"^14.18.22","@types/supertest":"^2.0.12","@typescript-eslint/eslint-plugin":"^4.33.0","@typescript-eslint/parser":"^4.33.0","eslint":"^7.32.0","eslint-config-prettier":"^8.5.0","eslint-plugin-prettier":"^3.4.1","jest":"^26.6.3","prettier":"^2.7.1","reflect-metadata":"^0.1.13","supertest":"^6.2.4","ts-jest":"^26.5.6","ts-loader":"^8.4.0","ts-node":"^9.1.1","tsconfig-paths":"^3.9.0","typescript":"^4.2.3"},"jest":{"moduleFileExtensions":["js","json","ts"],"rootDir":"src","testRegex":".*\\.spec\\.ts$","transform":{"^.+\\.(t|j)s$":"ts-jest"},"collectCoverageFrom":["**/*.(t|j)s"],"coverageDirectory":"../coverage","testEnvironment":"node"},"licenseText":"MIT License\n\nCopyright (c) 2022 Alexander Knips\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.","_id":"@alexknips/nestjs-kafka-events@1.1.4","dist":{"shasum":"fb1fe6e139a1a5570055eb34ce948b2cfb3e9c8c","integrity":"sha512-1P83tjwWQ01gKGGX/16xsdqE744vxOSndJWcWwFO4gZ6gmwJYiuDTBe6gvOywo6/lqy49cE7iSez2TuGWLchkQ==","tarball":"https://registry.npmjs.org/@alexknips/nestjs-kafka-events/-/nestjs-kafka-events-1.1.4.tgz","fileCount":76,"unpackedSize":178627,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD54tHQZnkjWXIa++MossEJFvJ7bbYiKDPSmg6+Um1xUQIgDe+Gs4ditACQzuFbc/1eMc/+8YtXMbysAmgTpPPI+Lg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjD9eZACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpZ9g//cGOOvzn45xlblypkrerfXw246uKw62SvYd0yHfHXiEn8iWwM\r\n3XENgyF5d9MZtRFqNxuBXIuWJvgPOYSWTvTtsO0RjdGiM/EQ+RFRXJyP3OpD\r\npsN5cNcTqRfSpdAwMaOz97nWVs7HCH6LUE9JOmKHWZPwku9GhAZPk99VsGSe\r\n0u7fdBeszw/JFQY4tEngdazss8eu45RdnzbtHWn3Fbf5H77DXZ65qS2xpaWE\r\nAO4K7BaOfXLUqyvuH7cwFSOXELwotG2fRQeJPft4BO1/pmB/buM90f4qWVXa\r\nngVCkSaedXPtNJlnllIeNi+MjFVRNwCVUKgakRnYJMIKQqVitlBTrWrFL911\r\ngzkXAbK0sYKASO79wOeR5rGx690G0E7ZfrQZJ+ikSgDouI7aF0X8dICOAesz\r\n5sNNNcMf+Gr7dPCLQQn4XsFVSQV9ApfzlkZNLyNnj7FfxGfj3x+96/+eYczb\r\nsxcUiXL3exKY5bFJyFoEc75JnF9yf0xVkDERN84xOZwSFQaUWHTIw4ddSmBd\r\ndM9ATpCcY4feNdL6mQvmxjPRPyvQqp2YgR9IGYaM5oHLaBMecJo7MBODDHbM\r\n+D+Wq4M8asfQ+/pH1EtB0ZJtTIrqOj4UP6xr2fcuOJAomo/Zbx/DoPi1432L\r\nbFhAssNa9sVBlhUC7dqc6ZxIxyO7tWI2bt0=\r\n=YDBE\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"alexknips","email":"alex.knips@gmail.com"},"directories":{},"maintainers":[{"name":"alexknips","email":"alex.knips@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/nestjs-kafka-events_1.1.4_1661982617397_0.7932201358784052"},"_hasShrinkwrap":false},"1.1.5":{"name":"@alexknips/nestjs-kafka-events","version":"1.1.5","description":"Lightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry.","author":{"name":"Alexander Knips"},"private":false,"license":"MIT","main":"dist/index.js","types":"dist/index.d.ts","homepage":"https://github.com/alexknips/nestjs-kafka-events","bugs":{"url":"https://github.com/alexknips/nestjs-kafka-events/issues"},"keywords":["kafka","kafkajs","typescript","nestjs","kafka events","nest","nest events","nestjs events","confluent","schema registry","schema"],"scripts":{"prebuild":"rimraf dist","build":"nest build","prepare":"tsc --project tsconfig.build.json","format":"prettier --write \"src/**/*.ts\" \"test/**/*.ts\"","lint":"eslint \"{src,apps,libs,test}/**/*.ts\" --fix","test":"jest","test:watch":"jest --watch","test:cov":"jest --coverage","test:debug":"node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand","test:e2e":"jest --config ./test/jest-e2e.json"},"dependencies":{"@kafkajs/confluent-schema-registry":"^3.2.1","kafkajs":"^2.1.0","rimraf":"^3.0.2","rxjs":"^7.5.6"},"peerDependencies":{"@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","reflect-metadata":"^0.1.13"},"devDependencies":{"@nestjs/cli":"^9.0.0","@nestjs/common":"^9.0.4","@nestjs/core":"^9.0.4","@nestjs/schematics":"^9.0.1","@nestjs/testing":"^9.0.4","@types/express":"^4.17.13","@types/jest":"^26.0.24","@types/node":"^14.18.22","@types/supertest":"^2.0.12","@typescript-eslint/eslint-plugin":"^4.33.0","@typescript-eslint/parser":"^4.33.0","eslint":"^7.32.0","eslint-config-prettier":"^8.5.0","eslint-plugin-prettier":"^3.4.1","jest":"^26.6.3","prettier":"^2.7.1","reflect-metadata":"^0.1.13","supertest":"^6.2.4","ts-jest":"^26.5.6","ts-loader":"^8.4.0","ts-node":"^9.1.1","tsconfig-paths":"^3.9.0","typescript":"^4.2.3"},"jest":{"moduleFileExtensions":["js","json","ts"],"rootDir":"src","testRegex":".*\\.spec\\.ts$","transform":{"^.+\\.(t|j)s$":"ts-jest"},"collectCoverageFrom":["**/*.(t|j)s"],"coverageDirectory":"../coverage","testEnvironment":"node"},"licenseText":"MIT License\n\nCopyright (c) 2022 Alexander Knips\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.","_id":"@alexknips/nestjs-kafka-events@1.1.5","dist":{"shasum":"b5a677c3e244951c655c42e35b3b50ddab241c89","integrity":"sha512-XRsEXBu+WzV/4aYKTudOBJDDTjKXW231aCj4ogAfEsAPJ3uqf/6zbxh6QCsrFiuSqvML1dui+ocguf07JrdypA==","tarball":"https://registry.npmjs.org/@alexknips/nestjs-kafka-events/-/nestjs-kafka-events-1.1.5.tgz","fileCount":76,"unpackedSize":178627,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIH+abHnB9h3KRhdnMQ1hvsBi9q/sTMVvTqowDe4OJgqsAiB9yQmlB7uBvMP2wquyEMVsRkNCyeDj0pOUTou/5VT9JQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjD9mCACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoiMA//Val8bgt6ceerIaRTGVSSxYUrJlbhrc/jXeYWDJBzftQtbXmR\r\nYkw7/nNGO3An2lUDkL7HYUkbg6turPXNW7DAuC6iNLP0UA8WugNyM4QYjiHZ\r\nfle10r/DkOZ7W/FYDGRFE1GS/qf1mfbfRhfUKFOrqHXBJqDty0cm3wjQYRlm\r\nKJnPpVMTPLGzHj8Hx/mwUe7l++9arkbsFai9yy+1QOS90keCM751SYXFWzyV\r\ndhLOz2VaqDu7F70OKFei6yD1Vxu2T7+8vyx4Jhpw4yJJhDMXjHcVn1RB4yN2\r\nkn5i3VF6stI+q/DaCbl8tKA19ZVq91De3DViOWwSwAsbxlc73WWSH99B5dL3\r\nh4DuNCEO5FjKOSsifPlmgr3VKf6SjSYndhUmMm5f3l1w1RSc/IewtEp0AsNc\r\nx/oDTKpOWc9E7fiwSI/7/b+SmsjqfB6LnnivrTqZheG5/bq82lwuQJHOw95a\r\nhqtL9KR+7PUSUNO/qqIl9zYMIw+xNqIKbBRLemz88w9p2rcyzoVhNGmriAfv\r\nh4G6NvJvZJKFNo8QnBkDbU+mo7PSGu+uYDi/I3cNnJSu1Pa7FcUbFhmYE63a\r\naalNe8QAtf8GlAHRnEGcCJ10gh7yg1CK/lGUAHk3BlcXhyyYBshMS4VEM4/v\r\nUwUkmx3NdbQEXrAxNf5E4kz9lbjZCob1iNw=\r\n=IB3u\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"alexknips","email":"alex.knips@gmail.com"},"directories":{},"maintainers":[{"name":"alexknips","email":"alex.knips@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/nestjs-kafka-events_1.1.5_1661983105950_0.17658578201448183"},"_hasShrinkwrap":false}},"time":{"created":"2022-07-20T05:30:51.886Z","1.1.1":"2022-07-20T05:30:52.087Z","modified":"2022-08-31T21:58:26.267Z","1.1.2":"2022-08-30T19:54:05.256Z","1.1.4":"2022-08-31T21:50:17.570Z","1.1.5":"2022-08-31T21:58:26.197Z"},"maintainers":[{"name":"alexknips","email":"alex.knips@gmail.com"}],"description":"Lightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry.","homepage":"https://github.com/alexknips/nestjs-kafka-events","keywords":["kafka","kafkajs","typescript","nestjs","kafka events","nest","nest events","nestjs events","confluent","schema registry","schema"],"author":{"name":"Alexander Knips"},"bugs":{"url":"https://github.com/alexknips/nestjs-kafka-events/issues"},"license":"MIT","readme":"# NestJS Kafka Events 🏄‍♀️\nOriginally forked from https://github.com/jucr-io/nestjs-kafka-events\nand then versions updated and adapted to my use-case.\n\nLightweight, tested, straight-forward wrapper around KafkaJS and Confluent's Schema Registry\nto integrate with NestJS.\n\nAs the Kafka transporter provided by `@nestjs/microservices` is more focused on the request-response pattern, \nit was more convenient to build a custom module instead of hacking everything into the provided transporter.\n\n▶️ This module is based on the concept that schemas are managed in a central schema registry and are not registered\nautomatically when emitting the first event. This is following the best practices to this topic provided by Confluent.\n\nJust to give you an idea how a workflow could look like:\n\n- Developers registering schemas at the schema registry (either manually or automatically when someone\n  pushes some changes to a specific branch in a repository).\n- As soon as a schema is registered the first time in the registry, it's available to use for all applications\n  relying on this schema registry.\n\n### Usage\n➡️ Install via your favorite package manager e.g. `yarn install @alexknips/nestjs-kafka-events`\n\n▶️ Register module at the root of your application:\n\n```typescript\n// (...)\nimport { KafkaModule } from '@alexknips/nestjs-kafka-events';\n\n@Module({\n  imports: [\n    KafkaModule.registerAsync({\n      useFactory: async (configService: ConfigService) => {\n        return {\n          client: {\n            brokers: configService.brokers,\n            clientId: 'my-service',\n          },\n          consumer: {\n            groupId: 'my-service',\n            allowAutoTopicCreation: true,\n          },\n          producer: {\n            allowAutoTopicCreation: true,\n          },\n          schemaRegistry: {\n            api: {\n              host: 'http://127.0.0.1:9093',\n            },\n          },\n        };\n      },\n      inject: [ConfigService],\n      imports: [ConfigModule],\n    }),\n  ],\n  controllers: [AppController],\n  providers: [AppService, ConfigService],\n})\nexport class AppModule {}\n```\nConfiguration options are the same as mentioned on the documentations of [KafkaJS](https://kafka.js.org/docs/configuration)\nand [@kafkajs/confluent-schema-registry](https://kafkajs.github.io/confluent-schema-registry/).\n\n\n▶️ Register event handlers:\n\n```typescript\n// (...)\nimport { IKafkaEvent, KafkaEventHandler } from '@alexknips/nestjs-kafka-events';\n\ninterface MyEvent {\n  userId: string;\n  email: string;\n}\n\ninterface MyEventKey {\n  userId: string;\n}\n\n@Controller()\nexport class AppController {\n  \n  @KafkaEventHandler('com.example.events.user.created')\n  async myHandler(\n    payload: IKafkaEvent<MyEvent, MyEventKey>,\n  ): Promise<any> {\n    console.log('User registered: ', payload.event);\n    console.log('For co-partitioning: ', payload.key);\n    console.log('Event is arrived at: ', payload.arrival.toDateString());\n  }\n  \n}\n```\n\n▶️ Produce events:\n```typescript\n// (...)\nimport { KafkaEventEmitter, KafkaService } from '@alexknips/nestjs-kafka-events';\n\ninterface MyEvent {\n  userId: string;\n  email: string;\n}\n\ninterface MyEventKey {\n  userId: string;\n}\n\n@Injectable()\nexport class AppService {\n  constructor(private readonly kafkaService: KafkaService) {}\n\n  @KafkaEventEmitter('com.example.events.user.created')\n  async sendMe(): Promise<void> {\n    await this.kafkaService.emit<MyEvent, MyEventKey>({\n      topic: 'com.example.events.user.created',\n      event: {\n        userId: 'my-user-id',\n        email: 'mail@example.com',\n      },\n      key: {\n        userId: 'my-user-id',\n      },\n    });\n  }\n\n  @KafkaEventEmitter([\n    'com.example.events.user.created',\n    'com.example.events.customer.added',\n  ])\n  async sendMeBatch(): Promise<void> {\n    await this.kafkaService.emit([\n      {\n        topic: 'com.example.events.user.created',\n        event: {\n          userId: 'my-user-id',\n          email: 'mail@example.com',\n          createdAt: new Date().valueOf(),\n        },\n        key: {\n          userId: 'my-user-id',\n        },\n      },\n      {\n        topic: 'com.example.events.customer.added',\n        event: {\n          customerId: 'my-customer-id',\n          email: 'mail@example.com',\n        },\n        key: {\n          department: 'sales',\n        },\n      },\n    ]);\n  }\n}\n```\n\n▶️ The `IKafkaEvent` interface and `emit()` method are generic can be used with custom types to stay type-safe.\n\nThe idea behind using decorators for handling and producing events was to simplify the workflow when new schemas/events\nare introduced. By doing it this way, it's easy to fetch all schemas at application start up which are needed for the\ndeserialization done by the library.\nNo need to specify all schemas needed somewhere in application configuration 😎.\n\n### Contributing\nPR's are welcome💕\n\n","readmeFilename":"README.md"}