Share all details related to your problem, including any error messages you may have received.
Hi all!
I need to import XML objects from a folder that is in /opt/sailpoint/…/ and I need to achieve this using a rule. Is there a way to do this?
These XML objects are identities, and the idea would be running a task that will be using this rule, and this rule will be picking up these XML objects, importing and creating them in the environment.
Thanks for the reply!
Let me see if we have access to the IIQ console.
Apart from that option, do you have any other suggestions? Especially because the servers are Linux, and .bat files won’t be executable.
Hi @ashutosh08, thanks for commenting!
I’m following your instructions as below:
sailpoint.tools.xml.XMLReferenceResolver xml = new SimpleXMLReferenceResolver();
Object obj = SailPointObject.parseXml(xml,FileUtils.readFileToString(new File("opt/sailpoint/..."),Charset.defaultCharset()));
context.importObject((SailPointObject) obj);
context.saveObject(obj);
context.commitTransaction();
It doesn’t throw any errors if I use context.saveObject but looks like it doesn’t create the identity.
If I use commitTransaction, it throws the following error:
"Exception running rule: The application script threw an exception: sailpoint.tools.GeneralException: org.hibernate.TransientObjectException: object references an usaved transient instance - save the transient instance before flushing: sailpoint.object.identity BSF info: Run Rule at line: 0 column: columnNo"
If I’m doing something wrong, if I’m missing anything please let me know!