on 05-24-2022 6:36 AM
I need to call a python script from Node.js runtime.
I have tried using "child-process" library in node to call the Python script which works locally but doesn't install the python libraries (like pandas, etc) in the node runtime in BTP.
I am also trying to host python as a micro service and call it from the node.js using AJAX calls but it's not working as well.
Any leads on a solution will be really appreciated.
This example shows you how you can use libs like flasks in Python and package it up in an MTA. https://blogs.sap.com/2021/04/20/deployment-of-python-web-server-to-cloud-foundry-using-mta/
You could use the same pattern to build out a microservice that encapsulates your Python functionality and then use the MTA to create the bind between Nodejs and Python module.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
7 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.