Skip to main content

Issues getting Fast Infoset working

3 replies [Last post]
jodeen
Offline
Joined: 2007-02-07
Points: 0

I'm having some issues getting Fast Infoset working in general. I'm assuming that there's something simple missing.

Everything I've found on the web implies that setting up FI should be as simple as setting a property on my client-side stub (http://www.j2ee.me/webservices/docs/2.0/jaxrpc/fastinfoset/manual.html). But that doesn't seem to be working. When I use wsmonitor to look at the messages being sent, the requests don't have the application/fastinfoset in the HTTP accept header.

Is there something that I'm missing?
I'm running 1.6.0_07 for both the client and server. The web-service is deployed on glassfish v2ur2.

Here's my client-side code:
try { // Call Web Service Operation
fiweb.EchoService service = new fiweb.EchoService();
fiweb.Echo port = service.getEchoPort();
((BindingProvider) port).getRequestContext().put("com.sun.xml.ws.client.ContentNegotiation", "pessimistic");
java.lang.String message = "barr";
java.lang.String result = port.echo(message);
System.out.println("Result = " + result);
result = port.echo(message);
System.out.println("Result = " + result);

} catch (Exception ex) {
ex.printStackTrace();
}

And the server side code is just as simple:
@WebService()
public class Echo {

/**
* Web service operation
*/
@WebMethod(operationName = "echo")
public String echo(@WebParam(name = "message") String message) {
System.out.println("Recieved: " + message);
return "Recieved:" + message;
}
}

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
peppeme
Offline
Joined: 2007-05-30
Points: 0

I have the same problem..
Anyone, please?!

oleksiys
Offline
Joined: 2006-01-25
Points: 0

Can you pls. try to set "optimistic" mode, to check if it will make any difference?

peppeme
Offline
Joined: 2007-05-30
Points: 0

Now It works.
maybe the jax-ws library import.
Before I import it the webservice client works fine but infoset doesn't work.
When I import the jars from jax-ws 2.1 netbeans library it works.

I'm verifying deeply this.