Petals Getting started - day 3 - Expose a FTP Service in SOAP

Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (17)

View Page History
# File => New => Service Unit Project: Service Unit - Select the kind of service to create.
# Select: Provide / FTP / Current_Version => Next: FTP Service-Unit - Defines the JBI properties of the service to import.
## Service Name: *FtpTutorial*
## *Service Name*: FtpTutorial
# Next => Next: FTP Service-Unit - Define the specific properties for this version of the component.
{note}<folder> attribute is written as optionnal in Studio, but it is not. It will be optional in BC-FTP v3, so as soon as it is published, you will not need to specify the folder attribute for the tutorial.{note}
## Server: *ftp.petalslink.com*
## Port: *21*
## User: *petals*
## Password: *demo*
## Folder: *_/_*
## Transfer Type: *auto*
## Connection Mode: *active*
## *Server*: ftp.petalslink.com
## *Port*: 21
## *User*: petals
## *Password*: demo
## *Folder*: /
## *Transfer Type*: auto
## *Connection Mode*: active
# Finish.
# Look the generated _jbi.xml_ component configuration. It should look like:
<wsdl:portType name="FtpInterface">

This is a known bug in Petals Studio 1.1.0. It should might be corrected in version 1.1.1.{note}
# Drop the generated _sa-FTP-FtpTutorial-provide.zip_ to ./_petals-platform-xxx/install/_ folder to deploy it.
# Check Petals ESB traces to be sure the SA was deployed successfully.
# Go in tab: Monitoring/Filter Monitoring.
!Webconsole-monitoring.png|thumbnail,border=1!
_Screenshot: Message exchange monitoring_

*Change destination folder:*
# Next: Define the project name and location.
# Next: Define the specific properties for this version of the component.
## Adress: *SoapFtpTutorial* (Name you want to give to the service)
## *Service Name*: SoapFtpTutorial
# Next: Define the CDK properties.
# Finish.
# PetalsFtpTutorial => FtpServiceSoapBinding => dir.
# Right clic on "Request1" => Show Request Editor: A window with a pre-generated messages appears.
# Delete the optional part of the message ( <connection> node and its children).
# Delete what is under&nbsp; <\!\--Optionnal-->: <connection> node and its children. Ftp parameters were already configured in the SU, so you do not need to configure them again.

{code:lang=xml|title=Your message looks like this}
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ver="http://petals.ow2.org/components/ftp/version-3">
</soapenv:Envelope>
{code}
# Clic the green arrow to send the message. The response should list two several files.
{info:title=Want to go further?}Try reading "HelloWorld.txt" into "Integration" folder, with optional elements.
{info:title=Want to go further?}Try reading "HelloWorld.txt" into "Integration" folder, using optional elements instead of deleting them.
\\
You can keep the optional elements, to change the initial BC-FTP configuration. But you need to redefine ALL properties in this case.
{info}

*Webconsole technical monitoring:*
# Activate monitoring on Webconsole.
# Send a few test message.
# Check the messages monitoring.
*Technical monitoring with Webconsole:*
# Go in Webconsole => Server: 0 => Monitoring => Server Monitoring
## *Check* "Filter Endpoint"
## *Select*: FtpTutorialEndpoint
# Submit
# Click the small image in the "_Monitoring"_ Column to activate _FtpTutorialEndpoint_ monitoring.
# Send a few test message with SOAP UI.
# Go in Webconsole => Server: 0 => Monitoring => Filter Monitoring
# Click on the right of a message exchange to get details. You should get a screen like this:
!Exchange SOAP-FTP.png|thumbnail,border=1!
_Screen: Message exchange status_

{info}You can see the initial message was now sent by BC-SOAP to BC-FTP{info}