Techniques
Working with SOA & Web Services in PowerBuilder
An introduction
Jan. 22, 2006 10:15 AM
If you examine the awseCommerceServicePort object, you will see it has an ItemSearch function that takes various arguments. We can call this function to send a request to our Web service and capture the response.
This is very similar to how you would make a call to a remote object using CORBA from within PowerBuilder (see Listing 4).
Comparison
We have covered three techniques for making requests against a Web service. There are various pros and cons for the methods demonstrated. Table 1 summarizes the differences among these options.
Conclusion
The three methods presented here demonstrate the options available to the PowerBuilder developer with regard to Web services in the new SOA paradigm (for more information on SOA and Web services, see the sidebar SOA != Web Services). Those of you on older versions can use the GetURL/PostURL functions and the XmlHttp object, while the developers on supported versions can take advantage of the new Web Service Proxy object. The Web Service Proxy does a fantastic job of abstracting away Web services to the level of distributed method calls. This alone is worth the price of an upgrade if you are going to be working frequently with Web services. Remember, shiny new PowerBuilder CDs are the gift that keeps on giving.
Resources
About Doug H. PorterDoug Porter is a software developer with DailyAccess Corporation. He is a Sun Certified Java Programmer and a Certified PowerBuilder Professional and was a speaker at TechWave 2004. He holds a BA in Spanish and an MS in CIS from the University of South Alabama where he has also worked as an adjunct instructor. Doug works extensively with EAServer, PowerBuilder, and Java developing client/server and Web applications for the financial industry.