Jump to content

Talk:Web service

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Please Stop Associating "Web Service" Exclusively With XML+SOAP

[edit]

The intro of this page and the second section are inconsistent. Intro: A web service is any API published to the web, using web protocols. 2nd section: web service is SOAP+XML. I know the WWW XML WG tried to claim "web service" as specifically implying SOAP but it's far too general a term to try and make an exclusive claim to. All they've done is confuse everyone. We should ignore them or clarify "SOAP web service" .

Old discussion

[edit]

I don't see how the new images (derived from the one at the top) add anything. Furthermore, they really don't make much sense (this isn't XML-RPC, and they don't relate to points in the text). Unless someone disagrees, I'll remove them. mnot 02:21, 1 September 2006 (UTC)[reply]

Removed. mnot 14:38, 21 September 2006 (UTC)[reply]

Puting back a image: yes, two is a lot. Only one is ok for didatic. "RPC is a very popular usage of the web-service architecture, but is ONLY PART of the full architecture, and the image leaves it clearly". -- Krauss 25/sep/06


Isn't it so that information about three styles of use is a bit outdated? Wikipesia's article "Service-oriented architecture" states: Though many definitions of SOA limit themselves to technology or just Web Services, this is predominantly pushed by technology vendors; in 2003 they talked just of Web Services, while in 2006 the talk is of events and process engines.

It seems that SOA has overgrown its infancy and became to be a powerful paradigm: http://today.java.net/pub/a/today/2006/04/04/understanding-service-oriented-architecture.html Sciagent 08:35, 21 September 2006 (UTC)[reply]

--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)== Please explain or link where it says "the PUT, GET and DELETE HTTP methods, alongside POST," == --121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)--121.28.69.70 (talk) 04:51, 20 June 2011 (UTC)[reply]

Additional 'external link' for Web Services page.

[edit]

I'd like to recommend the following resource links be added to the Web Services article under External Links:

Tohagan 00:20, 6 November 2006 (UTC)[reply]

Simon sprott 14:18, 2 October 2007 (UTC)[reply]

Mzaremba (talk) 14:06, 13 December 2007 (UTC)[reply]

  • The most comprehensive collection of public Web Services (18K) is available through seekda (XMethods, whose link is in the current article indexes just a fraction of known public Web Services).

Most important for people who are going to plan a webservice implementation, please read this before:

Maybe this can be an external link as well?

More non-technical detail

[edit]

Could someone talk about the uses of Web services? Looking for technical examples and business examples. Why would a business look to utilize Web services?

Thanks.

76.187.219.94 15:20, 12 November 2006 (UTC)[reply]

I concur. How and for what is all this used in real life? (As real as it can get...) Some examples if you please. Wipe (talk) 02:06, 19 April 2008 (UTC)[reply]

there are many uses of webservices but the two best uses are:- 1)They are mostly used for efficient binary encodings as an alternative to textual XML representations.2)WEBSERVICE is used to solve immediate tactical problems. Anoopnair2050 (talk) 13:16, 23 July 2008 (UTC)[reply]

Excuse me but, what on earth do these 2 sentences mean ??? 194.250.5.173 (talk) 09:06, 20 June 2016 (UTC)[reply]

Yes, I have added a practical example shading light on why we need web service, what is web-service, and also reasons and explanations of each concept such as WSDL, UDDI, XSD, SOAP etc. I have written all of explanations under "Explanation" section. Hope this helps common people understand whole concept and reasoning behind Web Service. Rahulajani (talk) 06:09, 11 March 2014 (UTC)[reply]

REST: Stateful or stateless (or both)?

[edit]

In the Principles section of the REST –article we read: -A protocol that is:

  • Client/Server
  • Stateless
  • Cacheable
  • Layered

From Web_service#Styles of use: -Here, the focus is on interacting with stateful resources, rather than messages or operations.

Can someone explain? --84.48.33.95 09:08, 2 December 2006 (UTC)[reply]

Obsolete comment now. That text and link is not there. The complaint's root is the ambiguity of web services and W3C Web Services. — Preceding unsigned comment added by Rick Jelliffe (talkcontribs) 01:33, 3 May 2018 (UTC)[reply]

RPC

[edit]

There's some confusion in this article about Wire formats versus client APIs. There is a form of SOAP encoding called RPC/enc which predates XML schema (XSD), and was designed to allow you to marshall a graph of of native objects in a SOAP call. It is this that is discredited in WS-I, and somewhat deprecated in the current Java/C# SOAP stacks. Why? Because it was a nighmare of interoperability grief.

There is also Remote Procedure Calls as a paradigm for client side invocation of web services, and that is very much with us. It is certainly intrinsic to Sun's Web Services APIs in Java, originally called [JAX-RPC] (Java XML API for RPC) and now called JAX-WS, Java XML API for web services). This is not deprecated by the main stream vendors, although I have argued very much that it should be :

cite: Loughran S. and Smith E., Rethinking the Java SOAP stack, proceedings IEEE International Conference of Web Services 2005, http://www.hpl.hp.com/techreports/2005/HPL-2005-83.html

