grouper-users - RE: [grouper-users] WS getAttributeAssignments for imm_mem and multiple owner lookups
Subject: Grouper Users - Open Discussion List
List archive
RE: [grouper-users] WS getAttributeAssignments for imm_mem and multiple owner lookups
Chronological Thread
- From: Chris Hyzer <>
- To: Scott Koranda <>, grouper-users <>
- Subject: RE: [grouper-users] WS getAttributeAssignments for imm_mem and multiple owner lookups
- Date: Mon, 1 Oct 2012 02:06:39 +0000
- Accept-language: en-US
To check the syntax, I did this:
/**
* @param args
*/
public static void main(String[] args) {
WsRestGetAttributeAssignmentsRequest wsRestGetAttributeAssignmentsRequest
= new WsRestGetAttributeAssignmentsRequest();
wsRestGetAttributeAssignmentsRequest.setWsOwnerMembershipLookups(new
WsMembershipLookup[] {
new WsMembershipLookup("uuid1"), new WsMembershipLookup("uuid2")
});
System.out.println(GrouperUtil.indent(GrouperUtil.jsonConvertTo(wsRestGetAttributeAssignmentsRequest),
false));
}
But I got a similar result to what you had:
{
"WsRestGetAttributeAssignmentsRequest":{
"wsOwnerMembershipLookups":[
{
"uuid":"uuid1"
},
{
"uuid":"uuid2"
}
]
}
}
So I will have to try this out and see if there is some other issue...
Thanks,
Chris
-----Original Message-----
From:
[mailto:]
On Behalf Of Scott Koranda
Sent: Sunday, September 30, 2012 5:22 PM
To: grouper-users
Subject: [grouper-users] WS getAttributeAssignments for imm_mem and multiple
owner lookups
Hi,
I am using Grouper 2.1.2.
If I send in this JSON to the attributeAssignments RESTful
endpoint it works and I receive a list of attribute
assignments on the immediate membership:
{
"WsRestGetAttributeAssignmentsRequest":{
"actAsSubjectId":"GrouperSystem",
"attributeAssignType":"imm_mem",
"includeAssignmentsOnAssignments":"F",
"includeGroupDetail":"T",
"wsOwnerMembershipLookups" :[
{
"uuid":"cdcff16d8d8f4148ae8b7a2a8a87c010:0bb468654e91405c9b1461873e44d20c"
}
]
}
}
But if I send in this JSON, which includes multiple membership
uuids, it fails:
{
"WsRestGetAttributeAssignmentsRequest":{
"actAsSubjectId":"GrouperSystem",
"attributeAssignType":"imm_mem",
"includeAssignmentsOnAssignments":"F",
"includeGroupDetail":"T",
"wsOwnerMembershipLookups" :[
{
"uuid":"cdcff16d8d8f4148ae8b7a2a8a87c010:0bb468654e91405c9b1461873e44d20c"
},
{
"uuid":"4ea839c8b5ed4a519cbef121e39ec9e5:70c42e30bfe34638a60fcf522659f4a2"
}
]
}
}
When it fails I receive this:
{
"WsGetAttributeAssignmentsResults": {
"responseMetadata": {
"millis": "106",
"serverVersion": "2.1.2"
},
"resultMetadata": {
"resultCode": "INVALID_QUERY",
"resultMessage": "Membership calls can only have
membership owner lookups. clientVersion: 2.1.0,
attributeAssignType: imm_mem, wsAttributeDefLookups: null,
wsAttributeAssignLookups: null, wsAttributeDefNameLookups:
null, wsOwnerStemLookups: null, wsOwnerGroupLookups: null,
wsOwnerMembershipLookups: Array size: 2: [0]:
WsMembershipLookup[uuid=cdcff16d8d8f4148ae8b7a2a8a87c010:0bb468654e91405c9b1461873e44d20c]\n[1]:
WsMembershipLookup[uuid=4ea839c8b5ed4a519cbef121e39ec9e5:70c42e30bfe34638a60fcf52...,
wsOwnerMembershipAnyLookups: null, wsOwnerAttributeDefLookups:
null, actions: null, includeSubjectDetail: false,
actAsSubject: null, subjectAttributeNames: null\n, paramNames:
\n, params: null\n, wsOwnerSubjectLookups: null, enabled:
null, attributeDefValueType: null, theValue: null,
includeAssignmentsFromAssignments: false, attributeDefType:
null, wsAssignAssignOwnerAttributeAssignLookups: null,
wsAssignAssignOwnerAttributeDefLookups: null,
wsAssignAssignOwnerAttributeDefNameLookups: null,
wsAssignAssignOwnerActions: null",
"success": "F"
}
}
}
The documentation at
https://spaces.internet2.edu/display/Grouper/Get+Attribute+Assignments
says "Accepts multiple groups or subjects or memberhipIds (or
combination) etc to retrieve lists of attribute assignments".
That statement led me to think that I could send in multiple
immediate membership uuids.
What have I done wrong?
Thanks,
Scott
- [grouper-users] WS getAttributeAssignments for imm_mem and multiple owner lookups, Scott Koranda, 09/30/2012
- RE: [grouper-users] WS getAttributeAssignments for imm_mem and multiple owner lookups, Chris Hyzer, 09/30/2012
Archive powered by MHonArc 2.6.16.