Mailbox Extract Abort Service

The Mailbox Extract Abort service handles the unsuccessful extraction of a message from a mailbox so that extractability count is not updated.

The following table provides an overview of the Mailbox Extract Abort service:

Category Description

System name

Mailbox Extract Abort Service

Graphical Process Modeler (GPM) categories

All Services, Internet B2B > Mailbox

Description

Signifies to the business process the unsuccessful extraction of a message from a mailbox.

Business usage

Use this service to signify to the business process that the extraction of a mailbox message was not completed successfully, so the message information (the extractability count) should not change.

Usage example

If SAP processing fails after purchase orders are extracted from the mailbox and the Mailbox Extract Abort service is run, the message extractability count does not change.

Preconfigured?

Yes

Requires third party files?

No

Platform availability

All supported Sterling B2B Integrator platforms

Related services

The Mailbox Extract Abort service works with the other Sterling B2B Integrator Mailbox services to provide mailboxing capability:
  • Mailbox Add service – Enables the insertion of messages into a mailbox.
  • Mailbox Extract Begin service – Enables the extraction of messages from a mailbox.
  • Mailbox Extract Commit service – Provides the ability for a business process to signal Sterling B2B Integrator Mailbox that the message extract request has successfully completed.
  • Mailbox Query service – Enables querying messages.
  • Mailbox Delete service – Enables deletion of messages.
  • Mailbox Evaluate All Automatic Rules service – Provides for the scheduling of automatic routing rules for Sterling B2B Integrator Mailbox.
  • Mailbox Evaluate Routing Rule service – Enables triggering of mailbox routing rules from a business process.

Application requirements

Nothing external to Sterling B2B Integrator is required to use this service.

Initiates business processes?

No

Invocation

The business process using this service must have performed a Mailbox Extract Begin on the target message.

Business process context considerations

The business process ID and branch ID must match the business process context that performed the Mailbox Extract Begin.

Returned status values

Returned status values:
  • Success – Normal completion.
  • User Permission Error – The user associated with the business process does not have permission to use the target mailbox.
  • Invalid Mailbox Error – This might indicate changes in the assignment of virtual mailbox roots which would disallow the extract process.
  • Invalid Mailbox Parameter Error – An error occurred passing parameters to this service such as a message ID in an invalid format.
  • Message Not Found Error – The requested message cannot be found for extraction.
  • Message Not Extractable Error – The target message extraction policy forbids extraction.
  • Mailbox Extract Invalid State Error – The current business process has not performed an Extract Begin.
  • Mailbox Repository Error – A generic error associated with the mailbox repository occurred.
  • Mailbox Service Error – A generic error associated with the mailbox service occurred.

Restrictions

This service cannot be used against a target message until the Mailbox Extract Begin service is called for that message. Additionally, the business process that calls this service must have the same business process ID and branch ID as the business process that called the Mailbox Extract Begin service.

Testing considerations

Troubleshooting information for this service can be found in Sterling B2B Integrator Mailbox log files.

How the Mailbox Extract Abort Service Works

Use the Mailbox Extract Abort service to recover from Mailbox Extract Begin service failures. The Mailbox Extract Abort service releases the lock that the business process has on the message. If the extract policy of the message is a count, this service returns the count to the value it was before the Mailbox Extract Begin service was run.

For example, the Mailbox Extract Begin service attempts to extract a message with an extractable count of one. The message is extractable and available, so the Mailbox Extract Begin service extracts the message and decrements the extractable count to zero. During the extraction, the communication protocol has an error. The Mailbox Extract Abort service is started. The Mailbox Extract Abort service increments the Extractable Count by one, allowing a subsequent business process to extract the message.

It resets the extractable count of the message to one so that the business process can attempt to extract the file the next time the Mailbox Extract Begin service is run.

Business Process Example

The following BPML aborts the extraction of message 1234 from Sterling B2B Integrator Mailbox. If it is assumed message 1234 has been successfully extracted by business process ID=789, branch ID=456, the BPML will succeed if run by a business process with ID=789 and branch ID=456.

<operation name="Mailbox ExtractBegin Service">
       <participant name="MailboxExtractBegin"/>
           <output message="ExtractBeginRequest">
               <assign to="." from="*"></assign>
               <assign to="MessageID">1234</assign>
            </output>
             <input message="inmsg">
                 <assign to="." from="*"></assign>
            </input>
    </operation> 
<!-- Abort Extract Operation. -->
    <operation name="Mailbox ExtractAbort Service">
       <participant name="MailboxExtractAbort"/>
           <output message="ExtractAbortRequest">
               <assign to="." from="*"></assign>
               <assign to="MessageID">1234</assign>
          </output>
           <input message="inmsg">
               <assign to="." from="*"></assign>
           </input>
   </operation>

Implementing the Mailbox Extract Abort Service

To implement the Mailbox Extract Abort service for use in a business process:
  1. Create an Mailbox Extract Abort service configuration. For information, see Managing Services and Adapters.
  2. Configure the Mailbox Extract Abort service. For information, see Configuring the Mailbox Extract Abort Service.
  3. Use the Mailbox Extract Abort service in a business process.

Configuring the Mailbox Extract Abort Service

GPM Configuration

The following table describes the fields used to configure the Mailbox Extract Abort service in the GPM:

Field Description

Config

Name of the adapter configuration.

MessageID

ID of the stored message. Required. Valid values are numbers >=0 in traditional mailboxes and in UUID format in Global Mailbox.

UseGlobalMailboxes

Whether to use only Global Mailbox or only traditional Sterling B2B Integrator mailboxes. The following values are valid:
  • Yes - The Global Mailbox is used. The UseGlobalMailboxes parameter is displayed in the business process XML, with the value set to YES.
  • No (default) - The Global Mailbox is not used. The UseGlobalMailboxes parameter is displayed in the business process XML, with the value set to NO.

Output from Service to Business Process

The following table contains the parameter passed from the Mailbox Extract Abort service to a business process:

Parameter Description

MessageID

ID of the stored message.