I'm not going to edit the entry as I'm clearly biased, but I think that the article needs to explain about rpc/enc versus doc/lit and "wrapped" messages, separately from the actual programming model used client-side to make calls on a remote service. SteveLoughran 16:57, 25 January 2007 (UTC)[reply]

No, if it does not use URLs, it is not a web technology, and is not a web service as such. So RPCs should not be mentioned.Rick Jelliffe (talk) 01:35, 3 May 2018 (UTC)[reply]

Performance

[edit]

There is a new criticism over XML as being slow for use of XML and SOAP envelope/HTTP transport. Are there any recent citations for this? The sole one that I am aware of is [[1]], which would do as a first citation. SteveLoughran 20:53, 31 January 2007 (UTC)[reply]

Obsolete. This has been taken over by events, with SOAP-based W3C XMl Services on the decline, while AJAX (especially using JSON) is on the ascent. Rick Jelliffe (talk) 01:35, 3 May 2018 (UTC)[reply]

Scope of the term "Web service"

[edit]

The introduction cites the W3C and lets it sound like the W3C definition is very broad about the usage of the term Web Service and only public perception and other standards like WS-I are narrowing it to WSDL/SOAP. This is actually not true, the complete cite from the W3C WS Glossary explicitely names WSDL and SOAP. The introduction should be reformulated to avoid this impression. Zefiro 15:34, 20 February 2007 (UTC)[reply]

The definition (W3C What is a Web service) is poor, since it "defines" in one sentence and then clarifies in the others that it should utilize WSDL and SOAP. It also states that a web service does not require HTTP or XML. I'm also not sure how well-defined "Web-related standards" is. It should instead be worded to say what the objective of a Web Service ("a software system designed to support interoperable machine-to-machine interaction over a network") and then define it by how it accomplishes this objective by using WSDL, XML, SOAP, HTTP, etc. 199.94.94.21 12:59, 11 May 2007 (UTC)[reply]

The editors of this article need to make a choice. If the editors are going to insist that this page is about Web Services as defined by the W3C quote in the first sentence (e.g. W3C What is a Web service), then Wikipedia is missing an article on what are referred to as Web APIs or Web Services. If the editors decide that Web Services is an inclusive term, then the intro sentence should be replaced and there should be a page on SOAP/WSDL Web Services (if there isn't already). (Also, if the second choice, the technical level of this article is too high.) I would propose that neither answer is completely correct, but that either choice is better than the current state of things (esp. since Wikipedia is missing a layman's explanation of Web APIs and how they differ from web pages). Boyprose (talk) 00:10, 17 September 2009 (UTC)[reply]

I agree. Boyprose, anyone and everyone is the "editor" of an article! :-) So in revision 620424688 I tried to solve the general/specific problem by splitting the Web Services Architecture's definition quotation into general and the WSA-specific version. I think this helps, we'll see if it survives. My editorializing that few web services actually implement the WSA definition needs a citation. Perhaps the general definition could just link to Web API, and/or the specific definition could link to WSDL, so this page would become a kind of "general"/"specific" disambiguation page with just that one split quotation.-- Skierpage (talk) 21:34, 8 August 2014 (UTC)[reply]

I have been involved in standards making at W3C (XML, XML Schemas, etc), so I think I understand their tack. When they make a standard for something, they frequently just take the generic name and capitalize it. So their technology for XML schemas is called W3C XML Schemas, and their technology web services is W3C Web Services. But that gives them no right to usurp the generic term (nor do they want to.)

It drives me nuts that people use the term web services to only mean SOAP. If you mean SOAP and a particular technology, use W3C Web Services.

Please be aware that this was also part of marketing strategies of the large vendors in the days when they wanted to flog their elaborate SOAP implementations. They would only speak of web services as meaning W3C Web Services. The consequence is that now, when people want to talk about a web service that is not based on W3C Web Services they have to talk in terms of REST (even if they are not actually doing REST, a la JAX-RS.) The way out of the mess is to clearly distinguish the general concept from the particular technology. Rick Jelliffe (talk) 00:53, 3 May 2018 (UTC)[reply]

I have rearranged the article accordingly.Rick Jelliffe (talk) 01:58, 3 May 2018 (UTC)[reply]

Vandalism

[edit]

There has been a lot of vandalism editing lately, hasn't it ? Any idea of the reason behind that? This is not a all public article so I just don't understand. Do you think there is a need to act ? Dockurt2k 15:48, 12 March 2007 (UTC)[reply]


yes there has. There's no obvious cause; its just minor recreational vandalism rather than some concerted effort. If it can be kept under control, then good. —The preceding unsigned comment was added by SteveLoughran (talkcontribs) 20:33, 19 March 2007 (UTC).[reply]

Poor articel

[edit]

This article is of a very poor standard.Not really good. Lots of errors on this one —Preceding unsigned comment added by 84.66.3.93 (talkcontribs) 13:06, 24 May 2007

then fix it! :-) John Vandenberg 13:26, 24 May 2007 (UTC)[reply]
That's actually not fair. As it turns out, there are users out there who sometimes read articles about topics they are unfamiliar with, and there's no way you can know that this particular anonymous user doesn't belong to that group. It's difficult to demand of someone that they should read up on the topic not only to the point where they can discuss it in an unbiased way, but also so that they can explain it to others, just so that they can make some changes on Wikipedia. But of course, the criticism could've been more specific. --τις (talk) 11:00, 16 March 2011 (UTC)[reply]

