Databases Reference
In-Depth Information
Completing the FTP file writer service
The next step in the wizard is to define the actual record formats. This is exactly the
same as when creating an input file. If we don't have an existing XML Schema for the
output file, then we can use the wizard to create one if we have a sample file to use.
Finally, remember to run through the wizard to the end, and click Finish rather than
Cancel or our entire configuration will be lost.
Moving, copying, and deleting files
Sometimes we will just want an adapter to move, copy, or delete a file without
reading it. We will use the ability of the file adapter to move a file (refer to Chapter 16 ,
Message Interaction Patterns , to set up a scheduler service within the SOA Suite).
The following steps will configure an outbound file or FTP adapter to move, copy, or
delete a file without reading it.
Generating an adapter
Use the file or FTP adapter wizard to generate an outbound adapter with a file
synchronous read or FTP synchronous get operation. You may also use a write or put
operation. The data location should use physical directories, and the content should be
marked as opaque, so that there is no need to understand the content of the file. Once
this has been done, we will modify the WSDL generated to add additional operations.
Modifying the port type
First, we edit the WSDL file itself, which we call <AdapterServiceName>.wsdl .
Modify the port type of the adapter to include the additional operations required,
as shown in the following code snippet. Use the same message type as the operation
generated by the wizard.
<portTypename="Write_ptt">
<operationname="Write">
<inputmessage="tns:Write_msg"/>
</operation>
<operationname="Move">
<inputmessage="tns:Write_msg"/>
</operation>
</portType>
 
Search WWH ::




Custom Search