SOAP Defines A Standard Communication Protocol (Set of Rules) Specification
SOAP Defines A Standard Communication Protocol (Set of Rules) Specification
E-Handbook
E-Handbook
E-Handbook
The RESTful Web services are completely stateless. This can be tested by
restarting the server and checking if the interactions are able to survive.
Restful services provide a good caching infrastructure over HTTP GET method
(for most servers). This can improve the performance, if the data the Web
service returns is not altered frequently and not dynamic in nature.
REST services are easy to integrate with the existing websites and are
exposed with XML so the HTML pages can consume the same with ease.
There is hardly any need to refactor the existing website architecture. This
makes developers more productive and comfortable as they will not have to
rewrite everything from scratch and just need to add on the existing
functionality.
SOAP
The Web Services Description Language (WSDL) contains and describes the
common set of rules to define the messages, bindings, operations and
location of the Web service. WSDL is a sort of formal contract to define the
interface that the Web service offers.
SOAP requires less plumbing code than REST services design, (i.e.,
transactions, security, coordination, addressing, trust, etc.) Most real-world
applications are not simple and support complex operations, which require
conversational state and contextual information to be maintained. With
the SOAP approach, developers need not worry about writing this plumbing
code into the application layer themselves.
learning curve, and with lightweight and faster results and simple transactions
(i.e., CRUD operations) is needed, my vote goes to REST.
Invoking Web service via Oracle database stored procedure
Consuming a Web service via a database stored procedure allows users to straight
away update a database with information from different sources. Users can also
schedule a job at regular intervals to get data updated periodically in the database.
Oracle provides a "utl_http" utility to help achieve this. Below is sample code for the
Oracle package for a customer where the Web service call is made from the
database.
Common problems faced when invoking Web services and solutions
Sometimes, even after doing everything as expected in the stored procedure to call
the Web service, the procedure doesn't get compiled. The following is a compilation
of runtime errors faced during stored procedure execution to invoke a Web service
and their solutions.