i think it should be poor article INSTEAD OF POOR ARTICEL ......many errors on this one.it really doesnot match the standards of wikipedia...Anoopnair2050 (talk) 13:08, 23 July 2008 (UTC)[reply]

I agree, it is a very poor article. It doesn't explain anything to someone who wants to learn what it's for, how it can be used, how is it different from its predecessors. It's too technical and it assumes familiarity and knowledge. I think it should be rewritten to explain what it is to someone who has no clue, rather than describe it to someone who has a clue.58.105.242.113 (talk) 00:32, 17 August 2009 (UTC)[reply]

I've just read the article, as it stands at January 2010, and I think it's a fantastic article! It describes the technical view of web services, and some related issues, at just the right level of detail. Nice work! I have read many high level descriptions of SOAP and REST, and this is the best. —Preceding unsigned comment added by Javaman59 (talkcontribs) 02:32, 20 January 2010 (UTC)[reply]

I have rearranged the article for clarity, and augmented the existing material. So I think it is a bit better now.Rick Jelliffe (talk) 02:00, 3 May 2018 (UTC)[reply]

Outdated

[edit]

This article says that in common usage a Web Service is SOAP based. I think that was true a few years ago but more and more the common understanding is that a Web Service is a service accessible from the web (i.e. via HTTP). This seems to me, to be the simplest definition and the most fitting. As evidence, I offer Amazon Web Services (AWS) which provides both SOAP and non-SOAP versions of their services. If a web service must use SOAP, then it would be improper for Amazon to call these REST interfaces web services. It's pretty plain to me that making SOAP a requirement of Web Services is a pointless distinction. A lot of organizations are treating SOAP as a legacy protocol. Personally I call SOAP "xml-CORBA". I also don't understand the characterization of REST as emulating HTTP. AFAIK, REST is defined in terms of HTTP. It's not emulating the four operations of HTTP (get, put, post, delete), it's built on top of them. Dubwai (talk) 19:52, 24 January 2008 (UTC)[reply]

I see your point. Perhaps it should be clear this is SOAP web services and not RESTy ones (As amazon S3) or HTTP query abuse (amazon simpledb). Note that you can use the REST operations over other protocols (such as XMPP); you get the same state model over different transports. SteveLoughran (talk) 22:34, 27 January 2008 (UTC)[reply]

I have rearranged the article and clarified about SOAP/W3C.Rick Jelliffe (talk) 02:00, 3 May 2018 (UTC)[reply]

A 'Web service' (also Web Service)

[edit]

Untseac (talk) 00:46, 17 July 2008 (UTC)[reply]

A 'Web service' (also Web Service)? Is that a typo? I don't understand the meaning of that phrase. What's the difference?

Capitalisation. SteveLoughran (talk) 16:42, 19 July 2008 (UTC)[reply]

i also dont understand the meaning of the phrase.can someone can more elaborate it. Anoopnair2050 (talk) 13:04, 23 July 2008 (UTC) Sarma Pisapati (talk) 14:43, 27 February 2009 (UTC) Web Service is not just over HTTP transport. Today, there are other transports such as JMS, MQ, SMTP, etc. Basically it is an application service rather than a presentation sevice such as Web Server that operates over HTTP transport. Web Server can host Web Service. —Preceding unsigned comment added by Pisapatis (talkcontribs) 14:38, 27 February 2009[reply]

As you spell Hypertext Transfer Protocol and Great Barrier Reef I feel Web Service more correct than Web service. If a native speaker could confirm this, the spelling in this article should be consolidated and the lemma be changed. --Gerd-HH (talk) 07:09, 24 July 2009 (UTC)[reply]

Web Services that you can use to learn and explore more about this topic

[edit]

Here are some additional web services I recommend for addition to the main article.
http://www.ecubicle.net/youtubedownloader.asmx
http://www.ecubicle.net/driving.asmx
http://www.ecubicle.net/livestockquotes.asmx
http://www.ecubicle.net/whois_service.asmx

99.253.209.37 (talk) 07:48, 6 January 2009 (UTC)[reply]

Web services sample application [Edit Page] Edit Page [Browse Space] Browse Space [Add Page] Add Page [Add News] Add News Web application security sample Sample applications In a discussion on interoperability of modern day enterprise applications, Web Services naturally joins the party. Web Service technologies provides J2EE with an opportunity to become truly inter operable with any other system. This is because, Web service technologies are platform-agnostic; in other words, the medium used to communicate is not specific to any combination of programming language, operating system, and hardware.

After reading this article you should be able to deploy web services in the form of servlets in Apache Geronimo and access them with different sorts of clients. This will be a good starting point to web services in the Geronimo server and to getting familiar with cumbersome JAX-RPC technologies. This article is organized into the following sections : -

   * Overview of Web Services Features in Geronimo
   * Application Overview
   * Configuring, Building and Deploying the Sample Application
   * Testing of the Sample Application
   * Summary

