How Messages Arrive in HP Desk [ HP DeskManager Customization ] MPE/iX 5.0 Documentation
HP DeskManager Customization
How Messages Arrive in HP Desk
There are certain things your application must do before incoming
messages will be accepted by HP Desk.
If the message is in a format that HP Desk does not recognize, your
application must first translate it to an ARPA format. Your program must
then:
* Build an MPE file with a unique name and in an appropriate group,
to hold the message.
* Transfer the header from the incoming message to this file. There
must be one header per message.
* Transfer the message to the file, if it is in ARPA Standard
format, or transfer the names of the MPE files which make up the
message if the message is in ARPA Reference format.
* Write a record containing the unique file name to the appropriate
IPC file, according to the format being used. The format of the
IPC files is defined in "Incoming FSC Messages" . The IPC
files are:
* ARPAIPC.MAILDB.HPOFFICE for ARPA Standard and ARPA
Compressed formats.
* AREFIPC.MAILDB.HPOFFICE for ARPA Reference format.
Moving messages out of HP Desk is done by the Master Truck, as for
normal transport, but moving messages into HP Desk is done by FSC
Slave Trucks. The FSC Slave Truck programs are:
* FSCARPA for ARPA Standard and Compressed formats.
* FSCAREF for ARPA Reference format.
If the FSC Slave Truck is not left running all day, it must be
started manually. The commands to start the FSC Slave Trucks are:
* :MAILFSCARPAON for ARPA Standard and Compressed
* :MAILFSCAREFON for ARPA Reference
The commands to stop the FSC Slave Trucks are:
* :MAILFSCARPAOFF for ARPA Standard and Compressed
* :MAILFSCAREFOFF for ARPA Reference
NOTE Only one type of FSC Slave Truck can run per system. The
application program may continue to write to the incoming IPC file
at the same time as the corresponding FSC Slave Truck is running.
How are Incoming Messages Dealt with?
The following elements are involved in transporting incoming messages to
HP Desk:
Messages are transported into HP Desk in the following way:
1. The incoming IPC file appropriate to the gateway format is opened
by the application.
2. Your external application program must convert incoming messages
before writing them to an MPE file. More than one level of
conversion may be needed for FSC files, for example, from a
foreign document interchange format to the appropriate HP Desk
format, or from a foreign to a Hewlett-Packard word processing
format. The application must also write the ARPA header at the
beginning of each message.
3. When all messages have been written to the MPE file or the MPE
file is full, the external application program closes the MPE
file.
4. The external application program writes a record containing the
MPE file name to the incoming IPC file.
5. The FSC Slave Truck, when started, reads the record in the IPC
file, and so can access the MPE file containing the messages.
6. The FSC Slave Truck converts the file to HP Desk internal format,
building a Distribution List from the information given in the
header. If the messages are adequately addressed, and are not too
large for the capacity of the database, they are transferred to
the HP Desk transport mechanism. From then on they are handled as
HP Desk messages. Finally, the MPE file is purged.
Incoming mail arriving through the FSC gatewayconsists of two or more
files which must be built by the application.
The first file contains records which reference other files containing
the messages--that is the incoming IPC file. This file will be called:
* ARPAIPC for ARPA Standard and Compressed formats.
* AREFIPC for ARPA Reference for.
The second file either contains the actual message itself (the nodefile),
or it references other files which will hold the data. This file can be
given any name.
The Slave Truck uses the information from the incoming IPC file to open
the specified nodefile and to import the message or messages onto the
database. After the contents of the nodefile have been successfully
imported the file will be purged. The IPC record has already been
deleted since any read performed on that type file will be destructive.
If the Slave Truck can't import the messages from the nodefile, it writes
a record to the corresponding Error IPC file (see "Errors While
Processing Incoming Messages" detailing which nodefile caused
problems and the nodefile will not be purged. Details of the error will
be written to the job listing of the Slave Truck processing the incoming
messages. Once the error has been corrected then the Error IPC file can
be copied directly to the incoming IPC file, and the Slave Truck will
again attempt to import the messages.
ARPA Standard and ARPA Compressed
Accepting input from a nodefile in either ARPA Standard or Compressed
format is quite straightforward. Each file must be restored to the
system and a record written to the ARPAIPC IPC file and then the FSCARPA
input Slave Truck program run to actually bring the messages into the
database.
Importing FSC messages is slightly different from the normal mail
delivery. Instead of planting messages directly onto location or node
queues, messages brought into HP Desk using an FSC link are attached to
the Out Tray of the Default User. This is done mainly to keep the code
for the Trucks separate from the rest of the system. Problems as how to
deal with a hierarchical address are performed by the Mailroom. As a
side effect of this system, a copy of any messages brought in using an
FSC link can be restrained through use of AUTOFILE on the Default User
and use can also be made of Distribution Lists stored in the List Area of
the Default User or the Public Distribution List of the mailnode. The
qualification of a list name appearing in an ARPA address header is
always performed before the message is attached to the Default User's Out
Tray. Once the message has been attached, notification is made to the
Mailroom requesting delivery of the message--just as if the attachment
had been made by a normal user session.
ARPA Reference format
HP Desk can also import messages in ARPA Reference format and the
operation is much the same as Standard or Compressed formats.
The file holding the message header and reference name (E file) must be
restored to the system along with any data files (C files) and of course
the names must match. The name of the E file should be written to
AREFIPC and the FSCAREF Slave Truck program initiated.
The Truck will read the header file and use the information from it to
construct an HP Desk Distribution Lists in the Default User's Out Tray.
It then imports each data file as a separate part of the message. Any
Distribution List items will be converted to HP Desk Distribution List
format. Addresses that can be recognized will be directly converted,
those that cannot will be given a (configurable) default address.
Errors While Processing Incoming Messages
If HP Desk cannot import a message (if for example, the database
temporarily has insufficient room for a large FSC message or there is
something wrong with the file), the name of the file containing that
message is placed in an IPC error file appropriate to its format.
The error files for the two formats are:
* ERRARPA.MAILDB.HPOFFICE for ARPA Standard or ARPA Compressed
formats.
* ERRAREF.MAILDB.HPOFFICE for ARPA Reference format.
Messages that have caused a problem can be resubmitted by copying the IPC
records back into the normal incoming IPC file once the cause of the
problem has been rectified. Use the following commands to do this:
FCOPY FROM=ERRARPA.MAILDB.HPOFFICE; TO=ARPAIPC.MAILDB.HPOFFICE
for ARPA Standard and Compresed, and
FCOPY FROM=ERRAREF.MAILDB.HPOFFICE; TO=AREFIPC.MAILDB.HPOFFICE
for ARPA Reference.
Then restart the appropriate Slave Truck if it has stopped (using
MAILFSCARPAON or MAILFSCAREFON).
Any messages which have already been imported successfully from the file
to HP Desk will be skipped when the file is read again.
Unrecognizable Addresses
It is possible that some incoming FSC messages will be formatted
incorrectly or contain invalid or unrecognizable address information.
For this reason, a Default User must be configured on the receiving HP
Desk system to receive such messages. This Default User must be an
existing user, such as General Delivery.
So that unrecognizable addresses can be investigated, all the information
in the original message header is kept, normally in part 2 of the
message.
The minimum amount of information that must be provided by a foreign
system in the FROM, TO, CC or BCC fields of the ARPA header, is a
surname. If an entry in these fields is recognized as a unique name by
the receiving HP Desk system, that unique addressee will receive a copy
of the message.
Any message that cannot be delivered to the address specified is
delivered according to the following table:
Name Present? | Node Present? | Message Sent to:
| |
-------------------------------------------------------------------------------------------
| |
Yes (Recognized) | Yes (Recognized) | Specified name at specified
| | address
| |
-------------------------------------------------------------------------------------------
| |
Yes (Unrecognized) | Yes (Local node) | Message will go to General
| | Delivery for the local node.
| |
-------------------------------------------------------------------------------------------
| |
Yes (Matches a configured | Yes or No | HP Desk name and address
foreign alias for specified | | corresponding to the
gateway) | | configured foreign alias
| |
-------------------------------------------------------------------------------------------
| |
Yes (Unrecognized) | Yes (Remote node) | Specified name at specified
| | address. This may eventually
| | go to General Delivery when it
| | arrives at the remote node if
| | the name is still
| | unrecognized.
| |
-------------------------------------------------------------------------------------------
| |
Yes (Unrecognized or malformed) | Yes (Unrecognized or | Default User
| malformed) |
| |
-------------------------------------------------------------------------------------------
| |
Yes (Malformed) | Yes (Recognized) | Default User
| |
-------------------------------------------------------------------------------------------
| |
Yes (Recognized) | Yes (Malformed) | Default User
| |
-------------------------------------------------------------------------------------------
| |
Yes (Unrecognized or recognized | No | Default User
but not unique) | |
| |
-------------------------------------------------------------------------------------------
| |
Yes (Recognized and unique HP | No | Specified name at configured
Desk user) | | address
| |
-------------------------------------------------------------------------------------------
| |
No | No | Default User
| |
-------------------------------------------------------------------------------------------
MPE/iX 5.0 Documentation