killing py4j request and java processes associated with it

57
July 16, 2019, at 12:00 PM

I am calling java function from python using py4j java gateway.

python code

from py4j.java_gateway import JavaGateway, GatewayParameters
  gateway=JavaGateway(gateway_parameters=GatewayParameters
  (port=port.port))
  promo_engine = gateway.entry_point
  order_json_string = promo_engine.placeOrder(1L, True, 1L, "true", 
  None, "1PAY", False, cart)

placeOrder function is written in java code

strating the gateway server in java code

GatewayServer gatewayServer1 = new GatewayServer(new 
   PromotionBO(),port);
   gatewayServer1.start();
public Order placeOrder() { 
//some logic
// this is the function which is called from python 
}

Is there any way to close the request and kill the java process if response takes more than 30 seconds?

Thanks in Advance.

READ ALSO
Python Threads: event.set does not activate the thread in Task/Job management

Python Threads: event.set does not activate the thread in Task/Job management

I have a Task Broker who uses an internal message queue (redis) where Workers poll tasks fromThe tasks have a timeout and should be finished by a Worker before they are expired

73
How to customize AOSP keyboard?

How to customize AOSP keyboard?

I can try to add tab layout in AOSP keybord but tab click doesn't work and also whatsapp edittext hide behind tab so please help me how to add tab functionality in AOSP keyboard ?

56
Showing error while routing from one screen to another in flutter

Showing error while routing from one screen to another in flutter

I'm moving from one screen to another screen but it shows error in routingMy First screen named as VenueOption and the second one is PlayerOption

66
How to change “Battery Saver -> Allow Background Running” by programming on OPPO A3S with ColorOs

How to change “Battery Saver -> Allow Background Running” by programming on OPPO A3S with ColorOs

I want to my app always running In-Background, but it did not work with OPPO Device ColorOs Version

45