Overview of Web Services Features in Geronimo According to J2EE 1.4 standard there are several options for consuming web services :

  1. A servlet may act as a Web service.
  2. A session bean may act as a Web service.
  3. Any J2EE component may act as a Web service client, using a reference to an external Web service.

Apache Geronimo supports JAX-RPC based Web services according to J2EE 1.4 standard. This means that a Web service application developed for the Geronimo should run on any application server. But JAX-RPC is a technology that is cumbersome and difficult to deal with. Application Overview

The sample application referred in this article is a simple calculator which performs addition of two integers. The client application referred here is not a J2EE application, which will call a web service to carry out application functionality. Web service is exposed as a servlet in the Geronimo application server.

The following figure illustrates overview of calculator application :

The Web services deployed in the server uses CalculatorService interface as service end point interface. The important thing in this interface is it extends java.rmi.Remote interface and throws java.rmi.RemoteException from exposed methods. CalculatorService.java

public interface CalculatorService extends java.rmi.Remote {

  public int addition( int x,int y ) throws java.rmi.RemoteException;

}

The service implementation class for the web service is CalculatorServiceServlet. It implements all the methods in the service end point interface. This class will be exposed as a servlet in the web.xml file eventhough it is not necessary to extend javax.servlet.Servlet class. CalculatorServiceServlet.java

public class CalculatorServiceServlet { public int addition(int x, int y){ return x + y; } }

web.xml

<?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:calc="urn:geronimo-samples" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"> <servlet> <display-name>CalculatorServiceServlet</display-name> <servlet-name>CalculatorServiceServlet</servlet-name> <servlet-class> org.apache.geronimo.samples.calc.web.CalculatorServiceServlet </servlet-class> </servlet>

<servlet-mapping> <servlet-name>CalculatorServiceServlet</servlet-name> <url-pattern>/calculator</url-pattern> </servlet-mapping>

</web-app> Note the dependencies section of the geronimo-web.xml file. Those dependencies are mandotory to deploy web services in your web archive. geronimo-web.xml <web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web-1.1" xmlns:naming="http://geronimo.apache.org/xml/ns/naming-1.1">

 <dep:environment xmlns:dep="http://geronimo.apache.org/xml/ns/deployment-1.1">
   <dep:moduleId>
     <dep:groupId>org.apache.geronimo.samples</dep:groupId>
     <dep:artifactId>Calculator</dep:artifactId>
     <dep:version>1.0</dep:version>
     <dep:type>car</dep:type>
   </dep:moduleId>
   <dep:dependencies>

<dep:dependency>

          <dep:groupId>geronimo</dep:groupId>
          <dep:artifactId>geronimo-webservices</dep:artifactId>
          <dep:type>jar</dep:type>
       </dep:dependency>

<dep:dependency>

          <dep:groupId>geronimo</dep:groupId>
          <dep:artifactId>geronimo-axis</dep:artifactId>
          <dep:type>jar</dep:type>
       </dep:dependency>
   </dep:dependencies>	
   <dep:hidden-classes/>
   <dep:non-overridable-classes/>
 </dep:environment>
<context-root>/Calculator</context-root> 

</web-app> To deploy a JAX-RPC based web service, three additional configuration files have to be added into your archive. Those are WSDL file , jaxrpc-mapping file and web service description file. Those configuration files can be found under the config/servlet folder of the application. WSDL file describes about the web service as given in the below : CalculatorServiceServlet.wsdl <?xml version="1.0" encoding="UTF-8"?>

<definitions name="CalculatorServiceServlet" targetNamespace="urn:geronimo-samples" xmlns:tns="urn:geronimo-samples"

xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" 

xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">

 <types/>
 <message name="CalculatorService_addition">
   <part name="int_1" type="xsd:int"/>
   <part name="int_2" type="xsd:int"/>
 </message>
 <message name="CalculatorService_additionResponse">
   <part name="result" type="xsd:int"/>
 </message>
 <portType name="CalculatorService">
   <operation name="addition" parameterOrder="int_1 int_2">
     <input message="tns:CalculatorService_addition"/>
     <output message="tns:CalculatorService_additionResponse"/>
    </operation>
 </portType>
 <binding name="CalculatorServiceBinding" type="tns:CalculatorService">
   <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
   <operation name="addition">
     <soap:operation soapAction=""/>
     <input>
       <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded"
namespace="urn:geronimo-samples"/>
     </input>
     <output>
       <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded"
namespace="urn:geronimo-samples"/>
     </output>
   </operation>
 </binding>
 <service name="CalculatorServiceServlet">
   <port name="CalculatorServicePort" binding="tns:CalculatorServiceBinding">
     <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
   </port>
 </service>

</definitions> jaxrpc-mapping file will map the information with service implementation. jaxrpc-mapping.xml <?xml version="1.0" encoding="UTF-8"?> <java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">

 <package-mapping>
   <package-type>org.apache.geronimo.samples.calc</package-type>
   <namespaceURI>urn:geronimo-samples</namespaceURI>
 </package-mapping>
 <package-mapping>
   <package-type>org.apache.geronimo.samples.calc</package-type>
   <namespaceURI>urn:geronimo-samples</namespaceURI>
 </package-mapping>
 <service-interface-mapping>

