Configuring SFTP Server Adapter User Exits

In Sterling B2B Integrator 5,2.5 or higher, you can configure SFTP Server adapter user exits.

Perform the following tasks to configure user exit points for the SFTP Server adapter. The interfaces are provided through separate files present in the install_dir/install/userexit/jars (install_dir\install\userexit\jars for Windows) directory.

For more information on specific java method implementation details, see the Javadocs provided in the <install>/userexit/docs directory.

  1. Write the code to implement the interface for the specific point.
  2. Add the custom code classes to a .jar file.
  3. Add the path of the .jar file to the dynamicclasspath.cfg file in the install_dir/install/properties (install_dir\install\properties for Windows) directory.
  4. Restart Sterling B2B Integrator.
  5. Open the install_dir/properties/userexit (install_dir\properties\userexit for Windows) directory and locate SftpServerUserExits.xml file.
  6. Edit SftpServerUserExits.xml file and add an entry for each implementation as shown. The user exits are run in the same order as they appear.
    <bean id="" class="com.sterlingcommerce.woodstock.userexit.srvices.sftpserver.SftpServerUserExit">
      		<property name="implementations">
      		<property name="generalParameters">
    				<prop key="return.on.exception">false</prop>
    				<prop key="pool.size">5</prop>
    				<prop key="maximum.queue.length">5</prop>
    				<prop key="wait.time">10</prop>
    				<prop key="execution.threshold.time">600000</prop>
  7. Remove all values to deactivate the user exit points.
  8. Restart the SFTP server adapter instance to apply the changes.
    • Restart only the adapter instance if you modify implementation class list and other properties.
    • The user exits of the SFTP server adapter is supported only after user authentication and not before.
    • The SFTP User Exit functionality (using Putty) does not work for SFTP Server Adapter 2.0.