Login  
Search All Forums
Dart Home | PowerTCP Mail for ActiveX | Custom Development Reply | PowerTCP Mail for ActiveX Topics | Forums   
AuthorForum: PowerTCP Mail for ActiveX
Topic: SMTP Exchange Interaction
User268

Posts: 8
Member Since: 11/19/01
posted January 31, 2002 4:25 PM

We have a problem with the SMTP component * only * when sending messages to an Exchange 5.5 SP4 Internet Mail Connector. We login to the recipient's mail server, send our message, then logout. If we send another message to the same recipient (with or without intervening messages to different mail servers), the Progress event confirms that the message is successfully sent and a trace of the conversation shows the server received it. Yet only the very first message to that address ever appears in the recipient's mailbox.

If our program releases your component (set = nothing) and re-instantiates it (set = new smtp), the message goes through -- 1st time only, then we're back where we started.

Any thoughts? Thanks.

Ron
ron@zutz.com
K M Drake



From: Utica, NY USA
Posts: 3406
Member Since: 07/14/00
posted February 1, 2002 10:03 AM


Hi Ron,
Does this happen with the Smtp Client sample?
We use Exchange 5.5 (not sure of the SP), and I do not have any problem sending multiple messages with the sample.
-ken

K M Drake
Dart Tech Support
User216

Posts: 5
Member Since: 02/01/02
posted February 1, 2002 3:03 PM

I'm working with Ron to troubleshoot this issue.

The next reply is the Exchange Internet Mail Connector protocol log. This log shows the connection for two messages, but only the first is delivered to the recipient mailbox.

The first message, with subject "ExRay:SMTP:admin@testir.com:1385350532" gets deliverd, yet the second message with subject "ExRay:SMTP:admin@testir.com:769130892" does not.

In the SMTP protocol conversation, the "Message-ID" field are identical. This seems like the problem. Some versions of Exchange think the second message must be a duplicate.

Is there a way to change the "Message-ID" field to force uniqueness?

--- Greg


User216

Posts: 5
Member Since: 02/01/02
posted February 1, 2002 3:08 PM

====== SMTP Protocol Log First Message =====
2/1/02 10:15:53 AM : A connection was accepted from DEVELOPPROTO01.
2/1/02 10:15:53 AM : <<< IO: lEHLO DEVELOPPROTO01
2/1/02 10:15:53 AM : <<< EHLO DEVELOPPROTO01
2/1/02 10:15:53 AM : >>> 250-nt4_01.testir.com Hello [DEVELOPPROTO01]
250-XEXCH50
250-HELP
250-ETRN
250-DSN
250-SIZE 0
250-AUTH LOGIN
250 AUTH=LOGIN
2/1/02 10:15:53 AM : <<< IO: lMAIL FROM:<bkraft@intellireach.com> SIZE=408 RET=HDRSl
2/1/02 10:15:53 AM : <<< MAIL FROM:<bkraft@intellireach.com> SIZE=408 RET=HDRS
2/1/02 10:15:53 AM : >>> 250 OK - mail from <bkraft@intellireach.com>; can accomodate 408 bytes
2/1/02 10:15:53 AM : <<< IO: lRCPT TO:<admin@testir.com> NOTIFY=NEVERl
2/1/02 10:15:53 AM : <<< RCPT TO:<admin@testir.com> NOTIFY=NEVER
2/1/02 10:15:53 AM : >>> 250 OK - Recipient <admin@testir.com>
2/1/02 10:15:53 AM : <<< IO: lDATAl
2/1/02 10:15:53 AM : <<< DATA
2/1/02 10:15:53 AM : >>> 354 Send data. End with CRLF.CRLF
2/1/02 10:15:53 AM : <<< IO: lTo: admin@testir.com
Content-Type: text/plain; charset=ISO-8859-1
From: bkraft@intellireach.com
Subject: ExRay:SMTP:admin@testir.com:1385350532
Content-Transfer-Encoding: Quoted-Printable
MIME-Version: 1.0
Message-ID: <0000000105039907d2@[192.168.168.205]>
Date: Fri, 01 Feb 2002 10:19:00 -0500

This is a test of your SMTP settings=0D=0D=
bkraft@intellireach.coml
2/1/02 10:15:53 AM : <<< IO: l.l
2/1/02 10:15:53 AM : >>> 250 OK
2/1/02 10:15:53 AM : <<< IO: lQUITl
2/1/02 10:15:53 AM : <<< QUIT
2/1/02 10:15:53 AM : >>> 221 closing connection
User216

Posts: 5
Member Since: 02/01/02
posted February 1, 2002 3:11 PM

====== SMTP Protocol Log Second Message =====

This is the message that gets accepted, but never delivered. The Message-ID field in the header are identical to the first message.


