About mailboxes

A key function of Sterling File Gateway is the routing of files from one mailbox to another, so mailboxes are fundamental to Sterling File Gateway operations.

Mailboxes used for Sterling File Gateway operations can be created automatically in the following circumstances:
  • When a partner is created in Sterling File Gateway
  • When partners are migrated from AFT
  • When partners are imported into Sterling B2B Integrator
  • When a routing channel is created
  • On demand, at the time of file transfer

When a partner is created, a mailbox with the same name is created. For example, if the partner is named "PartnerOne" a mailbox is created where the mailbox absolute path is "/PartnerOne". When the partner user logs in, the absolute path is not displayed. The partner only sees the virtual path, which in this example is "/".

When a routing channel is created, a producer mailbox is created in the structure specified in the governing routing channel template. Creation of a routing channel may or may not result in the creation of a consumer mailbox as well, depending on the governing routing channel template.

A consumer mailbox may optionally be created on demand (at run time), if configured to do so in the routing channel template.

Whether created at routing channel creation time or on demand at run time, the consumer mailbox will conform to the structure mandated by the routing channel template.

Sterling File Gateway can also use pre-existing mailboxes (for example, those from a Sterling B2B Integrator instance), if their paths match those expected by a routing channel, which derives its mailbox path from the governing routing channel template. When creating routing channels, the Sterling File Gateway application first checks to see if a mailbox of the required structure exists. If the mailbox does not exist, Sterling File Gateway creates it, along with any needed permissions.

Disabling duplicate messages

An important consideration for mailboxes is related to system behavior regarding duplicate files. A global system setting allows or disallows duplicates (files of the same name) in mailboxes. For optimum system behavior, disallow duplicates in your customer_overrides.properties file. To edit the customer_overrides.properties file:
  1. In the install_dir/properties directory, locate (or create, if necessary) the customer_overrides.properties file.
  2. Open the customer_overrides.properties file in a text editor.
  3. Add the following:

This ensures that every message in a single mailbox has a unique name. It also ensures that a message and a mailbox do not have the same name. If you write a message to a mailbox and the name matches the name of a message in the mailbox, the service deletes the old message before adding the new message.

Verifying that a routing schedule is enabled

To enable the routing of files from one mailbox to another, you must also ensure that an appropriate mailbox routing schedule is enabled. Before attempting to operate the system, verify that one of the following schedules is enabled by default:
  • MailboxEvaluateAllAutomaticRules (runs once per minute and can be edited for longer intervals)
  • MailboxEvaluateAllAutomaticRulesSubMin (checks for the presence of routable messages once every ten seconds and can be edited for other intervals less than one minute by modifying the MailboxEvaluateAllAutomaticRulesSubMin business process)

To enable either of these schedules, from the Sterling B2B Integrator Administration menu, select Deployment > Schedules

Purging messages from mailboxes

Messages in consumer mailboxes are not automatically purged, and over time could affect system performance. To avoid this, configure the Mailbox Scheduled Delete service to delete messages from one, many, or all mailboxes. For more information, see Mailbox Scheduled Delete Service.