Thank you Marco,
worked like a charm!
Something else that I want to know:
I pulled my users with creation and last change dates in this way in my Search
script:
lastChangeDate:it.MODIFIEDON?.toString(),
creationDate:it.CREATEDON?.toString()
(Need to use toString() because it said it didn't support Timestamp)
And when I reviewed the log I found things like this:
Attribute: {Name=creationDate, Value=[2012-06-23 10:39:10.0]} , Attribute:
{Name=lastChangeDate, Value=[2017-07-29 03:43:36.0]}
However when I reviewed the pulled users in Syncope all of them had the current
(today's) date. Is it supposed to be like that?
Note: lastChangeDate is mapped to lastChangeDate, and creationDate is mapped to
creationDate.
Second and most important question:
Login of the users does not work. This is some proof that I pulled up the
password:
{Name=__PASSWORD__,
Value=[org.identityconnectors.common.security.GuardedString@9ce8aa1f]}
Obviously 'username' was pulled up as well. I also changed
password.cipher.algorithm to SHA256 which is the encryption it has on the DB.
However, when I try to login as one of the users it says "Wrong username and/or
password"
What could be wrong?
Best Regards,
Sergio Muriel
________________________________
From: Marco Di Sabatino Di Diodoro <[email protected]>
Sent: Monday, September 25, 2017 3:38 AM
To: [email protected]; Sergio Muriel
Subject: Re: Scripted SQL Pull Task Error
Il 23/09/2017 01:54, Sergio Muriel ha scritto:
Thank you Matteo! It seems like it works.
Now I want to pull the password from an Identity Store so I wrote this on my
script:
__PASSWORD__:it.PW,
With resource mapping:
Internal attribute External attribute Mandatory Remote Key Password Purpose
password __PASSWORD__ false
o x <=>
However I'm getting:
Caused by: java.lang.IllegalArgumentException: Password value must be an
instance of GuardedString
at
org.identityconnectors.framework.common.objects.Attribute.<init>(Attribute.java:114)
~[connector-framework-1.4.2.0.jar:?]
at
org.identityconnectors.framework.common.objects.AttributeBuilder.build(AttributeBuilder.java:188)
~[connector-framework-1.4.2.0.jar:?]
at
org.identityconnectors.framework.common.objects.AttributeBuilder.build(AttributeBuilder.java:87)
~[connector-framework-1.4.2.0.jar:?]
at
net.tirasa.connid.bundles.db.scriptedsql.ScriptedSQLConnector.processResults(ScriptedSQLConnector.java:580)
~[?:?]
at
net.tirasa.connid.bundles.db.scriptedsql.ScriptedSQLConnector.executeQuery(ScriptedSQLConnector.java:403)
~[?:?]
... 20 more
What is wrong? Isn't it the way I should pull the password?
you must add in your groovy script:
import org.identityconnectors.common.security.GuardedString;
and
__PASSWORD__:new GuardedString(it.PW)
Regards
Marco
Best Regards,
Sergio Muriel
________________________________
From: Marco Di Sabatino Di Diodoro
<[email protected]><mailto:[email protected]>
Sent: Friday, September 22, 2017 2:41 AM
To: [email protected]<mailto:[email protected]>
Subject: Re: Scripted SQL Pull Task Error
Hi Sergio,
Il 18/09/2017 18:30, Sergio Muriel ha scritto:
Hi Matteo,
I replaced "username:it.eid" with "username:it.EID" but no luck, still same
result, same exceptions.
I'm getting this on core-connid.log:
........
11:05:59.298 DEBUG Enter: {Uid=Attribute: {Name=__UID__,
Value=[abcdefgh-04a9-4181-9d4d-e3a812345678]}, ObjectClass=ObjectClass:
__ACCOUNT__, Attributes=[Attribute: {Name=__NAME__,
Value=[abcdefgh-04a9-4181-9d4d-e3a812345678]}, Attribute: {Name=__UID__,
Value=[ffe5c419-04a9-4181-9d4d-e3a8a09a8305]}, Attribute: {Name=email,
Value=[[email protected]<mailto:[email protected]>]}], Name=Attribute:
{Name=__NAME__, Value=[ffe5c419-04a9-4181-9d4d-e3a8a09a8305]}} Method: handle
11:05:59.346 DEBUG Return: true Method: handle
.........
11:08:56.979 DEBUG
d:\\syncope-standalone-2.0.4\\project\\myproject\\core\\src\\test\\resources\\scriptedsql\\SakaiUserSearchScript.groovy
is readable Method: checkFileIsReadable
11:08:56.979 INFO Checking Sync Script filename Method: validate
11:08:56.980 DEBUG
d:\\syncope-standalone-2.0.4\\project\\myproject\\core\\src\\test\\resources\\scriptedsql\\SakaiUserSyncScript.groovy
is readable Method: checkFileIsReadable
11:08:56.980 INFO Checking Test Script filename Method: validate
Is there anything else you want to see from scripts?
Where can I find it?
the problem is in your mapping, you've mapped the internal attribute username
with eid, but the search script doesn't return eid
case "__ACCOUNT__":
sql.eachRow("SELECT * FROM sakai_user u, sakai_user_id_map m WHERE u.USER_ID
= m.USER_ID "
+ ((where?.trim ()) ? ("AND" + where) : ""),
{result.add([
__UID__:it.user_id,
__NAME__:it.user_id,
username:it.eid, -----------------> Error
email:it.email,
firstname:it.first_name,
lastname:it.last_name
])
});
you must replace username:it.eid with eid:it.eid
or
fix the mapping with username ----> username
Regards
Marco
Thank you
Best Regards,
Sergio Muriel
________________________________
From: Matteo Alessandroni
<[email protected]><mailto:[email protected]>
Sent: Monday, September 18, 2017 2:25 AM
To: [email protected]<mailto:[email protected]>
Subject: Re: Scripted SQL Pull Task Error
Hi Sergio,
have you already tried to replace "username:it.eid" with "username:it.EID"?
The problem is that I'd need to see some logs from your groovy script to be
sure that all username EID values are not empty.
Regards,
Matteo
On 15/09/2017 18:29, Sergio Muriel wrote:
Hi Matteo,
Sure!
SELECT * FROM sakai_user u, sakai_user_id_map m WHERE u.USER_ID = m.USER_ID
"USER_ID"; "EMAIL"; "EMAIL_LC"; "FIRST_NAME";"LAST_NAME";"TYPE"; "PW";
"CREATEDBY"; "MODIFIEDBY"; "CREATEDON"; "MODIFIEDON"; "USER_ID"; "EID"
"00000000-62e7-425e-be28-12345678abcd";
"[email protected]"<mailto:[email protected]>;
"[email protected]"<mailto:[email protected]>; "Vi"; "Du"; "guest";
"pRCclQ==:KzTo0T9rfw45tgrsegfdCh/x3QJu/kragzJi4a8tCNk="; "admin"; "admin";
"2016-08-08 14:04:53"; "2017-07-29 03:46:08";
"00000000-62e7-425e-be28-12345678abcd"; "987854"
"00000000-54ae-418e-95ce-12345678abcd";
"[email protected]"<mailto:[email protected]>;
"[email protected]"<mailto:[email protected]>; "Bar"; "Than"; "guest";
"pfAqaw==:wx5Wc/M5msdfgdffsdffgf+mGPSSiFzs/omJF+wIFYU="; "admin"; "admin";
"2015-02-17 15:54:17"; "2017-07-29 03:44:55";
"00000000-54ae-418e-95ce-12345678abcd"; "987655"
"00000000-20e7-4905-b044-12345678abcd";
"[email protected]"<mailto:[email protected]>;
"[email protected]"<mailto:[email protected]>; "Joseph"; "Donovan"; "guest";
"psLZjA==:pNYul7adfadfadfasdfadssaPEIPTzrFLPdxC346gro=";
"00000000-f21d-4179-85e5-12345678abcd"; "00000000-20e7-4905-b044-12345678abcd";
"2013-04-01 14:05:11"; "2013-04-02 14:47:23";
"00000000-20e7-4905-b044-12345678abcd"; "987656"
"00000000-9e65-41ce-a434-12345678abcd";
"[email protected]"<mailto:[email protected]>;
"[email protected]"<mailto:[email protected]>; "Habibah"; "Assisi"; "guest";
"AvC7MQ==:2WCl8JQTasdfafeg452fgsgr45gsfsdg+XOMOUCLcfQ=";
"00000000-f21d-4179-85e5-12345678abcd"; "00000000-f21d-4179-85e5-12345678abcd";
"2013-08-26 19:42:24"; "2013-08-26 19:42:24";
"00000000-9e65-41ce-a434-12345678abcd"; "987657"
"00000000-f75c-42df-beaf-12345678abcd";
"[email protected]"<mailto:[email protected]>;
"[email protected]"<mailto:[email protected]>; "Keith"; "Roberts"; "guest";
"k/R8Mg==:vyM1Adfgsdfgsdget4563457tryeetyr1xSAHJXcqWk=";
"00000000-f21d-4179-85e5-12345678abcd"; "00000000-fe13-4bcc-84a7-12345678abcd";
"2015-03-30 22:34:04"; "2017-05-06 13:09:25";
"00000000-f75c-42df-beaf-12345678abcd"; "987658"
.......
/* Affected rows: 0 Found rows: 5,103 Warnings: 0 Duration for 1 query:
0.000 sec. (+ 0.125 sec. network) */
Yes, my MySQL is case insensitive.
SELECT *,m.EID FROM .....
and
SELECT *,m.eid FROM .....
both work the same.
Best Regards,
Sergio Muriel
________________________________
From: Matteo Alessandroni
<[email protected]><mailto:[email protected]>
Sent: Friday, September 15, 2017 10:45 AM
To: [email protected]<mailto:[email protected]>
Subject: Re: Scripted SQL Pull Task Error
Hi Sergio,
could you please add a little piece of the result of your query:
SELECT * FROM sakai_user u, sakai_user_id_map m WHERE u.USER_ID = m.USER_ID ...
from your "SakaiUserSearchScript.groovy" script?
Also please check that your mysql is case insensitive, otherwise ensure that
"it.eid" values are always set.
Regards,
Matteo
On 15/09/2017 17:17, Sergio Muriel wrote:
Hi Matteo,
please find the scripts attached to this email.
Thank you again!
Best Regards,
Sergio Muriel
________________________________
From: Matteo Alessandroni <[email protected]><mailto:[email protected]>
Sent: Friday, September 15, 2017 2:25 AM
To: [email protected]<mailto:[email protected]>
Subject:
Hi Sergio,
could please add the "SakaiUserSearchScript.groovy" too?
I need to see whether the "eid" field is set correctly and does always return a
value that will be mapped to "username".
Regards,
Matteo
On 2017-09-14 18:20, Sergio Muriel
<[email protected]><mailto:[email protected]> wrote:
> Hi Matteo,
>
> please find the screenshots attached to this email.
>
>
> Thank you in advance!
>
>
> PD: If is not pictured then values are by default.
>
> Best Regards,
> Sergio Muriel
>
>
> ________________________________
> From: Matteo Alessandroni
> <[email protected]><mailto:[email protected]>
> Sent: Thursday, September 14, 2017 2:23 AM
> To: [email protected]<mailto:[email protected]>
> Subject: Re: Scripted SQL Pull Task Error
>
> Hi Sergio,
>
> At this point could you please attach a screenshot of your mapping and also
> the Connector and Resource configuration?
>
> Regards,
> Matteo
>
> On 14/09/2017 00:02, Sergio Muriel wrote:
>
> Hi Matteo,
>
> * "username" is mapped in my resource. The "Purpose" column for
> "username" is set to the icon with both pull and push arrows. (That is Sync,
> I believe).
> * All users have a valid non blank username value. Indeed, I checked with
> a query, and it has been checked also by Sakai itself.
>
> So far I have the same problem. This is what the logs say:
>
> core-persistence.log shows this for each user creation attempt:
> 16:29:19.947 WARN
> org.apache.syncope.core.persistence.jpa.validation.entity.EntityValidationListener
> - Bean validation errors found:
> [ConstraintViolationImpl{rootBean=JPAUser[null], propertyPath='username',
> message='Blank username', leafBean=JPAUser[null], value=null}]
>
>
> core.log shows this for each user creation attempt:
> 16:26:28.884 ERROR
> org.apache.syncope.core.provisioning.api.pushpull.SyncopeResultHandler -
> Could not create USER f84440b0-3cc7-4d83-ae02-951c81faf2e22
> org.apache.syncope.core.persistence.api.attrvalue.validation.InvalidEntityException:
> JPAUser [Standard]
> at
> org.apache.syncope.core.persistence.jpa.validation.entity.EntityValidationListener.validate(EntityValidationListener.java:73)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at sun.reflect.GeneratedMethodAccessor517.invoke(Unknown Source) ~[?:?]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.apache.openjpa.event.BeanLifecycleCallbacks.makeCallback(BeanLifecycleCallbacks.java:85)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.persistence.PersistenceListenerAdapter.makeCallback(PersistenceListenerAdapter.java:71)
> ~[openjpa-persistence-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.persistence.PersistenceListenerAdapter.beforePersist(PersistenceListenerAdapter.java:85)
> ~[openjpa-persistence-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.event.LifecycleEventManager.fireEvent(LifecycleEventManager.java:404)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.event.LifecycleEventManager.fireEvent(LifecycleEventManager.java:308)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.kernel.BrokerImpl.fireLifecycleEvent(BrokerImpl.java:814)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.kernel.VersionAttachStrategy.attach(VersionAttachStrategy.java:140)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at org.apache.openjpa.kernel.AttachManager.attach(AttachManager.java:252)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at org.apache.openjpa.kernel.AttachManager.attach(AttachManager.java:105)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at org.apache.openjpa.kernel.BrokerImpl.attach(BrokerImpl.java:3508)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.kernel.DelegatingBroker.attach(DelegatingBroker.java:1213)
> ~[openjpa-kernel-2.4.2.jar:2.4.2]
> at
> org.apache.openjpa.persistence.EntityManagerImpl.merge(EntityManagerImpl.java:879)
> ~[openjpa-persistence-2.4.2.jar:2.4.2]
> at
> org.apache.syncope.core.persistence.jpa.dao.AbstractAnyDAO.save(AbstractAnyDAO.java:543)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.persistence.jpa.dao.JPAUserDAO.save(JPAUserDAO.java:437)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.persistence.jpa.dao.JPAUserDAO.save(JPAUserDAO.java:84)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at sun.reflect.GeneratedMethodAccessor527.invoke(Unknown Source) ~[?:?]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at com.sun.proxy.$Proxy85.save(Unknown Source) ~[?:?]
> at
> org.apache.syncope.core.workflow.java.DefaultUserWorkflowAdapter.doCreate(DefaultUserWorkflowAdapter.java:84)
> ~[syncope-core-workflow-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.workflow.java.AbstractUserWorkflowAdapter.create(AbstractUserWorkflowAdapter.java:91)
> ~[syncope-core-workflow-java-2.0.4.jar:2.0.4]
> at sun.reflect.GeneratedMethodAccessor524.invoke(Unknown Source) ~[?:?]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.apache.syncope.core.persistence.jpa.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at com.sun.proxy.$Proxy101.create(Unknown Source) ~[?:?]
> at
> org.apache.syncope.core.provisioning.java.DefaultUserProvisioningManager.create(DefaultUserProvisioningManager.java:101)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at sun.reflect.GeneratedMethodAccessor523.invoke(Unknown Source) ~[?:?]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.apache.syncope.core.persistence.jpa.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at com.sun.proxy.$Proxy109.create(Unknown Source) ~[?:?]
> at
> org.apache.syncope.core.provisioning.java.pushpull.UserPullResultHandlerImpl.doCreate(UserPullResultHandlerImpl.java:96)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.AbstractPullResultHandler.create(AbstractPullResultHandler.java:266)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.AbstractPullResultHandler.provision(AbstractPullResultHandler.java:231)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.AbstractPullResultHandler.doHandle(AbstractPullResultHandler.java:733)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.AbstractPullResultHandler.handle(AbstractPullResultHandler.java:130)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at sun.reflect.GeneratedMethodAccessor520.invoke(Unknown Source) ~[?:?]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.apache.syncope.core.persistence.jpa.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at com.sun.proxy.$Proxy292.handle(Unknown Source) ~[?:?]
> at
> org.apache.syncope.core.provisioning.java.ConnectorFacadeProxy$1.handle(ConnectorFacadeProxy.java:355)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.ConnectorFacadeProxy$2.handle(ConnectorFacadeProxy.java:448)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.identityconnectors.framework.impl.api.SearchResultsHandlerLoggingProxy.handle(SearchResultsHandlerLoggingProxy.java:64)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at
> org.identityconnectors.framework.impl.api.StreamHandlerUtil$ObjectStreamHandlerAdapter.handle(StreamHandlerUtil.java:101)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at
> org.identityconnectors.framework.impl.api.BufferedResultsProxy.invoke(BufferedResultsProxy.java:262)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at
> org.identityconnectors.framework.impl.api.DelegatingTimeoutProxy.invoke(DelegatingTimeoutProxy.java:94)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy294.search(Unknown Source) ~[?:?]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.identityconnectors.framework.impl.api.LoggingProxy.invoke(LoggingProxy.java:83)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy294.search(Unknown Source) ~[?:?]
> at
> org.identityconnectors.framework.impl.api.AbstractConnectorFacade.search(AbstractConnectorFacade.java:178)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at
> org.apache.syncope.core.provisioning.java.ConnectorFacadeProxy.search(ConnectorFacadeProxy.java:436)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.ConnectorFacadeProxy.filteredReconciliation(ConnectorFacadeProxy.java:350)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.ConnectorFacadeProxy.fullReconciliation(ConnectorFacadeProxy.java:339)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.PullJobDelegate.doExecuteProvisioning(PullJobDelegate.java:278)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.PullJobDelegate.doExecuteProvisioning(PullJobDelegate.java:60)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.pushpull.AbstractProvisioningJobDelegate.doExecute(AbstractProvisioningJobDelegate.java:558)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.job.AbstractSchedTaskJobDelegate.execute(AbstractSchedTaskJobDelegate.java:96)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
> ~[spring-tx-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.apache.syncope.core.persistence.jpa.spring.DomainTransactionInterceptor.invoke(DomainTransactionInterceptor.java:64)
> ~[syncope-core-persistence-jpa-2.0.4.jar:2.0.4]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at com.sun.proxy.$Proxy290.execute(Unknown Source) ~[?:?]
> at
> org.apache.syncope.core.provisioning.java.job.TaskJob$1.exec(TaskJob.java:80)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.job.TaskJob$1.exec(TaskJob.java:70)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.spring.security.AuthContextUtils.execWithAuthContext(AuthContextUtils.java:136)
> ~[syncope-core-spring-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.job.TaskJob.execute(TaskJob.java:69)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at org.quartz.core.JobRunShell.run(JobRunShell.java:202) ~[quartz-2.3.0.jar:?]
> at
> org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)
> ~[quartz-2.3.0.jar:?]
>
> enduser.log shows this from the beginning:
> 15:48:44.384 ERROR
> org.apache.syncope.client.enduser.init.ClassPathScanImplementationLookup -
> Could not find annotation
> org.apache.syncope.client.enduser.annotations.Resource in
> org.apache.syncope.client.enduser.resources.CaptchaResource, ignoring
>
> console.log shows this:
> 16:24:49.743 ERROR org.apache.wicket.protocol.ws.javax.WicketEndpoint - An
> error occurred in web socket connection with id : 1
> java.io.IOException: java.io.IOException: An established connection was
> aborted by the software in your host machine
> at
> org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:315)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:258)
> ~[tomcat-websocket.jar:8.5.16]
> at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:592)
> ~[tomcat-websocket.jar:8.5.16]
> at org.apache.tomcat.websocket.WsSession.onClose(WsSession.java:512)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.WsFrameBase.processDataControl(WsFrameBase.java:347)
> ~[tomcat-websocket.jar:8.5.16]
> at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:289)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:133)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:82)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:171)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:151)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:148)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:54)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:53)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1455)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
> ~[tomcat-coyote.jar:8.5.16]
> at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
> [?:1.8.0_71]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
> [?:1.8.0_71]
> at
> org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
> ~[tomcat-util.jar:8.5.16]
> at java.lang.Thread.run(Unknown Source) [?:1.8.0_71]
> Caused by: java.io.IOException: An established connection was aborted by the
> software in your host machine
> at sun.nio.ch.SocketDispatcher.write0(Native Method) ~[?:1.8.0_71]
> at sun.nio.ch.SocketDispatcher.write(Unknown Source) ~[?:1.8.0_71]
> at sun.nio.ch.IOUtil.writeFromNativeBuffer(Unknown Source) ~[?:1.8.0_71]
> at sun.nio.ch.IOUtil.write(Unknown Source) ~[?:1.8.0_71]
> at sun.nio.ch.SocketChannelImpl.write(Unknown Source) ~[?:1.8.0_71]
> at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.NioBlockingSelector.write(NioBlockingSelector.java:101)
> ~[tomcat-coyote.jar:8.5.16]
> at org.apache.tomcat.util.net.NioSelectorPool.write(NioSelectorPool.java:157)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.doWrite(NioEndpoint.java:1259)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.SocketWrapperBase.doWrite(SocketWrapperBase.java:670)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.SocketWrapperBase.flushBlocking(SocketWrapperBase.java:607)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.util.net.SocketWrapperBase.flush(SocketWrapperBase.java:597)
> ~[tomcat-coyote.jar:8.5.16]
> at
> org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:95)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:494)
> ~[tomcat-websocket.jar:8.5.16]
> at
> org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:309)
> ~[tomcat-websocket.jar:8.5.16]
> ... 19 more
>
>
> Finally, core-connid.log shows this once in a while:
> 16:15:08.888 DEBUG Exception: Method: schema
> java.lang.UnsupportedOperationException: SCHEMA script executor is null.
> Problem loading Schema script
> at
> net.tirasa.connid.bundles.db.scriptedsql.ScriptedSQLConnector.schema(ScriptedSQLConnector.java:356)
> ~[?:?]
> at
> org.identityconnectors.framework.impl.api.local.operations.SchemaImpl.schema(SchemaImpl.java:59)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.identityconnectors.framework.impl.api.local.operations.ConnectorAPIOperationRunnerProxy.invoke(ConnectorAPIOperationRunnerProxy.java:98)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy278.schema(Unknown Source) ~[?:?]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.identityconnectors.framework.impl.api.local.operations.ThreadClassLoaderManagerProxy.invoke(ThreadClassLoaderManagerProxy.java:96)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy278.schema(Unknown Source) ~[?:?]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.identityconnectors.framework.impl.api.DelegatingTimeoutProxy.invoke(DelegatingTimeoutProxy.java:99)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy278.schema(Unknown Source) ~[?:?]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_71]
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_71]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> ~[?:1.8.0_71]
> at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_71]
> at
> org.identityconnectors.framework.impl.api.LoggingProxy.invoke(LoggingProxy.java:83)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at com.sun.proxy.$Proxy278.schema(Unknown Source) ~[?:?]
> at
> org.identityconnectors.framework.impl.api.AbstractConnectorFacade.schema(AbstractConnectorFacade.java:145)
> ~[connector-framework-internal-1.4.2.0.jar:?]
> at
> org.apache.syncope.core.provisioning.java.AsyncConnectorFacade.getObjectClassInfo(AsyncConnectorFacade.java:112)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at
> org.apache.syncope.core.provisioning.java.AsyncConnectorFacade$$FastClassBySpringCGLIB$$886ae36a.invoke(<generated>)
> ~[syncope-core-provisioning-java-2.0.4.jar:2.0.4]
> at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
> ~[spring-core-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:738)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at
> org.springframework.aop.interceptor.AsyncExecutionInterceptor$1.call(AsyncExecutionInterceptor.java:115)
> ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]
> at java.util.concurrent.FutureTask.run(Unknown Source) ~[?:1.8.0_71]
> at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
> [?:1.8.0_71]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
> [?:1.8.0_71]
> at java.lang.Thread.run(Unknown Source) [?:1.8.0_71]
>
>
>
> Help is very appreciated!
>
>
> Best Regards,
> Sergio Muriel
>
>
> ________________________________
> From: Matteo Alessandroni
> <[email protected]><mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>
> Sent: Wednesday, September 13, 2017 4:23 AM
> To:
> [email protected]<mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>
> Subject: Re: Scripted SQL Pull Task Error
>
> Hi Sergio,
>
> There could be 2 possibilities for that error:
> - there is no mapping for "username" in your resource "Edit Provision Rules"
> section or there is an incorrect mapping (e.g. "Purpose" column for
> "username" is set not to handle synchronization);
> - one or more users in your external resource do not have a "username" value
> (it is blank) and Syncope requires it.
> Please check those things and let me know.
>
> Regards,
> Matteo
>
> On 2017-09-13 02:53, Sergio Muriel
> <[email protected]><mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>
> wrote:
> > Hi everyone,
> >
> > following the advise from Francesco I decided to connect to my Sakai LMS
> > instance starting from the given scripts at
> >
> > https://github.com/Tirasa/ConnIdDBBundle/tree/master/scriptedsql/src/main/resources/samples
[https://avatars2.githubusercontent.com/u/1718149?v=4&s=400]<https://github.com/Tirasa/ConnIdDBBundle/tree/master/scriptedsql/src/main/resources/samples>
Tirasa/ConnIdDBBundle<https://github.com/Tirasa/ConnIdDBBundle/tree/master/scriptedsql/src/main/resources/samples>
github.com
ConnIdDBBundle - ConnId: DB bundle
>
> >
> >
> > I'm trying to pull the users from there, so I customized both the Sync and
> > Search scripts (because the user info is not in a single table). I run the
> > pull task and I can see the running task icon spinning for several minutes
> > (Dashboard, control tab); however, when it stops spinning I get no new
> > users but a message like this for each user in my core-persistence.log:
> >
> >
> > 18:43:19.304 WARN
> > org.apache.syncope.core.persistence.jpa.validation.entity.EntityValidationListener
> > - Bean validation errors found:
> > [ConstraintViolationImpl{rootBean=JPAUser[null], propertyPath='username',
> > message='Blank username', leafBean=JPAUser[null], value=null}]
> >
> >
> > What I find weird, is that I do see that most of the users have username
> > attribute (in core-connid.log), like this one:
> >
> >
> > 18:43:13.858 DEBUG Enter: {Uid=Attribute: {Name=__UID__,
> > Value=[5165468435165165165165]}, ObjectClass=ObjectClass: __ACCOUNT__,
> > Attributes=[Attribute: {Name=lastname, Value=[Register]}, Attribute:
> > {Name=username,
> > Value=[[email protected]<mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>]},
> > Attribute: {Name=__NAME__,
> > Value=[[email protected]<mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>]},
> > Attribute: {Name=firstname, Value=[Scott]}, Attribute: {Name=__UID__,
> > Value=[5165468435165165165165]}, Attribute: {Name=email,
> > Value=[[email protected]<mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>]}],
> > Name=Attribute: {Name=__NAME__,
> > Value=[[email protected]<mailto:[email protected]><mailto:[email protected]><mailto:[email protected]>]}}
> > Method: handle
> >
> > It should at least load the ones that are correct. Am I right?
> >
> >
> > Thank you for the help!
> >
> > Best Regards,
> > Sergio Muriel
> >
>
>
--
Dott. Marco Di Sabatino Di Diodoro
Tel. +39 3939065570
Tirasa S.r.l.
Viale D'Annunzio 267 - 65127 Pescara
Tel +39 0859116307 / FAX +39 0859111173
http://www.tirasa.net
Apache Syncope PMC Member
http://people.apache.org/~mdisabatino/<http://people.apache.org/%7Emdisabatino/>
--
Dott. Marco Di Sabatino Di Diodoro
Tel. +39 3939065570
Tirasa S.r.l.
Viale D'Annunzio 267 - 65127 Pescara
Tel +39 0859116307 / FAX +39 0859111173
http://www.tirasa.net
Apache Syncope PMC Member
http://people.apache.org/~mdisabatino/