• Post Reply Bookmark Topic Watch Topic
  • New Topic

Reflection in Webservice ?`Beginner's question  RSS feed

 
Ken Tokuhamaru
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello !

I have a basic question regarding Webservices, you can shed some light on this for me.

Is it possible to have a Class A exposed as a Webservice like that ?


Is this a viable way to use reflection in Webservices, is it possible to serialize the proxy object this way ?
Well the intention is to model a distributed Object with Webservices, with the use of a proxyInstance. Are there any other solutions if I want to achieve this goal ? My understanding of Webservices is that it allows some kind of stateless method invocation on the basis of XML etc. How would a stateful Webservice look like ?


My 2nd question is: What if my Webservice method look like this:


Is this possible ? Well I guess It's not since Class is a Java construct which cannot be mapped to WSDL ?

Well I am quite confused

Thanks alot

Ken

 
Ken Tokuhamaru
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can someone confirm if my solution is possible, please ? Unfortunatly I cannot cornfirm it myself yet. I am thankful for any answer.

Best regards,

Ken
 
Jimmy Clark
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A "web service" is an integration technology. It is not for implementation. A web services connects applications.

Example: Application A, B, C use a web service to connect to Application X.

The purpose of the web service in this example is to allow applications to connect to something that application X does or has.

If you want to explore alternatives to "web services" for distributed computing, you can explore Java's Remote Method Invocation API.

Good luck!
 
Ken Tokuhamaru
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

A "web service" is an integration technology. It is not for implementation. A web services connects applications.

Example: Application A, B, C use a web service to connect to Application X.

The purpose of the web service in this example is to allow applications to connect to something that application X does or has.

If you want to explore alternatives to "web services" for distributed computing, you can explore Java's Remote Method Invocation API.

Good luck!


Thank you for the quick answer.

Yes I know, it's quite a misuse to use "Webservices" as such. But if my goal is intended to provide this kind of integration, and distributed technologies such like EJB, or RMI is not available( because it depends on Java, and I need it to be platform independant). Is this technically possible ? I just mean technically...

The goal is to have say :

Application A, with Webservices W1,W2,W3 with which other applications can connect to and can compute something. The result type of W1,W2,W3 would be just proxyObject of the serverside Object. Wouldn't it be possible to have this proxyObject call a Webservice W of the Application to invoke the methods of the real instance of it ? Hmm ... I can see now that this proxyObject would implicitly call the Webservice W. Thus it's my question if all this is a technical feasible scenario.

I know that I could just have used EJB (stateful beans) or RMI, to implement this scenario, but I unfortunatly cannot by requirements.

 
Ken Tokuhamaru
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well , if I you think that I am confused with something , can you point out at which point my logic is broken ?

I will appreaciated this alot. Thank you.
 
Jimmy Clark
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Application A, with Webservices W1,W2,W3 with which other applications can connect to and can compute something.


You can create a set of web services that connect to application A to either retrieve data or compute something.


If you want to implement these web services, using standard mechanisms and APIs, then you should forget about your ideas of "proxy object", reflection, etc.


If you are looking for a "new" way to implement what a "web service" does, with your own design and code, this is fine.


Keep in mind that Java's Remote Method Invocation API works with "proxy objects" and reflection, so you are not contemplating something that does not exist already. As to the question if it is technically feasible, visit the web pages for Java's Remote Method Invocation API.

RMI server's are free. No charge
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!