Skip to Content.
Sympa Menu

grouper-users - RE: [grouper-users] Query on Response From Web Services Call

Subject: Grouper Users - Open Discussion List

List archive

RE: [grouper-users] Query on Response From Web Services Call


Chronological Thread 
  • From: Chris Hyzer <>
  • To: "Mailvaganam, Hari" <>, Lichten Stein <>, "" <>
  • Subject: RE: [grouper-users] Query on Response From Web Services Call
  • Date: Sat, 15 May 2010 14:49:12 -0400
  • Accept-language: en-US
  • Acceptlanguage: en-US

Hari is right. Here is an example of getting the result code from the object
model:

System.out.println("Result code: " +
wsHasMemberResults.getResultMetadata().getResultCode());
System.out.println("Result message: " +
wsHasMemberResults.getResultMetadata().getResultMessage());

You can look around in those objects to find what you need. The objects
correspond to the XML. E.g. here:

http://anonsvn.internet2.edu/cgi-bin/viewvc.cgi/i2mi/trunk/grouper-ws/grouper-ws/doc/samples/hasMember/WsSampleHasMember_soap.txt?revision=6127&view=co

If your web services server is running SSL, then you cannot run the eclipse
tcp/ip monitor. If your server is not SSL, then you can run the eclipse TCP
monitor. Just set a local port not in use, monitor the server name and port,
and change the Grouper client to connect to the local port instead of remote.
Once you get that working, you can take a request or response, copy and
paste into temp.xml in eclipse (some file with xml extension), right click on
the contents and do source->format. Then you will see what is going back and
forth.

Btw, if you are coding from Java I think the grouperClient (with Rest) is the
easiest way to go...

Good luck!
Chris

-----Original Message-----
From: Mailvaganam, Hari
[mailto:]

Sent: Saturday, May 15, 2010 12:54 PM
To: Lichten Stein;

Subject: RE: [grouper-users] Query on Response From Web Services Call

Hi Matt:

I have not previously experimented with the Grouper WS java generated classes
you are using; having said that, I believe you need to parse the SOAP object
(the output forwarded is probably a string representation of the object).

regards,

Hari
________________________________________
From: Lichten Stein
[]
Sent: Friday, May 14, 2010 11:36 PM
To:

Subject: Re: [grouper-users] Query on Response From Web Services Call

Hi Chris:

Thank you for your email.

>>>Are you using the java generated soap client classes?
Yes I am (I recognize your name from the code, I am honored)

>>>Are you just printing out the objects with toString()?
Yes - I was using the example code - the output is coming from:
System.out.println(ToStringBuilder.reflectionToString(wsHasMemberLiteResult));
is there something else I should do?

>>>Can you run a tcp monitor (like the one built in to eclipse)
I could not get Eclipse TCP/IP monitor to work - not sure if it because the
Grouper is on a remote Linux server and the Web Services client is on my PC.

Cheers,

Matt


On Fri, May 14, 2010 at 10:29 PM, Chris Hyzer
<<mailto:>>
wrote:
It looks like you are doing SOAP. Are you using the java generated soap
client classes? (looks like it)

Are you just printing out the objects with toString()? It might not be
printing all fields, though the data might be there.

Can you run a tcp monitor (like the one built in to eclipse) and capture the
XML going back and forth (or the grouper client does this if you set
-debug=true, though that is Rest)

Thanks,
Chris


From: Lichten Stein
[mailto:<mailto:>]
Sent: Saturday, May 15, 2010 1:22 AM
To:
<mailto:>
Subject: [grouper-users] Query on Response From Web Services Call

Hello,

I have successfully installed Grouper 1.5 on a Lnux box - I have populated
with sample members/groups.

I am trying to test the Web Services call - I downloaded the sample and
started with WsSampleHasMemberLite.

Running the WsSampleHasMemberLite class returned the output listed below.

I was expecting the 'Response Code' given in the documentation - I'm not too
sure what to make out of the output below. Can anyone help give me a prod in
the correct direction?

edu.internet2.middleware.grouper.webservicesClient.GrouperServiceStub$WsHasMemberLiteResult@186c6b2[localResponseMetadata=
edu.internet2.middleware.grouper.webservicesClient.GrouperServiceStub$WsResponseMeta@1bca5f1,localResponseMetadataTracker=true,
localResultMetadata=edu.internet2.middleware.grouper.webservicesClient.GrouperServiceStub$WsResultMeta@329f3d,
localResultMetadataTracker=true,localResults={<null>},localResultsTracker=true,localSubjectAttributeNames{<null>},
localSubjectAttributeNamesTracker=true,localWsGroup=<null>,localWsGroupTracker=true,localWsSubject=<null>,localWsSubjectTracker=true]


Cheers,

Matt





Archive powered by MHonArc 2.6.16.

Top of Page