Name Last Update
..
conf Loading commit data...
script Loading commit data...
README Loading commit data...

README

Logging in Scripts Sample
-------------------------
Copyright (c) 2012 ForgeRock AS
This work is licensed under a Creative Commons Attribution-
NonCommercial-NoDerivs 3.0 Unported License. See
http://creativecommons.org/licenses/by-nc-nd/3.0/

This sample demonstrates logging capabilities available to OpenIDM scripts,
providing you an alternative method for debugging your scripts.

For documentation pertaining to this example see:
http://openidm.forgerock.org/doc/install-guide/index.html#more-sample8

To try the sample, follow these steps.

1. Start OpenIDM with the configuration for sample 8.

$ cd /path/to/openidm
$ ./startup.sh -p samples/sample8

2. Run reconciliation.

$ curl -u openidm-admin:openidm-admin -X POST "http://localhost:8080/openidm/recon?_action=recon&mapping=systemXmlfileAccounts_managedUser"

3. Observe messages from your scripts that are logged to the OpenIDM
(Felix) console:

2012-12-10 21:53:08:691 WARN Case no Source: the source object contains: = null [js]
2012-12-10 21:53:08:693 WARN Case emptySource: the source object contains: = {name=DDOE1, firstname=Darth1, __UID__=1, email=[mail1@example.com], description=Created By XML1, lastname=Doe1, _id=1} [js]
2012-12-10 21:53:08:694 WARN Case sourceDescription: the source object contains: = Created By XML1 [js]
2012-12-10 21:53:08:695 WARN Case onCreate: the source object contains: = {name=DDOE1, firstname=Darth1, __UID__=1, email=[mail1@example.com], description=Created By XML1, lastname=Doe1, _id=1} [js]
2012-12-10 21:53:08:817 WARN Case result: the source object contains: = {SOURCE_IGNORED={count=0, ids=[]}, UNQUALIFIED={count=0, ids=[]}, NOTVALID={count=0, ids=[]}, processed=1, UNASSIGNED={count=0, ids=[]}, TARGET_IGNORED={count=0, ids=[]}, CONFIRMED={count=0, ids=[]}, AMBIGUOUS={count=0, ids=[]}, ABSENT={count=1, ids=[1]}, MISSING={count=0, ids=[]}, SOURCE_MISSING={count=0, ids=[]}, FOUND={count=0, ids=[]}} [js]

Read the short scripts in samples/sample8/script/ to see examples of how
to use the logger object.