<service-interface> org.apache.geronimo.samples.calc.CalculatorService </service-interface>

   <wsdl-service-name xmlns:serviceNS="urn:geronimo-samples">serviceNS:CalculatorServiceServlet</wsdl-service-name>
   <port-mapping>
     <port-name>CalculatorServicePort</port-name>
     <java-port-name>CalculatorServicePort</java-port-name>
   </port-mapping>
 </service-interface-mapping>
 <service-endpoint-interface-mapping>
   <service-endpoint-interface>org.apache.geronimo.samples.calc.CalculatorService</service-endpoint-interface>
   <wsdl-port-type xmlns:portTypeNS="urn:geronimo-samples">portTypeNS:CalculatorService</wsdl-port-type>
   <wsdl-binding xmlns:bindingNS="urn:geronimo-samples">bindingNS:CalculatorServiceBinding</wsdl-binding>
   <service-endpoint-method-mapping>
     <java-method-name>addition</java-method-name>
     <wsdl-operation>addition</wsdl-operation>
     <method-param-parts-mapping>
       <param-position>0</param-position>
       <param-type>int</param-type>
       <wsdl-message-mapping>
         <wsdl-message xmlns:wsdlMsgNS="urn:geronimo-samples">wsdlMsgNS:CalculatorService_addition</wsdl-message>
         <wsdl-message-part-name>int_1</wsdl-message-part-name>
         <parameter-mode>IN</parameter-mode>
       </wsdl-message-mapping>
     </method-param-parts-mapping>
     <method-param-parts-mapping>
       <param-position>1</param-position>
       <param-type>int</param-type>
       <wsdl-message-mapping>
         <wsdl-message xmlns:wsdlMsgNS="urn:geronimo-samples">wsdlMsgNS:CalculatorService_addition</wsdl-message>
         <wsdl-message-part-name>int_2</wsdl-message-part-name>
         <parameter-mode>IN</parameter-mode>
       </wsdl-message-mapping>
     </method-param-parts-mapping>
     <wsdl-return-value-mapping>
       <method-return-value>int</method-return-value>
       <wsdl-message xmlns:wsdlMsgNS="urn:geronimo-samples">wsdlMsgNS:CalculatorService_additionResponse</wsdl-message>
       <wsdl-message-part-name>result</wsdl-message-part-name>
     </wsdl-return-value-mapping>
   </service-endpoint-method-mapping>
 </service-endpoint-interface-mapping>

</java-wsdl-mapping> webservices.xml file gives the locations of WSDL and jaxrpc-mapping files to services. The developer needs to have a good understanding of this file than the others given above. webservices.xml <?xml version="1.0" encoding="UTF-8"?> <webservices xmlns="http://java.sun.com/xml/ns/j2ee" version="1.1">

<webservice-description>
 <webservice-description-name>

CalculatorServiceServlet

 </webservice-description-name>
 <wsdl-file>WEB-INF/wsdl/CalculatorServiceServlet.wsdl</wsdl-file>
 <jaxrpc-mapping-file>WEB-INF/jaxrpc-mapping.xml</jaxrpc-mapping-file>
 <port-component>

<port-component-name>CalculatorServicePort</port-component-name> <wsdl-port>CalculatorServicePort</wsdl-port> <service-endpoint-interface> org.apache.geronimo.samples.calc.CalculatorService </service-endpoint-interface> <service-impl-bean> <servlet-link>CalculatorServiceServlet</servlet-link> </service-impl-bean>

 </port-component>
</webservice-description>

</webservices> How to access the Web service deployed in the server in tool independent manner? CalculatorClient.java file demonstrates how to achieve this function. CalculatorClient.java String urlstr = "http://localhost:8080/Calculator/calculator?wsdl"; URL url = new URL(urlstr); QName qname = new QName("urn:geronimo-samples","CalculatorServiceServlet"); ServiceFactory factory = ServiceFactory.newInstance(); Service service = factory.createService(url, qname); CalculatorService calc = (CalculatorService)service.getPort(CalculatorService.class); int sum = calc.addition(x, y); System.out.println("Sum of "+x+" and "+y+" is "+sum); Tools used The tools used for developing and building the Calculator sample application are: Java Web Services Developer Kit

The Java Web Services Developer Pack (Java WSDP) is used for simplified development of secure and interoperable Web services applications. The Java WSDP is an integrated toolkit for developing, building, testing, and deploying web services, as well as web and XML-based applications. WSDP has been used to generate jaxrpc-mapping and WSDL files for the Calculator application. WSDP can be downloaded from the following URL: http://java.sun.com/webservices/jwsdp/index.jsp Eclipse The Eclipse IDE was used for development of the sample application. This is an extremely powerful and popular open source development tool. Integration plug-ins are available for Geronimo. Eclipse can be downloaded from the following URL: http://www.eclipse.org Apache Ant Ant is a pure Java build tool. It is used for building the Calculator application. Ant can be downloaded from the following URL: http://ant.apache.org Back to Top Configuring, Building and Deploying Sample Application Download the Calculator application from the following link: Calculator

