IBM Integration Bus, Version 9.0.0.8 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

EmailInput node

Use the EmailInput node to retrieve an email, with or without attachments, from an email server that supports Post Office Protocol 3 (POP3) or Internet Message Access Protocol (IMAP).

This topic contains the following sections:

Purpose

The EmailInput node receives an email, with or without attachments, from an email server that supports Post Office Protocol 3 (POP3) or Internet Message Access Protocol (IMAP). The body of the email message, and any attachments, are propagated in the Multipurpose Internet Mail Extensions (MIME) domain. All other information relating to the email is stored in the Root.EmailInputHeader MIME logical tree. The fields in this structure are described in the following table:
Element Location Element Data Type Description
Root.EmailInputHeader.To CHARACTER A comma-separated list of email addresses.
Root.EmailInputHeader.Cc CHARACTER A comma-separated list of email addresses.
Root.EmailInputHeader.From CHARACTER A comma-separated list of email addresses.
Root.EmailInputHeader.ReplyTo CHARACTER A comma-separated list of email addresses.
Root.EmailInputHeader.Subject CHARACTER The summary of the email content or the subject of the email.
Root.EmailInputHeader.Size INTEGER The size of the email, including any attachments.
Root.EmailInputHeader.SentDate CHARACTER The sent delivery date of the email.
This structure is propagated with each message written to the Out terminal of the EmailInput node. For more information about the MIME logical tree, see MIME parser and domain.

Using the EmailInput node in a message flow

To enable function that becomes available in IBM® Integration Bus fix packs, use the -f parameter on the mqsichangebroker command. For more information, see mqsichangebroker command.

You can configure the EmailInput node by using the node properties in the IBM Integration Toolkit. One possible use of the EmailInput node is to poll an email server for email messages at regular intervals, and to retrieve an email message when an email is available. The message flow receives the email from the email server as a MIME message.

In the following example message flow, the EmailInput node then passes the email message, which is associated with the MIME parser, onto a Filter node. The Filter node processes the email and directs it either to an MQHeader node or to a FileOutput node based on whether the email has an attachment or not.

If the email message does not contain an attachment, the Filter node sends the email to an MQHeader node for MQ Message Descriptor (MQMD) customization. The MQHeader node adds a WebSphere® MQ header to the message tree and passes the message onto the MQOutput node. The MQOutput node serializes the message body, for example; the text contents of the email, and places the body of the email on a WebSphere MQ queue for further processing.

If the email message does contain an attachment, the Filter node sends the email onto a FileOutput node. The FileOutput node then saves the attachment as a file named email_attachment.dat to a hard disk drive that you specify and, in this example, the text content of the email is discarded. You can achieve this example by creating the following message flow:

The diagram shows how you can use a EmailInput node to receive an email message, with or without attachments, from an email server, and how you can process the email.

The EmailInput node is contained in the Email drawer of the message flow node palette, and is represented in the IBM Integration Toolkit by the following icon:

This image shows the EmailInput node icon.

View the following sample to see how to use the EmailInput node:

You can view information about samples only when you use the product documentation that is integrated with the IBM Integration Toolkit or the online product documentation. You can run samples only when you use the product documentation that is integrated with the IBM Integration Toolkit.

Using configurable services for the EmailInput node

You can configure the EmailInput node to get the email server URL and security identity information from a configurable service. For details about creating, changing, reporting, and deleting the configurable services, see Changing connection information for the EmailInput node.

Using a security identity to authenticate with an email server

You can use the mqsisetdbparms command to set a user ID and password security identity object for the EmailInput node or EmailServer configurable service to use for accessing the email server. For detailed information about how to configure email server security identity support, see mqsisetdbparms command.

Configuring the EmailInput node

When you have put an instance of the EmailInput node into a message flow, you can configure it. For more information, see Configuring a message flow node. The properties of the node are displayed in the Properties view.

All mandatory properties for which you must enter a value (those that do not have a default value defined) are marked with an asterisk.

To configure the EmailInput node by using the node properties in the IBM Integration Toolkit to retrieve an email, with or without attachments, see Receiving an email.

Terminals and properties

The EmailInput node terminals are described in the following table.

Terminal Description
Failure The output terminal to which the message is routed if an EmailInput node failure is detected when a message is propagated, or an EmailInput node fails to access the email server. Connect the Failure terminal of this node to another node in the message flow to process errors.
Out The output terminal to which the message is routed if it has been propagated successfully. Connect the Out terminal of this node to another node in the message flow to process the message further, or send the message to an additional destination.
Catch The output terminal to which the message is routed if an exception is thrown downstream and caught by this node. Exceptions are caught only if this terminal is attached.

