huwb
  •  huwb
  • 50.2% (Neutral)
  • YAF Forumling Topic Starter
2012-08-29T21:14:52Z
Hi.

I first posted a query on this some 10 or 11 months ago...

http://forum.yetanotherf...email-notifications.aspx 

...but it wasn't resolved. I decided to wait to the next release and retry which I have now done - unfortunately I seem to be getting the same problem and was wondering if someone could try and steer me in the right direction. I can't find anyone appearing to report an identical problem so I'm having to conclude it could be something on my side of the fence (but I'm darned if I can find it... :-))

Now running version 1.9.6.1 (18/3/2012) running on net framework 4. IIS as far as I am aware (this is a hosted platform not directly under my control).

I have a YAF board that has not yet gone 'live' so I am able to play around with multiple users and accounts. I have setup a number of test forums and have enabled notifications on new topics and posts to users. I am very comfortable with how this is configured within YAF and have checked that appropriate users have correct settings for notifications in their profiles.

Email generally is working OK - I can send emails between YAF users and the general email tests from YAF appear to work OK.

If I start afresh (restarting YAF) and get a test user to post a new topic in a forum then the users I have marked to watch the forum and receive a notification of this get the notification correctly - in the current test case I have there are 4 users enabled to receive 'new topic' notifications on the test forum and all receive the first notification email correctly - i.e.this is what I would expect and shows that the basic email system and notification system is working. Things then start to go downhill rapidly....

