473,396 Members | 2,151 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

pros and cons of AJAX compared to SOAP messaging

I have started learning about Ajax and SOAP Messaging, can someone tell me what are pros and cons of AJAX compared to SOAP messaging
Mar 24 '08 #1
2 1862
gits
5,390 Expert Mod 4TB
hi ...

this is quite a question :) ... SOAP is typically used to invoke webservices and as the name says it has a specific protocol with failure-states etc. while AJAX is used to make an 'ordinary' XMLHttpRequest that requests a resource at the server. even thogh you can send soap-messages through an XMLHttpRequest and invoke a webservice ... so the XMLHttpRequest is the transport object.

SOAP is mainly XML you have an envelope and a body. so in short words ... using soap/xml adds some overhead to your webapp compared to a XMLHttpRequest that just transports json-data for example. but XML is a little bit more comfortable to use. webservices (typically) have a public description ... the WSDL-file that you may read and you know what params you have to send, what methods could be invoked and what response you might get ... while using the XMLHttpRequest method without such comfort you have to know! how the service is to be invoked and what you get ...

hope this gets you on track with your further investigations on that interesting topic ... but there is much more to say as it could be done here :)

kind regards
Mar 25 '08 #2
Since we are talking pros and cons, I would say this from my experience in dealing with Paypal SOAP as well as many different Ajax applications. With the caveat that this is my opinion.

SOAP
Pros:
1. Generally more secure.
2. Less likely to allow an incorrect transaction to pass through. (IE the data is validated in the process of the transaction)
3. More structured, allowing you to control certain pieces of the transport of data.
Cons:
1. More complicated to understand.
2. More difficult to implement (as there is much more to do).
3. Not as well supported (SOAP didn't achieve the popularity that many thought it would, so you will have trouble finding companies that prefer this protocol).

AJAX:
Pros:
1. Extremely flexible. Can handle whatever you want it to.
2. Makes your application much more responsive and user-friendly.
3. Easy to understand. There are some quirks that make it seem strange, but once you get the general idea it's a piece of cake.
Cons:
1. Security will take extra work. This a whole can of worms. You're opening up a whole new avenue to exploit. This may not be an issue depending upon what you expose, but you need to make sure you know it's secure before opening your database or other important information to Ajax calls.
2. Increased development time over "traditional" methods. It will always take a little bit longer to make something in Ajax than just a post or something similar. Of course, you will tend to see a good ROI in that time as the application will be much easier to use.

I don't know if the two things are really apples to apples, but that should give you enough information to have a better idea as to what kind of solution should work for you.

Again, this is my opinion. Not all of these things are true in all cases (of course)!
Mar 25 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Antonio | last post by:
Hi everybody!! First of all, sorry about my english. I promise to improve it. I have a big problem when I try to add an attachment which contains a image in it. I have to solve it as soon as...
0
by: Stephen Chell | last post by:
I'm using SAAJ 1.2 (from jwsdp-1.3) and JDK 1.4.2_03. I've written a client application that uses the SAAJ api to send a SOAP message to a servlet. The servlet successfully receives the message...
44
by: lester | last post by:
a pre-beginner's question: what is the pros and cons of .net, compared to ++ I am wondering what can I get if I continue to learn C# after I have learned C --> C++ --> C# ?? I think there...
5
by: Fred | last post by:
Not much expertise on XSLT and trying to understand it's uses when creating apps in VS.NET? If I wanted flexibility on the UI (View aspect of M.V.C.): - How does it compare with creating...
10
by: Steve | last post by:
I need to build a very dynamic client and would be interested in knowing the pros and cons of using JSF and Ajax to accomplish this. Thanks. Steve
3
by: Andrea | last post by:
Hello everyone, I'd like to know which are the main pros and cons of using XML implementation in business organizations. >From a technical perspective, I find XML powerful, but looks like it is...
42
by: kenneth.m.mcdonald | last post by:
First, I don't intend this to be a flame war, please. Python and Ruby are the only two languages I'd willingly work in (at least amongst common languages), and TurboGears and Rails seem roughly...
62
by: estherschindler | last post by:
This is part of a series examining the strengths and weaknesses of various scripting languages, with particular attention to enterprise (read: big company) use. You Used Python to Write WHAT?...
1
by: moorcroft | last post by:
I'm sending the following SOAP request to a webservice (I've had to star out some parts of it for privacy purposes): <?xml version="1.0" encoding="UTF-8"?> <soap-env:Envelope...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.