Connecting to a web service
When creating a web service data source in BIRT, you typically need to specify only the location of the WSDL file. A well-formed WSDL file defines the available services, and typically, the information to connect to the SOAP server identified by a SOAP endpoint URL.
Alternatively, you can connect to the web service through a custom driver class. You would create and use a custom driver, if, for example, the web service does not provide a WSDL document.
How to specify the connection information for accessing a web service
This procedure shows how to connect to a public web service that returns the weather forecast for a specified U.S. zip code. You can get information about this web service at the following location:
http://www.webservicex.net/WS/WSDetails.aspx?CATID=12&WSID=68
1 In Data Explorer, right-click Data Sources, then choose New Data Source.
2 In New Data Source, supply the following information:
1 Select Web Services Data Source from the list of data source types.
2 In Data Source Name, type a name for the data source. For this example, type:
Weather_ws
3 Choose Next.
3 In New Web Services Data Source Profile, in WSDL URL or Location, type the following URL, as shown in Figure 8‑1:
http://www.webservicex.net/WeatherForecast.asmx?WSDL
For well-defined web services, you need only specify the URL to the WSDL document.
Figure 8‑1 URL to WSDL specified
4 Choose Test Connection to verify the connection to the web service.
5 Choose Finish. The new web service data source, Weather_ws, appears under Data Sources in Data Explorer.