2/1/02 10:16:03 AM : A connection was accepted from DEVELOPPROTO01.
2/1/02 10:16:03 AM : <<< IO: lEHLO DEVELOPPROTO01l
2/1/02 10:16:03 AM : <<< EHLO DEVELOPPROTO01
2/1/02 10:16:03 AM : >>> 250-nt4_01.testir.com Hello [DEVELOPPROTO01]
250-XEXCH50
250-HELP
250-ETRN
250-DSN
250-SIZE 0
250-AUTH LOGIN
250 AUTH=LOGIN
2/1/02 10:16:03 AM : <<< IO: lMAIL FROM:<bkraft@intellireach.com> SIZE=515 RET=HDRSl
2/1/02 10:16:03 AM : <<< MAIL FROM:<bkraft@intellireach.com> SIZE=515 RET=HDRS
2/1/02 10:16:03 AM : >>> 250 OK - mail from <bkraft@intellireach.com>; can accomodate 515 bytes
2/1/02 10:16:03 AM : <<< IO: lRCPT TO:<admin@testir.com> NOTIFY=NEVERl
2/1/02 10:16:03 AM : <<< RCPT TO:<admin@testir.com> NOTIFY=NEVER
2/1/02 10:16:03 AM : >>> 250 OK - Recipient <admin@testir.com>
2/1/02 10:16:03 AM : <<< IO: lDATAl
2/1/02 10:16:03 AM : <<< DATA
2/1/02 10:16:03 AM : >>> 354 Send data. End with CRLF.CRLF
2/1/02 10:16:03 AM : <<< IO: lTo: admin@testir.com
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: Quoted-Printable
Message-ID: <0000000105039907d2@[192.168.168.205]>
Date: Fri, 01 Feb 2002 10:19:00 -0500
From: bkraft@intellireach.com
Subject: ExRay:SMTP:admin@testir.com:769130892
MIME-Version: 1.0

This is a test of your SMTP settings=0D=0D=
bkraft@intellireach.coml
2/1/02 10:16:03 AM : <<< IO: l.l
2/1/02 10:16:03 AM : >>> 250 OK
2/1/02 10:16:03 AM : <<< IO: lQUITl
2/1/02 10:16:03 AM : <<< QUIT
2/1/02 10:16:03 AM : >>> 221 closing connection


K M Drake



From: Utica, NY USA
Posts: 3406
Member Since: 07/14/00
posted February 1, 2002 3:30 PM


Hi,
Again, when I use the Smtp Client sample to send the same message twice, I do not see the problem, and the Message-IDs are different for both messages. Use Trace with the Smtp sample to create a log while sending two messages, then examine the log.
If you are unable to reproduce this with the sample, please pursue this through our paid support program.
Thanks,
-ken

K M Drake
Dart Tech Support
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted February 1, 2002 5:22 PM


Greg,

I think I see what's going on. When we generate the header, the string is generated based on time ticks since the process started. It looks to me like it's down to the millisecond. I really don't see how you can send 2 messages within a millisecond of each other, but evidently you have found a way.

I'll put in a request to make this process a little more unique (like using a guid or something).

I don't see that this is going to happen to you very often in the real world, but if it does, you'll have to put some kind of delay in between sending the messages (like a for next loop that delays for a couple ms)

Unfortunately, there is no way for you to remove this header line as it is re-generated by us just prior to setting.

Sorry I could not offer more.

Tony Priest
Dart Tech Support

User216

Posts: 5
Member Since: 02/01/02
posted February 1, 2002 5:39 PM

Thanks Ken and Tony.

The sample SMTP client works fine. No duplicate message-id's in the protocol logs.

It could be the way we are using the control that is somehow allowing the second and ...n messages sent to keep the same message-id. Stopping or re-instatiating the control fixes the problem, but not the prefered way to solve this issue.

I know we are not sending a message every millisecond (I can't press the "Send" button that fast :)), so it must be somehow related to the way the control is used in our application.

--- greg
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted February 1, 2002 8:29 PM


Maybe you need to reset the message before you send. I think the sample does. I don't have it with me now, but as I recall, I put Smtp1.Message.Content = "" before I make the message.

That's my best guess.

Tony
N/A posted March 19, 2002 4:43 PM

Just for the record, I was having this exact same issue. This suggestion of reseting the message content solved the problem for me. To be exact I cleared both the message and the header content before sending each message.

Smtp1.Message.Content(msgMessage) = ""
Smtp1.Message.Content(msgHeader) = ""

I was working on this issue for almost a full day and was driving me mad! Thanks a lot Tony.

-Tony Kirk
Reply | PowerTCP Mail for ActiveX Topics | Forums   
This site is powered by PowerTCP WebServer Tool PowerTCP WebServer for ActiveX