In reply to 100rabhh:
Move the req.print statement to after the call to randomize. That will tell you if your legacy IP is set up correctly. Just because you are using legacy code, does not mean you have properly configured it. If the print never happens, you need to debug all the connections and make sure the driver is executing the get_next_item statement.