The following tables describe the EmailInput node properties.

The table column headed M indicates whether the property is mandatory. For example, the property is marked with an asterisk meaning that you must enter a value if no default is defined.

The column headed C indicates whether the property is configurable. For example, you can change the value when you add the message flow to the BAR file to deploy it.

The EmailInput node Description properties are described in the following table.

Property M C Default Description
Node name No No Email Input The name of the node.
Short description No No None A brief description of the node.
Long description No No None Text that describes the purpose of the node in the message flow.

The EmailInput node Basic properties are described in the following table.

Property M C Default Description mqsiapplybaroverride command property
Email server Yes Yes None The Email server property is defined either as a configurable service name, for example: myEmailConfigurableServiceName, or as a URL. A URL allows you to specify a protocol, host name, and port number, which is the minimum information you need to access the email server.

The URL must be made up of the following structure:

protocol://hostname:port

Where:

  • protocol can be pop3, pop3s, imap, or imops.
  • hostname is the Internet Protocol version 4 (IPv4) TCP/IP address or DNS-resolvable host name of the email host.
  • port is the port number that the email server is listening on for connections over POP3 or IMAP. You can enter an integer in the range 1- 65535.

For example: pop3://myemailserver.com:12345 or imap://myemailserver.com:56789.

You can configure secure pop3/imap with the following example: pop3s://myemailserver.com:12345 or imaps://myemailserver.com:56789. Then you must configure your JVM with the keystore/truststore credentials. See Viewing and setting keystore and truststore runtime properties at broker level

There is no default value for this property, however this property is mandatory, and therefore must be configured with a configurable service name or a URL.

You can obtain the hostname and port values from the email server or email server administrator.

emailServer
The EmailInput node Polling properties are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
Polling interval (in seconds) Yes Yes 5 The interval at which the EmailInput node polls the email server for new emails. waitInterval
The EmailInput node Security properties are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
Security identity No Yes None The name of the security identity object that is created and configured by the mqsisetdbparms command, which contains the user ID and password to be used by the broker to authenticate with the email server. Use the mqsisetdbparms command to set the security identity user ID and password to be accessed by the broker.

The default value for this property is None, which signifies that the user ID and password are not passed to the email server.

For more information about email server security identity support, see mqsisetdbparms command.

securityIdentity
The EmailInput node Retry properties are described in the following table. For more information about configuring the EmailInput node Retry properties, see Receiving an email.
Property M C Default Description mqsiapplybaroverride command property
Retry mechanism Yes No Short and Long Retry How the EmailInput node handles a message flow failure. Valid values are Failure, Short Retry, or Short and Long Retry.  
Retry threshold Yes Yes 0 The number of times to try the message flow transaction again when the Retry mechanism property value is set to Short Retry. retryThreshold
Short retry interval (in seconds) No Yes 0 The interval, in seconds, between each retry if the Retry threshold property value is not set to zero. shortRetryInterval
Long retry interval (in seconds) No Yes 300 The interval, in seconds, between each retry, if the Retry mechanism property value is Short and Long Retry and the retry threshold has been exhausted. longRetryInterval
Action on failing email Yes No Delete Email The action that the EmailInput node takes with the input data source after all attempts to process the contents fail. emailFailureAction
The EmailInput node Transactions properties are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
Transaction mode No Yes No The transaction mode on the EmailInput node determines if the rest of the nodes in the message flow are run under sync point. Valid values are Yes or No.  
The EmailInput node Instances properties are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
Additional instances pool No Yes Use Pool Associated with Message Flow The pool from which additional instances are obtained.

If you select the property value Use Pool Associated with Message Flow, additional instances are obtained from the message flow pool.

If you select the property value Use Pool Associated with Node, additional instances are allocated from the additional instances of the node, based on the number specified in the Additional instances property.

componentLevel
Additional instances No Yes 0 The number of additional instances that the EmailInput node can start if the Additional instances pool property is set to the value Use Pool Associated with Node. additionalInstances
The Monitoring properties of the node are described in the following table.
Property M C Default Description
Events No No None Events that you have defined for the node are displayed on this tab. By default, no monitoring events are defined on any node in a message flow. Use Add, Edit, and Delete to create, change or delete monitoring events for the node; see Configuring monitoring event sources using monitoring properties for details.

You can enable and disable events that are shown here by selecting or clearing the Enabled check box.


bc16200_.htm | Last updated Friday, 21 July 2017