AnsweredAssumed Answered

How to use retry on send_wait (update_object)?

Question asked by melis.yazici on Nov 13, 2017
Latest reply on Nov 14, 2017 by cdtj

Hi,

 

We use below on spel code.This spel code sometimes doesnt work.Therefore we want to use retry.I find SPEL: Object update  file.Can I use this it(retry) in the following file? 

cr::zCR_AutoDialerClose(...)
{
string cr_persid;
cr_persid = argv[3];
//logf(SIGNIFICANT, "zCR_AutoDialerClose : , cr_persid : %s",cr_persid);
logf(ERROR, " zVFTR_AutoDialerflag cr_persid : %s ",cr_persid);
uuid who;
object group_leader;
send_wait(0,top_object(), "call_attr", "cnt", "current_user_id");
who=msg[0];

send_wait(0, top_object(), "get_co_group");
if (msg_error())
{
printf("Error IF ACTION MACRO HATASI'%s'", msg[0]);
}
else
{
group_leader = msg[0];
}

send_wait(0, top_object(), "call_attr", "api", "update_object", who, cr_persid, NULL, group_leader, 0, "status", 'CL');
if (!msg_error()) {
send_wait(0, group_leader, "checkin");
if (msg_error()) {
printf("Error: '%s'", msg[0]);
}
}
else{
printf("Update failed %s",msg[0]);
}

logf(ERROR, " zVFTR_AutoDialerflag cr_persid : %s ",cr_persid);
}

Regards,

Burcu

Outcomes