service contract create through webservice takes 2 minutes
As you can see in this thread: https://discussions.vtiger.com/discussion/186456/slow-create-update-via-web-services-api#latest
problem still exists and it is not fixed.
It fails because of the DB constraints and foreign keys. ServiceContract foreign_key/id don't exist at the time of update.
These following 2 sql update scripts run around 40s each not because they take such amount of time but it's mysql DB set timeout. It's clear while the constrain fails the "Service Contract" SQL table is locked therefore causing the CRM system to timeout for other users.
UPDATE vtiger_servicecontracts SET end_date=? WHERE servicecontractsid = ? UPDATE vtiger_servicecontracts SET planned_duration = '',actual_duration = '',progress = NULL WHERE servicecontractsid = ?
Debug Call stack points to ServiceContracts.php->caclulateProgress()
Issue is cause when creating a Service Contract via the webservice.
Note: Using the CRM Web interface everything runs smoothly.