After extracting the zip file, the Calculator directory is created. Configuring Calculator application comes with an Ant script to help users to build from source code. It has to be properly configured before using it to build from source. build.properties file in the config directory has to be modified according to your environment. Set the correct path to the <geronimo_home> directory.

This build script depends on Geronimo 1.1.1. Also make sure to use "/" as you directory separator in Windows environment when you are setting the <geronimo_home> directory. Building Compile Source Code

Use a command prompt and navigate to the Calculator directory and just give ant compile-web command to build. It will compile the source code into the Calculator/releases/war folder. From these compiled classes we are going to create jaxrpc-mapping and WSDL. Generate WSDL and jaxrpc-mapping files We have tested this application with Java WSDP 2.0 and it needs JDK 1.5 If you are not happy with given configuration files in Calculator/config/servlet and want to do some experiments, use the Java WSDP to generate jaxrpc-mapping and WSDL files. Follow these steps to generate those files.

  1. Copy Calculator/config/servlet/config-interface.xml to the WSDP_HOME/jaxrpc/bin.
  2. Create a folder called build under WSDP_HOME/jaxrpc/bin and copy classes folder from Calculator/releases/ear/war/classes.
  3. From command prompt issue the following command in WSDP_HOME/jaxrpc/bin.
     Linux
     ./wscompile.sh -define -mapping build/jaxrpc-mapping.xml -d build -nd build -classpath build config-interface.xml
     Windows
     wscompile -define -mapping build/jaxrpc-mapping.xml -d build -nd build -classpath build config-interface.xml
  4. Previous step will generate both WSDL and jaxrpc-mapping file in the WSDP_HOME/jaxrpc/bin/build folder. 

The next step is to edit jaxrpc-mapping.xml file according to our services. Change the service-interface to org.apache.geronimo.samples.calc.CalculatorService.

  5. Now copy those files to the Calculator/config/servlet folder.
  6. Remove the build file from WSDP_HOME/jaxrpc/bin.

Create WAR file To create WAR file use ant command while you are in the Calculator folder, from command prompt. This will create Calculator.war file under the Calculator/releases folder. Deploying Deploying sample application is pretty straight forward, since we are going to using Geronimo Console.

  1. Scroll to Deploy New from the Console Navigation panel.
  2. Load Calculator.war from Calculator/releases folder in to the Archive input box.
  3. Press Install button to deploy application in the server.

Testing of the Sample Application To test this sample application we are going to run the CalculatorClient application as given below. ant run-client -Dval1=<num1> -Dval2=<num2> lsf@lsf-laptop:~/workspace/Calculator$ ant run-client -Dval1=1 -Dval2=12 Buildfile: build.xml run-client:

    [java] Working directory ignored when same JVM is used.
    [java] Sum of 1 and 12 is 13

Summary This article has shown, how to deploy a simple web service in J2EE specific manner. The highlights of this article :

   * As a J2EE 1.4 certified application server Apache Geronimo supports JAX-RPC based Web service deployment.
   * Deploy simple Web service in Geronimo as a servlet.
   * Generate Web service related configuration files from Java WSDP.
   * Access a deployed Web service from a client other than J2EE.

Added By Bala

disambiguate between "web service" and "Web Service"

[edit]

I think this page should start with some disambiguation. A web service is just a generic term for some kind of network service that uses the web. A Web Service is the standard built on SOAP.

I agree, but the general / specific split is not based on whether "Web Service" is capitalized. I split the starting quotation in revision 620424688, which helps. -- Skierpage (talk) 21:38, 8 August 2014 (UTC)[reply]

I agree that it would be good to capitalize all uses of web services when what is meant is W3C Web Services. I have done this in a few cases, however I hope the new split in the article between generic and specific (W3C) helps clarify things more.Rick Jelliffe (talk) 01:46, 3 May 2018 (UTC)[reply]

SOA, Web Services, REST

[edit]

This article is a mess. Whoever wrote it doesn't seem to understand web services at all. There are -two- kinds of web services, RPC and ROA (resource oriented architecture). RPC offers services (ie. verbs/methods) and ROA offers nouns (XML/JSON for example). RPC is typically associated with SOAP (hence the name - simple object access protocol - which accesses objects on the server to invoke their member functions). It is similar to CORBA. ROA is typically associated with REST (hence the name, ROA grabs a representation of content which is on the server and transfers it to the client). It is similar to the rest of the web. I started to fix the article, but it is so messed up, it really requires a total rewrite. I've never seen a technical article on Wikipedia which is so uninformed (political articles are always a mess, but I always thought Wikipedia did a fairly good job of technical content) - 69.143.48.114 (talk) 14:49, 16 January 2010 (UTC)[reply]

I agree with you, the article is a mess. Trying to make sense of what web services are from reading it is not easy. The most fundamental error is that it does not explain the purpose of web services. Which, if I understand it correctly, is as simple as machine-machine communications on the web instead of man-machine. This needs to be pointed out before any of the technical details is presented. I, unfortunately, do not have sufficent knowledge on the subject. Happy to review, fact check, etc. though. --Gosub (talk) 12:33, 18 March 2010 (UTC)[reply]

