aspose file tools*
The moose likes Web Services and the fly likes Web Service without any framework Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Web Service without any framework" Watch "Web Service without any framework" New topic
Author

Web Service without any framework

Arslan Khan
Greenhorn

Joined: Jul 29, 2009
Posts: 18

Hello,

I want to know whether we can create a web service without using any framework? If yes, please guide me on how to do it.

Regards.


If you can't make it good, at least make it look good.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61651
    
  67

Sure you can write all the code yourself in Java. After all that's what the frameworks do. But why would you re-invent the wheel?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Arslan Khan
Greenhorn

Joined: Jul 29, 2009
Posts: 18

I've tried a simple example with Apache Axis in Eclipse, but I understand nothing as Eclipse generated all the stuff. Thats why I want to do it manually to understand the details.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61651
    
  67

Are you confusing "framework" with "IDE"?
Arslan Khan
Greenhorn

Joined: Jul 29, 2009
Posts: 18

Nope. I am not confusing IDE and framework. Let me explain, I want to create a simple web service without using Axis, CXF or any other such framework. This way I will be able to see the details of how a web service actually looks and works.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42611
    
  65
It's not hard for a RESTful WS, but SOAP is quite involved - implementing that would be a major undertaking (and more likely than not to be unsuccessful in the end). What do you hope to learn by doing that?

I'd advise to use Axis2, but forgo the IDE. That way you'll get a good understanding of how SOAP and WSDL look like and how they work together. You can also use a tool like SoapUI to monitor SOAP traffic in transit.


Ping & DNS - my free Android networking tools app
Arslan Khan
Greenhorn

Joined: Jul 29, 2009
Posts: 18

Thanks Ulf. I want to know the differences between Axis and Axis2. Can you suggest some good tutorial on Axis2?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42611
    
  65
Axis 1 is obsolete; don't bother investigating it.

The Axis site has many tutorials including Installation Guide, QuickStart Guide and User Guide. Also check out the wiki http://wiki.apache.org/ws/FrontPage/Axis.
Arslan Khan
Greenhorn

Joined: Jul 29, 2009
Posts: 18

Thank you Ulf for such quick response. I will try your suggestion.
Ulli Hertlein
Greenhorn

Joined: Jan 13, 2011
Posts: 15

Arslan Khan wrote:Nope. I am not confusing IDE and framework. Let me explain, I want to create a simple web service without using Axis, CXF or any other such framework. This way I will be able to see the details of how a web service actually looks and works.


imho it is quite confusing to spot which steps in JAX-WS development (mostly deployment) is done by which component (IDE (Appserver plugin), Jax-WS Framework (Axis, Metro) or Java/Jax-WS Tools (apt, wsgen etc.).
another problem is to find out, which artefacts are required (e.g. webservice.xml and wsdl are both not always required - as running the jax-ws RI examples show).

imho the lowest possible approach for developing (learning) WS is the following:
  • download and install ant (for commandline usage)
  • download and install JAX-WS RI
  • download and install tomcat
  • install (deploy jars) JAX-WS RI into tomcat
  • run the provided examples which are included in JAX-WS RI (commandline ant)


  • hope it helps


    Professional Senior Crap Manager & doing Livestrong
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: Web Service without any framework