It is a real divine feeling to watch how Assignment Manager works. One of the joys of AM is system takes care of assigning everything you have created. But as they say, Devi-lies-in-details, issue starts when you dig deep.
Recently we were asked to implement AM for assignment of Service Request only to Logged in Employees. System should not assign SR to any employee which is not available in system.
First look of this problem seems this to be a cake walk. We created Employee availability as skill which was updated every time when he logs in our logs out of the system. But however on actual implementation we realized that skills of employees were not getting refreshed dynamically. It required "Release" button to be pressed every time in order to flush the employee skills and to update rulecache.dat file. Once again Support Web came to rescue and job was saved.
When the employees to assign are not Dynamic Candidates, AM during assignment looks into the cache for the candidate employees instead reading skills directly from the database. However with certain parameters we can achieve dynamic refresh. I will try to club all the possible ways to refresh the skills(One can definitely add more).
There are three possible ways, based on the flavour of Assignment (dynamic, batch , interactive).
1 - 'Refresh People Skills Interval(MaxSkillsAge)' Parameter - The value for this parameter should be greater than 0 seconds. This will refresh skill in specified seconds.
2 - 'Ignore Assignment Rule Code' Parameter - The value for this parameter should be set to TRUE in order to avoid cache.
The above two solutions work fine for Batch Assignment but still for dynamic assignments we were not able to assign service request properly. One reason was dynamic assignment makes use of WorkMon agent and this component doesn't have above parameters.
3 - This approach should be thoroughly tested prior implementation as it can very taxing on your system if you have large number of assignment rules. The idea is to recursively Release the assignment rules using a batch job which runs below business service.
function Service_PreInvokeMethod (MethodName, Inputs, Outputs)
{
var busobj;
var buscomp;
busobj = TheApplication().GetBusObject("Assignment");
buscomp = busobj.GetBusComp("Assignment Group");
buscomp.InvokeMethod("Release");
return (CancelOperation);
}
Disclaimer: If you have a lot of rules and data to load, it will take AsgnSrvr component some time to completely this process, which also means that AsgnSrvr will not be able to accept any incoming assignment requests during this process startup/shutdown and rulecache.dat update until the cache file is completely updated.
With the above three mechanisms one can dynamically refresh the skills or can always bank on Dynamic Candidate mechanism for smooth assignments.
Happy Assignment!!!