You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background: Start with the java code and use gunicorn to start the python server with multiple works
The java side uses the following code:
public static void main(String[] args) {
GatewayServer server = new GatewayServer(func);
server.start();
The python side uses the following code:
from py4j.java_gateway import JavaGateway
jvm = JavaGateway()
function = jvm.getfunc()
When multiple threads from python call java, the result will be confused. For example, the input of thread 1 is not returned to thread 1, but to thread 2
The text was updated successfully, but these errors were encountered:
I tried using gunicorn to start a work to start a python method, that is, a single process, and then the python method used multiple threads to call java, but it still returned confusing results. Am I doing it wrong?
Background: Start with the java code and use gunicorn to start the python server with multiple works
The java side uses the following code:
public static void main(String[] args) {
GatewayServer server = new GatewayServer(func);
server.start();
The python side uses the following code:
from py4j.java_gateway import JavaGateway
jvm = JavaGateway()
function = jvm.getfunc()
When multiple threads from python call java, the result will be confused. For example, the input of thread 1 is not returned to thread 1, but to thread 2
The text was updated successfully, but these errors were encountered: