Hi:
I have a function, if I call it from DBeaver, it returns within a minute.
call commonhp.run_unified_profile_load_script_work_assignment_details('BACDHP', 'G3XPM6YE2JHMSQA2');
but if I called it from spring jdbc template, it never comes back:
public void runTransform(String proc, InitDataLoadEntity entity) {
log.info("Initial data finished data migration for {}, starting transform for {}...", entity.getOrganizationOid(), proc);
var schema = clientDbInfo.getSchema(entity.getOrganizationOid())[1].toUpperCase();
var count = unifiedProfileJdbcTemplate.update("call commonhp." + proc + "(?, ?)", schema, entity.getOrganizationOid());
log.info("Initial data finished data migration for {}, end transform for {}, result is {}", entity.getOrganizationOid(), proc, count);
}
The server does show high CPU, the function has mainly just one insert command (batch insert), the target table has 3 FKs.