• Post Reply Bookmark Topic Watch Topic
  • New Topic

Calling a web service operation from JSP

 
Alex Parvan
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can call a WS operation using "useBean" but what if they are not on the same server ?

And i'm more interested in sending object, because i'm using JAXB in the Web Service.

Thanks,
Alex
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is "they" - both ends of the WS call? It's the hallmark of WS that they run on a remote server; if caller and callee run on the same server then there are probably more efficient ways of communication than a WS call.
 
Alex Parvan
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I meant if the website (with the JSP pages) are on one machine, and the WS is on another machine.

Thanks for your reply.
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This kind of thing shouldn't be done in a JSP, it should be done in Java code that's part of a backing bean or a servlet. At that point it's the same as if you were writing a desktop app that calls a WS.
 
Alex Parvan
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Aha, that makes sense, thanks for your help.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!