Navigation

  • index
  • next |
  • previous |
  • AdapLink v5.4.5 documentation »
  • Configuration »

Configuring AdapLink Service message delivery policy¶

At certain times, AdapLink requires messages to be delivered to the end users (like error message, etc).

The exact delivery method needs to be configured by the server administrator with the help of message configuration file parameters.

Message Configuration file¶

Location: $AdapLink_service\acconfig\alink.msg.config.props.

If the configuration file is not yet present at the respective location, then the message handler factory just before creating a message will also auto generate a file with the default values.

msg.transport.nature¶

Parameter ‘msg.transport.nature’ governs the overall nature of message delivery. The default nature is to save messages locally on the server file system.

Save messages locally on the Server file system (Default)¶

ac.msg.transport.nature=localfile

If message is saved locally, then it is administrators responsibility to deliver the message to the end user as all messages are saved locally.

The locally saved file contains human readable text, which contains message header (From, TO, CC, BCC, Subject), body, etc. which can be further used by the administrator when manually delivering the message.

Send message via trusted email server¶

ac.msg.transport.nature=mail

If the policy is to send message by email, then additional parameters need to be configured. The additional parameters include JavaMail related parameters.

ac.msg.admin. prefix parameters¶

ac.msg.admin. prefix parameters are used to configure administrator details.

Default values:

# Server Administrator details
ac.msg.admin.name=AdapLink Administrator
ac.msg.admin.email=AdapLinkAdmin@localhost

ac.msg.automatic. prefix parameters¶

ac.msg.automatic. prefix parameters are used to configure automatic mailer details.

Default values:

# Server automatic mailer details
ac.msg.automatic.name=AdapLink Service
ac.msg.automatic.email=AdapLinkAuto@localhost

JavaMail parameters¶

AdapLink relies on JavaMail API to send emails.

For JavaMail reference:

http://java.sun.com/products/javamail/javadocs/com/sun/mail/smtp/package-summary.html#package_description

http://java.sun.com/products/javamail/FAQ.html

http://java.sun.com/products/javamail/Third_Party.html

Standard parameters¶

# Transport layer
mail.transport.protocol=smtp
mail.smtp.host=localhost
mail.smtp.port=25

# [Optional] Address for handling Bounced Messages
mail.smtp.from=AdapLinkReply@localhost

Use SSL to connect SMTP server [Optional]¶

# if SSL
mail.smtp.port=465
mail.smtp.socketFactory.port=465
mail.smtp.socketFactory.class=javax.net.ssl.SSLSocketFactory
mail.smtp.socketFactory.fallback=false

Login and password for mail server authentication [Optional]¶

# SMTP send mail server Authentication
mail.smtp.auth=true
mail.smtp.user=username
mail.smtp.password=password

Configuration errors¶

Some sentences are comments and they always starts with #.

Incorrect:

Transport layer

[Optional] Address for handling Bounced Messages

Correct:

#Transport layer

#[Optional] Address for handling Bounced Messages

SMTP Server Error Debugging¶

To start with, look at server log files at $AdapLink_serviceapache-tomcat\logs\

Assumption: Email ID is assumed to be user@localhost; you need to replace with a valid ID of your choice.

Error message 501 Syntax error, ...¶

Complete message: Error message 501 Syntax error, parameters in command “MAIL FROM:Administrator<user@localhost>” unrecognized or missing

Caused by: com.sun.mail.smtp.SMTPSendFailedException: 501 Syntax error, parameters in command "MAIL FROM:Administrator<user@localhost>" unrecognized or missing

         at com.sun.mail.smtp.SMTPTransport.issueSendCommand(SMTPTransport.java:1388)
         at com.sun.mail.smtp.SMTPTransport.mailFrom(SMTPTransport.java:959)
         at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:583)
         at javax.mail.Transport.send0(Transport.java:169)
         at javax.mail.Transport.send(Transport.java:98)
         at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1128)
         ... 30 more

This could be due to an older SMTP server version.

Trial and error based solutions:

Solution 1:

mail.smtp.from=user@localhost

Solution 2:

If solution 1 fails then comment the above key value pair as below

#mail.smtp.from=user@localhost

Logo

Table Of Contents

  • Configuring AdapLink Service message delivery policy
    • Message Configuration file
    • msg.transport.nature
      • Save messages locally on the Server file system (Default)
      • Send message via trusted email server
    • ac.msg.admin. prefix parameters
    • ac.msg.automatic. prefix parameters
    • JavaMail parameters
      • Standard parameters
      • Use SSL to connect SMTP server [Optional]
      • Login and password for mail server authentication [Optional]
    • Configuration errors
    • SMTP Server Error Debugging
      • Error message 501 Syntax error, ...

Previous topic

Configuring AdapLink Service database connection

Next topic

Installing JDBC Drivers

This Page

  • Show Source

Quick search

Enter search terms or a module, class or function name.

Navigation

  • index
  • next |
  • previous |
  • AdapLink v5.4.5 documentation »
  • Configuration »
© Copyright 2010, AdapChain Inc.