I agree also that the article is poor. It doesn't address the predominant type of web service in use today, which is the basis of most mashups. I think the problem is that the three classes of web service (RPC, SOA, REST) are not mutually exclusive nor even at the same level. SOA is too broad and is used as a catchall for SOAP/WSDL and other WS* technologies.

Tally another vote for a rework of the article. Also, neither SOA nor REST are a "class of web service." SOA and REST are architectural styles. SOA does not prescribe the use of SOAP. SOA != SOAP. REST does not prescribe the use of HTTP and does not define any verbs at all--it simply uses HTTP and its verbs as an exemplar for adhering to the REST architectural constraints. REST != HTTP. Reamon (talk) 01:33, 22 December 2010 (UTC)[reply]

While I agree that SOA != SOAP (you can have web services over other transports), REST != HTTP is a bit misleading. Though true for REST in general RESTful web services do need to run over HTTP. -- Q Chris (talk) 11:12, 16 March 2011 (UTC)[reply]
I have disentangled the article, which should help some of the points raised above.Rick Jelliffe (talk) 01:45, 3 May 2018 (UTC)[reply]

Evolution

[edit]

I see some support for a complete rewrite of this article. It is a fairly important topic, but it is important to keep vendor/implementation bias out of it. The current article is pretty good about that. I would guess that most people that can contribute substantially will have experience with only a limited range of the available technologies. I propose changing things in stages. Identify major axes that can be used to partition what is a web-service from what isn't, and what separates different approaches. These can be added in as new sections, cannibalizing the old ones as needed to keep everything consistent/connected. In that vein, I'm starting with minor changes to more accurately describe the section on design methodologies, which is actually describing "automated design methodologies." Srjefferys (talk) 21:43, 10 January 2011 (UTC)[reply]

An article for those who already know what a Web service is?

[edit]

I'm studying computer science, but still think that this article explains next to nothing. The first sentence is "A Web service is a method of communication between two electronic devices over a network." Can it be used for any kind of communication? Ping is a form of communication. Is a Web service then the preferred way to do a ping? Emailing is certainly communication. Do I use Web services every time I email someone? What most people would want to know is probably what kind of communication it refers to, and what is transmitted. Also, is there a server and a client, or is it peer-to-peer? Is the communication initiated by the user, or is this something done in the background? Do you have to know about it to use it or do the programs use it without the user's knowledge? Reading on, we find "Other systems interact with the Web service in a manner prescribed by its description using SOAP messages" a few sentences later. Okay, so now it's no longer a method, but rather a computer and SOAP is the method? But probably not, because later on it says "Web services are a set of tools that can be used in a number of ways" (a perfectly non-informative sentence by the way). My point is that I still have no clue what the whole concept is about. Let me know if I'm just too stupid to understand it, but otherwise I hope someone can rewrite at least the introduction. Someone other than me, that is. --τις (talk) 10:30, 16 March 2011 (UTC)[reply]

I'm also a cs student, and I agree with the above. I could not really make much of the article. 85.101.129.75 (talk) 21:40, 12 January 2012 (UTC)[reply]
Quite. What is a web service?? Flies 1 (talk) 15:59, 9 May 2012 (UTC)[reply]

The problem with a lot of this is that a Web service should be defined as "a service provided on the Web". It's extremely broad but accurate. Contrary to what this article implies, and the naming conventions of W3 (within WSDL, etc), a "service" is an abstract concept of "providing some type of functionality" or "performing operations to satisfy a request". You may easily compare it to a restaurant waitress or gas station attendant. A web service is not a "method of communication". Nor is a "web service" an interface for how you submit a request or receive a reply (contrary to WSDL meaning 'Web Service Definition Language'). Those are interface definitions for how you must communicate with a web service. I would also exclude the act of receiving the request and the act of transmitting the reply from the definition of "web service", and rather limit the "service" to be the processing of the request and the generation of the reply, albeit every "service" need not process requests or generate replies. Returning to the restaurant waitress example, the "service" provided is all the actions between (including) taking your food order and delivering your food, and fulfilling any other requests you may have. The "service" provided by the waitress is definitely not the waitress dictating how you must communicate with her, which is what WSDL and other interface definition languages do. Mojodaddy (talk) 16:27, 7 May 2014 (UTC)[reply]

Examples

[edit]

Maybe a few examples would help. What are the biggest web services out there? What are the most interesting web services? And how do these work. And maye a counter example: "foobar.com provides intercomputer communication but is not considered a webservice because ...". 85.101.129.75 (talk) 21:42, 12 January 2012 (UTC).[reply]

I agree that this would be helpful. Flies 1 (talk) 15:57, 9 May 2012 (UTC)[reply]

The article does not explain what a web service is adequately

[edit]

I've read through this article, and it left me with no idea what a web service is. The head is rendered unintelligible by the use of jargon. What is a web service? What does it do? Who uses it, and what for? Flies 1 (talk) 15:56, 9 May 2012 (UTC)[reply]

I'm a developer, mainly writing web apps, so I know what a web service is in practice (I work in the .NET framework), but in general this article is fricking terrible. I'm not knowledgeable enough yet to edit it, but I'm surprised at its low quality since web services aren't exactly some niche thing.

