I have created a stored procedure which has just one insert statement to a table which takes 10 times longer to execute as compared to sending the exact same insert statement executed using mariadb client.
I am calling the stored procedure from a python program. Tested the same insert SQL directly executing from python program.
It takes one second to do 50 inserts (row) by calling stored procedure each time
It takes one second to do 500 inserts (no stored procedure call) by executing insert SQL stmt each time