This is the third in a series of posts counting down to the release of LiveCompare 2.3. So far I’ve covered one big new feature: extended enhancement pack support – and one little feature: send workflow as email attachment. This time it’s back to big features.
LivCompare 2.3 supports web services both as a client and server. In client mode, you use the Run Web Service action to invoke a web service and consume the results in your workflow. For example, you might take advantage of some cross-customer benchmark analyses that IntelliCorp is offering where LiveCompare sends some anonymous usage statistics to our server and in return you get a report comparing your SAP system with peer organizations. In server mode, you register a workflow as a web service to be consumed by some other external process. For example, you might want to trigger a LiveCompare SAP analysis from a change management environment.
Client Mode – Consume a Web Service
The palette contains a new action: Run Web Service. You first have to configure the action using a Wizard. The Wizard prompts you for the URL of a special file that describes the web service you want to call. These files go by the name of WSDL (which stands for web service description language) and then guides you through setting up the input and output parameters. Often you can simply click Next to skip through the pages and LiveCompare will do the right thing – creating input parameters and an output parameter of the correct type.
Once the action is configured you can run it. The input parameters will be sent to the web service and LiveCompare will transform the output into LiveCompare datasets of the right type.
What web services might you want to consume? We have one example of a customer that wants to combine data from SAP with a third-party application. The third-party application exposes a series of web service functions that provide access to the data. Using the Run Web Service action means the data can be accessed directly without messing about with exporting it to, say, a CSV file and importing it as a LiveCompare External Data Source. In this example, the web services functionality makes it simpler to integrate LiveCompare into the wider information systems available for analysis.
Example
In this example I am using a .NET Fact of the Day development web service. First I drop a Run Web Service action on the workflow design surface. From the context menu I choose Configure Web Service to start the wizard.

Click Next.
Enter the URL of the WSDL file that describes the web service:

Click Next.
Web services can often be invoked in different ways. LiveCompare displays the methods it supports. Pick one:

Click Next.
Pick from the available service methods. Just one in this case:

Click Next.
LiveCompare gives you the chance to ‘tweak’ how the response from the web service method is configured. In most cases you can simply click Next and LiveCompare will do the right thing.

Click Next.
LiveCompare displays the output types that it finds. The types you choose become LiveCompare datasets. Usually you just click Next.

Click Next.
The wizard is finished. The Run Web Service action is configured.

The workflow looks like this once I’ve created datasets for each of the configured output parameters:

Why are there three when we only picked one in the wizard?
The Raw Results Xml is always generated. This provides access to the low-level XML response that LiveCompare got from the service method. Some special case may exist where you want to work directly with the XML, perhaps using the Convert Data action to transform the XML into a report output via an XSL transformation (new 2.3 feature that I’ll cover in another post).
The Processed Results Table is always generated. Table datasets are often the most useful and convenient datasets – in part because you can use the ExecuteSQL action to manipulate the data. The Run Web Service action looks at the output parameters and tries to convert it into a table automatically for you.
The GotDOtnetDailyFact Result is LiveCompare’s native data type view of the web services response. In this case the dataset is a string containing:
“A C# System.InvalidCastException is thrown when a requested conversion from an interface or base type to a derived type fails at run time.”
I’ve expanded this workflow to look like:

The other actions turns the web service result into a Twitter compatible message that is then posted to LiveCompare’s Twitter account. The final result looks like:

Server Mode – Register Workflow as a Web Service
Registering a workflow as a web service is as simple as right-clicking on the workflow object in the hierarchy and choosing Register as Web Service. A Wizard will guide you through setting up the input parameters and output parameter.
The main Administration page has a link to all the registered web services. You can use this page to grab the WSDL URL for consumption in the ‘client’ program.
I’ve written here about our plans to work with Revelation Software Concepts on the integration of LiveCompare and Rev-Trac. Web services provides the the technical foundation for the integration. To enable the integration I simply register the special Rev-Trac workflow as a web service (it will ship in the LiveCompare templates package). In Rev-Trac I configure my change management strategy to require a LiveCompare impact analysis and under the covers Rev-Trac will run the web service-registered workflow to perform the impact analysis and collect the report as part of the permanent change record.
Cross-customer Analyses
One use that we’re exploring for this functionality is to offer customers a series of benchmarking services that compare and contrast their SAP implementation with peer SAP users. We already have a basic system called SOLO – http://solo.intellicorp.com/. The implementation of web services makes it easier for us to deploy the ‘client’ – it’s your installation of LiveCompare with an appropriate workflow – and extend the services overtime – we just add more workflows to our LiveCompare server.
The first benchmarking service will compare and contrast your level of SAP customization. From SOLO I see that the current average level of customization is 30%. The implementation of this service will mean a workflow on your LiveCompare server waking up every month and sending us your anonymous usage stats. In return you’ll get a dataset containing your current customization usage level and the average customization usage level.
The web services functionality in LiveCompare was driven by the need to integrate LiveCompare into the wider workflows that customers use to manage their SAP lifecycle. The technology provides the foundation for integrating with partner products, such as Rev-Trac, customer systems and information services available on the web.
Special thanks to Kevin Collins and the team at seanco.com for their permission to use the DailyDotNetWebService.
Posted
01-21-2010 11:35 AM
by
Chris Trueman