Search code examples
node.jsapache-kafkanode-moduleslibrdkafka

Does 'node-rdkafka' a nodeJs module need python on runtime?


I know, the node-rdkafka module depends on the node-gyp build tool, which in turn requires Python during the build process. Wanted to understand if it needs python during application runtime or not.


Solution

  • The short answer is no; node-rdkafka does not require Python during application runtime.

    The node-rdkafka module depends on the node-gyp build tool, which does require Python during the build process. This is because node-gyp uses Python scripts to build native modules. However, this dependency is only relevant during the installation and build operation of the module.

    Once the node-rdkafka module is successfully built and installed, there is no need for Python during the runtime of your Node.js application. Therefore, the module's Python dependency is limited to the build process and is not required to run your application using the node-rdkafka module.

    If you review the GitHub repo, you can see that Python is only used in the build process.Screenshot of repo