AAI Converter fails for Autosys Scheduler due to duplicate GlobalVariable names in Autosys, one with leading space, one without.
Errors in jaws.log and hibernate.log will show constraint errors like below:
Release : 6.0.1
Component : AUTOMIC AUTOMATION INTELLIGENCE ENGINE
You need to look for leading spaces in the GlobalVariables in AAI and Autosys.
Below are a summary of what we did to identify and resolve the issue.
1. The query below would sort by globalVariableName, which would bring anything with a leading space to the top of the list, replace the SCHEDULER_NAME with your scheduler name.
You can also use a query like below to find all GlobalVariableNames with a Space either leading, trailing or in the middle. Only Leading or Trailing should be an issue, if there is another globalVariable with the same name.
select s.jobSchedulerId, s.schedulerName, gv.*
from GlobalVariable gv, JobScheduler s
where s.schedulerName = 'SCHEDULER_NAME'
and gv.globalVariableName like '% %'
and s.jobSchedulerId = gv.jobSchedulerId
order by gv.globalVariableName;
2. Once you have identified the GlobalVariableName with a leading space, look for a duplicate of that name in the query output above.
3. Once you have identified the duplicate, search Autosy for this variable using the autorep command like below using that GlobalVariableName in the command below:
6. Stop the AAI service.
7. Then use the DummyJaws value for globalVariableId from the query output of step 3, in the query below
8. Then delete the entries for that GlobalVariable from the GlobalVariable table in AAI with:
9. Attempt a "Download Now" and verify if it completes.