
1298
DEVELOPING
COLDFUSION 9 APPLICATIONS
Using External Resources
Las
t
upda
te
d 8/5/2010
You can also set the following values in each outgoing message: source-ton, source-npi, source-address, destination-
ton, destination-npi, and service-type. The message field names differ from the configuration file property names.
Handling incoming messages
The SMS event gateway handles messages that are contained in deliver_sm PDUs. These PDUs request the gateway to
deliver one of the following types of message:
•
A user- or application-generated text message
•
A message disposition response
Note:
The SMS event gateway does not handle messages that are contained in data_sm PDUs.
The event gateway sends the object to event gateway services, which delivers it to the listener CFC. The CFEvent object
that the listener CFC receives contains the following fields:
Note:
Consider SMS messages and any other data that enters through an Event Gateway handler to be potentially hostile.
For example, if SMS data is archived in a SQL database, an attacker could construct a message that modifies or deletes
data, or even takes over the SQL Server. Therefore, be sure to perform Event Gateway input validation, just as you would
validate web form input.
transient-retry
no
Gateway behavior when the SMSC returns an error that indicates a transient error, where it
may be able to accept the message in the future:
•
yes
The gateway attempts to resend the message. Retrying is useful if the gateway is in
asynchronous mode, where the CFML
SendGatewayMessage
function does not return
an error.
•
no
The gateway does not retry sending the message.
cfc-method
onIncomingMessage
Listener CFC method for ColdFusion to invoke when the gateway gets incoming messages.
destination-ton
1
Default TON of addresses for outgoing messages.
destination-npi
1
Default NPI of addresses for outgoing messages.
service-type
empty string
Type of messaging service; can be empty or one of the following values: CMT, CPT, VMN,
VMA, WAP, or USSD.
system-type
empty string
Type of system (ESME, External Short Message Entity ); used when binding to the SMSC.
Some SMSCs might be able to send responses that are specific to a given type of ESME.
Normally set to SMPP.
receive-timeout
-1 (do not time out)
The time-out, in seconds, for trying to receive a message from the SMSC after it establishes
a connection. To wait indefinitely until a message is received, set the
receive-timeout
to -1.
ping-interval
60
Number of seconds between EnquireLink messages that the event gateway sends to the
server to verify the health of the connection.
retries
-1 (try forever)
Number of times to retry connecting to the SMSC to send a message before the gateway
goes into a failed state. If the gateway is in a failed state, the
getStatus
method returns
FAILED, and theColdFusion Administrator shows the gateway status as Failed. The gateway
must be restarted before it can be used.
retry-interval
10
Number of seconds between connection retries.
Property
Default
Description
Содержание COLDFUSION 9
Страница 1: ...Developing Applications ADOBE COLDFUSION 9...