On 09/05/2018 22:49, Arnold Miller wrote:
Hi,
I'm getting this
"java.lang.IllegalStateException: Object {Uid=Attribute:
{Name=__UID__, .....
was returned by the connector but failed to pass the framework filter.
This seems like wrong implementation of the filter in the connector."
when the Search script is executed after running a Push task.
From a previous message I found that the search script must return all
the attributes it is asked for:
https://www.mail-archive.com/[email protected]/msg02339.html
Which basically means that you fill in all the values in ATTRS_TO_GET
[.....]
I am doing that and also I am returning the result as suggested in
https://github.com/apache/syncope/blob/2_0_X/fit/core-reference/src/test/resources/rest/SearchScript.groovy#L76-L93
like this:
result.add(buildConnectorObject(node));
My questions:
1. Why am I getting that "IllegalStateException" described above?
The error above means that your search script is returning something
that does not match with the original request: suppose that Syncope asks
for a filter like as "name == 'Francesco'" and the result returned from
the search script does not have the "name" attribute, or value is "Arnold".
2. If the script is finding the item it is requested to, why does it
trigger the creation script instead of the update script?
The point is exactly this: because of the exception above, Syncope does
not find any item, hence create is invoked.
HTH
Regards.
--
Francesco Chicchiriccò
Tirasa - Open Source Excellence
http://www.tirasa.net/
Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/