For one, what the hell are "Big Web Services" and why is that a header? And the last line from that section: "Web services used in 3 ways first one is SOAP,WSDL,UDI.....". I went ahead and removed that since it makes no sense and was written by someone without a 4th grade English comprehension. Clamum (talk) 19:14, 20 August 2012 (UTC)[reply]

I have untangled the article, so I hope the idea should be a little clearer.Rick Jelliffe (talk) 01:43, 3 May 2018 (UTC)[reply]

Why no mention of JSON?

[edit]

Why does this article explicitly specify that Web Services use XML? If I have a JSON or YAML service that behaves in every other way like an XML Web Service, this article implies that it's not a Web Service. Is that true? I've worked with XML web services for 6 years with SOAP and all that fun stuff. I don't see any reason why you can't do the same thing with JSON or YAML, so don't understand why this article doesn't acknowledge that there are options for the representation format. I thought the key aspect of a web service was that it provided data over HTTP in the client-server context that HTTP was designed for.

I'm hoping someone can correct me or this article. — Preceding unsigned comment added by GlenPeterson (talkcontribs) 15:18, 4 December 2012 (UTC)[reply]

Because in the Web Services Architecture "definition", web services use XML and WSDL. I tried to clarify the distinction. -- Skierpage (talk) 21:42, 8 August 2014 (UTC)[reply]

I have added reference to JSON.Rick Jelliffe (talk) 01:42, 3 May 2018 (UTC)[reply]

What is a "service"

[edit]

Hello, first, thank you all for all the work done here. My question is simple: in the article, it is stated that: "A Web service is a service offered by an electronic device to another electronic device".

OK... But, can anyone explain to me, in plain "dumb" english, what is (here) a "service" ? I seem to not have all the prerequisite knowledge to understand even the premises of this article.

And also: "to manipulate representations of Web resources using a uniform set of stateless operations"... Whut ??? I don't even understand any word here, except "to", "of" and "a"... Am i the dumbest person on Earth, or is this article just totally incomprehensible ? I a definition not meant to make you understand something anymore ?

Thanks ! 194.250.5.173 (talk) 08:54, 20 June 2016 (UTC)[reply]

I took a stab at fixing your first observation, by hyperlinking the word "service" in the first sentence to Service (systems architecture) (and fixing up the first sentence in that article a bit).
As for the latter portion of your note: Well, if you don't already know what an atom is, it's not going to help you to be told that a proton is one of the constituent parts of an atom, but there you are. Some of the words in that sentence about manipulating representations, including "REST", are hyperlinked to articles that explain the underlying concepts further. You do need to understand what a stateless operation is, for example, to understand what the point of REST is. But stateless operations themselves require some explanation that is outside the scope of this article. Largoplazo (talk) 11:05, 20 June 2016 (UTC)[reply]

Definition

[edit]

The definition is not correct, even the single sentence that is currently in place:

Currently it reads that a webservice communicates from an electronic device to another electronic device. Even that is not the case. If I run webservice 1 on port 80 on localhost, open my browser and navigate to it. There are no different electronic devices. If I build a webserver that offers services to both external devices as well as service-to-service communication between the services on the same electronic device: there are no different electronic devices.

Secondly If I use a webservice from a company somewhere in the cloud, undoubtly it will run on something but I don't regard that as a device. Possibly on the other side there is a load balancer with a gazillion servers where somewhere the web services are served.

So to combine the above I think it is sharper to not define it as "a web service is a software component that listens to a specific port for a call. If the call is received it will execute functionality. (implementation can differ, transport can differ, an web service that only reacts on a timer without an interface and then write a log entry, has no clients) — Preceding unsigned comment added by 83.80.242.210 (talk) 12:06, 5 October 2017 (UTC)[reply]

Ħéȳ

Use sentence case

[edit]

I find the page hard to read. Would it be a good idea to not capitalize web in web service? Not sure if relevant, but Google and Microsoft use lower case web. Also the W3C glossary quote uses sentence case. Kinda related, the section about Ajax would also benefit from having fewer capital letters. Cru121 (talk) 12:38, 2 September 2019 (UTC)[reply]

The article's still a mess

[edit]

I was suddenly seized with the urge to rewrite the article , but I figured I'd check on the Talk page first solicit support for this. I see there's already been a tremendous amount—and I'm surprised that knowledgeable people (moreso than I) haven't rushed to fix it.

For one thing, I don't see that there's such a thing as a "W3C Web Service", and the two-item list in the lead is a false dichotomy. Web services are services supplied over the web by applications running on web servers. The W3C came up with a particular working definition and, as they do in many areas, prescribed specific practices, but they're still just web services, they aren't a different thing calling for capitalization as Web Services, and certainly not as W3C Web Services.

It's worth covering W3C's influence on web services, how they developed, and in what form they're provided, but there's nothing here to disambiguate. It's like saying hockey, on one hand, and the game played on ice with a puck and sticks under rules issued by the National Hockey League, on the other hand, are two different sports. Largoplazo (talk) 22:11, 18 January 2020 (UTC)[reply]