Chapter 10
[ 233 ]
NetBeans provides a wizard to create a web service from a database table. The
generated web service can perform the CRUD operation on the selected table. For
this, right-click on ReservationBPEL project and select New | Other from the menu.
In the New File wizard page, select WSDL From Database option as shown in the
following screenshot:
Enter the name of the WSDL.
Building a Sample Application
[ 234 ]
Select the Data Source for the wizard to connect to and retrieve the tables. Make sure
that Java DB is running and you see the ITINERARY table. Add the table to Selected
Tables list and click Next.
You have the option of selecting individual columns to update. Since ours is a
sample, we will select all the columns to be updated.
Chapter 10
[ 235 ]
The next page will ask you about JNDI Name for a connection pooling that are
configured to provide connections for the same database that you selected in the
previous step. Type jdbc/southair as JNDI Name, we will configure jdbc/southair
data source and the connection pooling later.
After completing the wizard, ITINERARY.xsd and Itinerary_SA.wsdl files are
created automatically under ReservationBPEL project. The following is the code for
ITINERARY.xsd:
"http://j2ee.
Pages:
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208