If I get the same test user (or another one - it doesn't have to be the same user) to then post another new topic in the same forum then only one of the 4 users previously successfully receives a notification of this - the other three don't. Depending on various combinations of who posts what when then various permutations of users get notification, but only ever ONE of the group monitoring the forum - the whole group of monitoring users never now all receive the notification emails - only ever one of them will get this. See the original post for a structured test of this - this appears to still be happening.

I realise that this all sounds a bit odd, but I have looked at this very carefully and it is driving me crazy.... I would class myself as 'tech savvy' and normally more than capable of setting up these types of things (hence the structured testing I've been doing) but this one is beating me.

Has anyone else seen this behaviour? Any suggestions on what might be happening??

There is nothing funny (in fact nothing) reported in the event log.

Help....? (and thanks...)

Huw
Sponsor
huwb
  •  huwb
  • 50.2% (Neutral)
  • YAF Forumling Topic Starter
2012-08-31T03:11:36Z
Hi.

Perhaps someone out there could just confirm that you are NOT seeing this problem with your existing implementations - i.e. are you comfortable that notifications are working OK with a recent release?

That would then help me - My logic tells me this is a YAF problem but I'm not seeing other people report it and I'd expect other's to have seen this issue? Clearly if its not a YAF problem and others are not seeing this then I'll have to try and figure out what's happening with my setup....

Thanks for your help on this.

Huw
Thantis
2012-08-31T12:49:02Z
Well, I cant help much with your problem, since from what you said your email seems to be setup properly, but I can confirm that my forum sends notifications correctly. I am sure one of the more knowledgeable folks will have ideas, just give it a day or two, sometimes it takes a bit.
huwb
  •  huwb
  • 50.2% (Neutral)
  • YAF Forumling Topic Starter
2012-08-31T14:10:05Z
Thanks Thantis - I appreciate the feedback. Just out of interest what version are you running on?

I was intrigued that, whilst I am registered to watch this post, I didn't get a notification of your reply :-)

Huw
tha_watcha
2012-08-31T15:04:15Z
Quote:

Has anyone else seen this behaviour? Any suggestions on what might be happening??

There is nothing funny (in fact nothing) reported in the event log.

Help....? (and thanks...)



Well under perfect conditions with 1.9.6.1 on my home server with a test mail server i was not able to reproduce this.

But since there are so many problems about the watch topic function there must be a serious problem.

FYI currently yaf didnt report any errors when the mail was not successfully send out.

I Posted the Zip file with the Updated dlls here:

http://forum.yetanotherf...on-t-work.aspx#post55802 

In this Build logging is enabled, there is also an updated sql script to solve some of the mail problems.
UserPostedImage
huwb
  •  huwb
  • 50.2% (Neutral)
  • YAF Forumling Topic Starter
2012-08-31T16:07:32Z
Thanks tha_watcha

I loaded the executables into the bin folder and restarted the app - anything else needed?

I tried to run the update script you provided in your previous post :

ALTER PROCEDURE [{databaseOwner}].[{objectQualifier}mail_list]
(
@ProcessID int
)
AS
BEGIN
DECLARE @UTCTIMESTAMP datetime

SET @UTCTIMESTAMP = GETUTCDATE()

BEGIN TRANSACTION TRANSUPDATEMAIL
UPDATE [{databaseOwner}].[{objectQualifier}Mail]
SET
ProcessID = NULL
WHERE
ProcessID IS NOT NULL AND SendAttempt > @UTCTIMESTAMP

UPDATE [{databaseOwner}].[{objectQualifier}Mail]
SET
SendTries = SendTries + 1,
SendAttempt = DATEADD(n,5,@UTCTIMESTAMP),
ProcessID = @ProcessID
WHERE
MailID IN (SELECT TOP 10 MailID FROM [{databaseOwner}].[{objectQualifier}Mail] WHERE SendAttempt < @UTCTIMESTAMP OR SendAttempt IS NULL ORDER BY SendAttempt, Created)
COMMIT TRANSACTION TRANSUPDATEMAIL

and got the response :

Incorrect syntax near 'TRANSUPDATEMAIL'.
No Results Returned.

Any thoughts why that wouldn't have run? (i ran in the DB query option in the maintenance area?)

Huw
tha_watcha
2012-08-31T16:40:17Z
Sorry i forgot you already have 1.9.6.1 so the update script needs to be


ALTER PROCEDURE [{databaseOwner}].[{objectQualifier}mail_list]
(
	@ProcessID int,
	@UTCTIMESTAMP datetime
)
AS
BEGIN
	BEGIN TRANSACTION TRANSUPDATEMAIL
		UPDATE [{databaseOwner}].[{objectQualifier}Mail]
		SET 
			ProcessID = NULL
		WHERE
			ProcessID IS NOT NULL AND SendAttempt > @UTCTIMESTAMP

		UPDATE [{databaseOwner}].[{objectQualifier}Mail]
		SET 
			SendTries = SendTries + 1,
			SendAttempt = DATEADD(n,5,@UTCTIMESTAMP),
			ProcessID = @ProcessID
		WHERE
			MailID IN (SELECT TOP 10 MailID FROM [{databaseOwner}].[{objectQualifier}Mail] WHERE SendAttempt < @UTCTIMESTAMP OR SendAttempt IS NULL ORDER BY SendAttempt, Created)
	COMMIT TRANSACTION TRANSUPDATEMAIL

	-- now select all mail reserved for this process...
	SELECT TOP 10 * FROM [{databaseOwner}].[{objectQualifier}Mail] WHERE ProcessID = @ProcessID ORDER BY SendAttempt, Created desc
END

UserPostedImage
huwb
  •  huwb
  • 50.2% (Neutral)
  • YAF Forumling Topic Starter
2012-08-31T17:12:25Z
sorry for being a pain tha_watch, but that seemed to get the same result :

Incorrect syntax near 'TRANSUPDATEMAIL'.

No Results Returned.

Don't worry about it (but thanks for trying...). I've done a little more testing and would report the following:

I have 5 users (lets call them u1,u2,u3,u4 and u5....) all watching one forum - I checked that they were all enabled to watch this correctly.

I got one of the users (u4) to post a new topic, after I had done a reinstall / restart of the application and also confirmed that the event log and mail SQL table were empty

As before, all 4 other users got the notification that I would have expected saying that a new topic had been posted by u4. This is what should happen.

I then went back and posted another new topic in the same forum by the same user (u4).

This time only one of the other users (u1) got a notification. I repeated the same thing a number of times (getting u4 to post a new topic) and u1 continually got the email but no-one else did.

I checked the event log and it was still clear. I ran the query to look at the mail table and again this was totally clear.

With a little manual dexterity I setup two browser sessions next to one another (:-)) and repeated the same action - getting u4 to post a new topic - this time I hit the mail table query request as quickly as I could following making the new post. I did this a few times just to be sure. In all 3 cases I 'caught' the email post to u1 being in the mail table but there was only that one entry - I didn't see any entry appearing for u2, u3 or u5 at all in the mail table.

I just repeated this again but in this case got u2 rather than u4 to post a new topic. In this case, u1 and now u4 got the notifications successfully. I tried this again and this was repeatable, u2 posting a new topic and two (rather than 4, as should be the case) notifications being sent out to u1 and u4. I also repeated the 'quick' query of the mail table and in this case I caught both email records as would be expected.

This seems to imply to me that the emails are not reaching the mail table (which i assume the mail task then picks up from and sends the mails...?). This also implies to me that the issue must be internal to YAF rather than anything after YAF has created the emails. I also wouldn't think that it is the mail task, as the problem appears to be happening before the entries get put in the mail database table (or don't get put in , as the case may be)?

Anyway, enough rambling - I think I'll have to give up on this. I'm still bemused that no-one else is seeing this and wondering what is unique about my setup that might be causing it....

Thanks all for your help.

Huw

guest
2012-09-24T14:45:33Z
We're having a similar issue. See my link below. In short, a user no longer gets an email notification if they don't re-visit the forum while logged in.

For example, I have a user watch a forum. New post is made, they get an email alert. If they click the site link (and are logged in) then the next time a post is made, they get another email alert. All good.

However, if they do NOT visit the forum (while logged in) then they will NOT get another email alert. For our purposes, we want them to get another email alert, regardless if they visit the site or not.

Like I said, not sure if it's related to your issue, but passing it on so us users can figure it out since YAF is silent on the issue.

http://forum.yetanotherf...criptions.aspx#post56396 

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved