Hi Darshana,

I have found a way.

setUserMember(String id, String displayName) works fine.

setUserMember(String id) also do the job but it fails during json decoding.

Anyway thanks for looking into this.

Thanks,
Gayan




On Wed, Jul 16, 2014 at 1:28 AM, Darshana Gunawardana <[email protected]>
wrote:

> Hi Gayan,
>
> Have you found the way to do $subject?
>
> AFAIK, this functionality does not supported. If you have to add user to
> some group using scim,
> * Either you have to include that user while creating the group
> * Or you have to update role list of user.
>
> Thanks,
> Darshana
>
>
>
> On Mon, Jul 14, 2014 at 11:45 AM, Gayan Gunawardana <[email protected]>
> wrote:
>
>> Hi Ishara,
>>
>> While writing integration test for patch operation I wanted to modify
>> user list of a group. I have tried following method
>>
>> setMember(String id)
>>
>> setUserMember(String id)
>>
>> setGroupMember(String id)
>>
>> but it gives
>>
>> org.apache.wink.client.ClientRuntimeException:
>> org.wso2.charon.core.exceptions.AbstractCharonException
>>     at
>> org.apache.wink.client.internal.ResourceImpl.invoke(ResourceImpl.java:240)
>>     at
>> org.apache.wink.client.internal.ResourceImpl.invoke(ResourceImpl.java:189)
>>     at
>> org.apache.wink.client.internal.ResourceImpl.put(ResourceImpl.java:326)
>>     at
>> org.wso2.carbon.identity.tests.scim.SCIMServiceProviderGroupTestCase.updateGroup(SCIMServiceProviderGroupTestCase.java:208)
>> Caused by: org.wso2.charon.core.exceptions.AbstractCharonException
>>     at
>> org.wso2.charon.core.encoder.json.JSONDecoder.decodeException(JSONDecoder.java:153)
>>     at
>> org.wso2.charon.core.client.SCIMClient.decodeSCIMException(SCIMClient.java:219)
>>     at
>> org.wso2.carbon.identity.tests.scim.utils.SCIMResponseHandler.handle(SCIMResponseHandler.java:51)
>>     at
>> org.apache.wink.client.internal.handlers.HandlerContextImpl.doChain(HandlerContextImpl.java:52)
>>     at
>> org.apache.wink.client.internal.ResourceImpl.invoke(ResourceImpl.java:227)
>>     ... 36 more
>>
>> seems like after modifying user list of a group, json decoder fails some
>> where. This does not happen for updating group name only.
>>
>> Can you point the correct method to add new user member to a group from
>> id ?  (org.wso2.charon.core.objects.Group).
>>
>>
>>
>> --
>> Gayan Gunawardana
>> Software Engineer; WSO2 Inc.; http://wso2.com/
>> Email: [email protected]
>> Mobile: +94 (71) 8020933
>>
>> _______________________________________________
>> Dev mailing list
>> [email protected]
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Regards,
>
>
> *Darshana Gunawardana *Software Engineer
> WSO2 Inc.; http://wso2.com
>
> * E-mail: [email protected] <[email protected]>*
> *Mobile: +94718566859 <%2B94718566859>*Lean . Enterprise . Middleware
>



-- 
Gayan Gunawardana
Software Engineer; WSO2 Inc.; http://wso2.com/
Email: [email protected]
Mobile: +94 (71) 8020933
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to