Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Newsletter/mailing list how-to question (not really related to programming)

Newsletter/mailing list how-to question (not really related to programming)

Scheduled Pinned Locked Moved The Lounge
questiondatabasesysadminhelpannouncement
14 Posts 9 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Anton Afanasyev
    wrote on last edited by
    #1

    So, I have a need to make a mailing applications of sorts. I have people subscribing to receive notifications about certain parts on a website, e.g. what new articles there are on a certain topic, etc. Pretty similar to CP's own newsletter functionality. I have the whole thing planned out, but I just started thinking about what would happen if, say, there was a power outage while the application was running and sending out emails. Naturally, the server(s) would be on backup power, but, lets say the backup power fails, and the server shuts down. So then half the emails is sent, the other half isnt. What is the best thing to do when the server goes back up? Do nothing and just ignore unsent emails? Or perhaps send them all over again? The only solution I can think of is, since each and every email is sent separately (the content is different), is to loop through subscribers, one by one, generate an email, send, update database record somewhere saying that an email was sent already to that subscriber. Then move to the next one. And in case of a power outage, the program would just pick up from the point where it stopped - since it has the last person it sent the email to. Does this sound like a good way? Any suggestions/ideas? How does CP send its emails? I remember there was a problem a while ago, where some people would receive an email more than once, or receive it very-very later, or not receive one at all.

    "impossible" is just an opinion.

    C L S 3 Replies Last reply
    0
    • A Anton Afanasyev

      So, I have a need to make a mailing applications of sorts. I have people subscribing to receive notifications about certain parts on a website, e.g. what new articles there are on a certain topic, etc. Pretty similar to CP's own newsletter functionality. I have the whole thing planned out, but I just started thinking about what would happen if, say, there was a power outage while the application was running and sending out emails. Naturally, the server(s) would be on backup power, but, lets say the backup power fails, and the server shuts down. So then half the emails is sent, the other half isnt. What is the best thing to do when the server goes back up? Do nothing and just ignore unsent emails? Or perhaps send them all over again? The only solution I can think of is, since each and every email is sent separately (the content is different), is to loop through subscribers, one by one, generate an email, send, update database record somewhere saying that an email was sent already to that subscriber. Then move to the next one. And in case of a power outage, the program would just pick up from the point where it stopped - since it has the last person it sent the email to. Does this sound like a good way? Any suggestions/ideas? How does CP send its emails? I remember there was a problem a while ago, where some people would receive an email more than once, or receive it very-very later, or not receive one at all.

      "impossible" is just an opinion.

      C Offline
      C Offline
      Chris Maunder
      wrote on last edited by
      #2

      We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

      cheers, Chris Maunder

      CodeProject.com : C++ MVP

      D A P S R 6 Replies Last reply
      0
      • C Chris Maunder

        We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

        cheers, Chris Maunder

        CodeProject.com : C++ MVP

        D Offline
        D Offline
        Douglas Troy
        wrote on last edited by
        #3

        :laugh:


        :..::. Douglas H. Troy ::..
        Bad Astronomy |VCF|wxWidgets|WTL

        1 Reply Last reply
        0
        • C Chris Maunder

          We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

          cheers, Chris Maunder

          CodeProject.com : C++ MVP

          A Offline
          A Offline
          Anton Afanasyev
          wrote on last edited by
          #4

          I've seen people naming their servers after planets, rivers, lakes, constellations, or even car models. But people...man, Chris, if it has come to this, you honestly need to get out more.

          :badger:

          1 Reply Last reply
          0
          • C Chris Maunder

            We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

            cheers, Chris Maunder

            CodeProject.com : C++ MVP

            P Offline
            P Offline
            Paul Conrad
            wrote on last edited by
            #5

            Chris Maunder wrote:

            Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next.

            :eek: Poor Mike

            Chris Maunder wrote:

            His Mondays are brutal

            :laugh: What about the remainder of the week?

            "The clue train passed his station without stopping." - John Simmons / outlaw programmer "Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon

            1 Reply Last reply
            0
            • A Anton Afanasyev

              So, I have a need to make a mailing applications of sorts. I have people subscribing to receive notifications about certain parts on a website, e.g. what new articles there are on a certain topic, etc. Pretty similar to CP's own newsletter functionality. I have the whole thing planned out, but I just started thinking about what would happen if, say, there was a power outage while the application was running and sending out emails. Naturally, the server(s) would be on backup power, but, lets say the backup power fails, and the server shuts down. So then half the emails is sent, the other half isnt. What is the best thing to do when the server goes back up? Do nothing and just ignore unsent emails? Or perhaps send them all over again? The only solution I can think of is, since each and every email is sent separately (the content is different), is to loop through subscribers, one by one, generate an email, send, update database record somewhere saying that an email was sent already to that subscriber. Then move to the next one. And in case of a power outage, the program would just pick up from the point where it stopped - since it has the last person it sent the email to. Does this sound like a good way? Any suggestions/ideas? How does CP send its emails? I remember there was a problem a while ago, where some people would receive an email more than once, or receive it very-very later, or not receive one at all.

              "impossible" is just an opinion.

              L Offline
              L Offline
              l a u r e n
              wrote on last edited by
              #6

              you would want to keep track of which mailshot was sent to which user and the results (bounce / no bounce / failed / etc) so that: 1. you can pick up where you left off after the hypothetical power outage 2. you can stop sending to problem addresses after (say) 3 attempts (useful for not being permanently banned from the whole domain) each email is unique usually anyway even if it just has a unique tracking beacon on it so the extra overhead really isn't much hth :)

              "mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them"

              A 1 Reply Last reply
              0
              • C Chris Maunder

                We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

                cheers, Chris Maunder

                CodeProject.com : C++ MVP

                S Offline
                S Offline
                Stuart Dootson
                wrote on last edited by
                #7

                And we appreciate the personal touch - really, we do, Chris.

                1 Reply Last reply
                0
                • C Chris Maunder

                  We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

                  cheers, Chris Maunder

                  CodeProject.com : C++ MVP

                  R Offline
                  R Offline
                  Rajesh R Subramanian
                  wrote on last edited by
                  #8

                  Not to mention how Mike has to painstakingly click "Authorize" every time someone posts a message somewhere in the site. Having said that, his Mondays still ought to be brutal.

                  1 Reply Last reply
                  0
                  • A Anton Afanasyev

                    So, I have a need to make a mailing applications of sorts. I have people subscribing to receive notifications about certain parts on a website, e.g. what new articles there are on a certain topic, etc. Pretty similar to CP's own newsletter functionality. I have the whole thing planned out, but I just started thinking about what would happen if, say, there was a power outage while the application was running and sending out emails. Naturally, the server(s) would be on backup power, but, lets say the backup power fails, and the server shuts down. So then half the emails is sent, the other half isnt. What is the best thing to do when the server goes back up? Do nothing and just ignore unsent emails? Or perhaps send them all over again? The only solution I can think of is, since each and every email is sent separately (the content is different), is to loop through subscribers, one by one, generate an email, send, update database record somewhere saying that an email was sent already to that subscriber. Then move to the next one. And in case of a power outage, the program would just pick up from the point where it stopped - since it has the last person it sent the email to. Does this sound like a good way? Any suggestions/ideas? How does CP send its emails? I remember there was a problem a while ago, where some people would receive an email more than once, or receive it very-very later, or not receive one at all.

                    "impossible" is just an opinion.

                    S Offline
                    S Offline
                    Simon P Stevens
                    wrote on last edited by
                    #9

                    So hang on. Plan A is just send the emails. In the case of a power failure, Plan B is rely on backup power. In the case that backup power fails, You need a plan C? Who cares. Think of the amount of effort you'll put into the plan C stuff compared to the amount of times you will actually use it. Sod it, just take the simplest possible option[^] and resend all the emails. So half your readers may get 2 copies one week, they aren't going to care. Maybe this changes if your sever is somewhere without a reliable power supply (like Antarctica maybe), and power failures happen every time your home made generator runs low on diesel. Just my 2 cents ;) .

                    Simon

                    A 1 Reply Last reply
                    0
                    • S Simon P Stevens

                      So hang on. Plan A is just send the emails. In the case of a power failure, Plan B is rely on backup power. In the case that backup power fails, You need a plan C? Who cares. Think of the amount of effort you'll put into the plan C stuff compared to the amount of times you will actually use it. Sod it, just take the simplest possible option[^] and resend all the emails. So half your readers may get 2 copies one week, they aren't going to care. Maybe this changes if your sever is somewhere without a reliable power supply (like Antarctica maybe), and power failures happen every time your home made generator runs low on diesel. Just my 2 cents ;) .

                      Simon

                      A Offline
                      A Offline
                      Anton Afanasyev
                      wrote on last edited by
                      #10

                      Thats exactly what I myself was thinking...And since Canada is a little far from Antarctica...you get the point :) Thanks for the input, guess I'm not the only one thinking this way.

                      :badger:

                      S 1 Reply Last reply
                      0
                      • L l a u r e n

                        you would want to keep track of which mailshot was sent to which user and the results (bounce / no bounce / failed / etc) so that: 1. you can pick up where you left off after the hypothetical power outage 2. you can stop sending to problem addresses after (say) 3 attempts (useful for not being permanently banned from the whole domain) each email is unique usually anyway even if it just has a unique tracking beacon on it so the extra overhead really isn't much hth :)

                        "mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them"

                        A Offline
                        A Offline
                        Anton Afanasyev
                        wrote on last edited by
                        #11

                        Thanks for the suggestions:) This would be the ideal situation. If I am not mistaken, our mail server is configured in a way that it would keep track of the bounces, failed delivery, etc., so I don't wont to get involved in that. Though I'll keep this in mind for any future related work. As for the power outage/keeping track....I am going to go with Simon Stevens' reply just below yours. In the last 3-4 years, the servers only went down once - we changed the hosting company, and even that was only for a couple of minutes. I understand that this really isnt any indication of how well they are set up, but I don't think that even if the server does go down, then the people who receive their regularly scheduled spam newsletter twice will care much. Thanks anyway :), and both points are very valid.

                        "impossible" is just an opinion.

                        1 Reply Last reply
                        0
                        • C Chris Maunder

                          We actually send them out one by one, each email personally written and delivered by Mike. I simply write the foreword now - Mike is the one who actually looks up everyone's address, customises it, sends it, ticks off 'Mail Sent' on the spreadsheet and then moves to the next. His Mondays are brutal

                          cheers, Chris Maunder

                          CodeProject.com : C++ MVP

                          J Offline
                          J Offline
                          Jorgen Sigvardsson
                          wrote on last edited by
                          #12

                          Is Mike one of your (in)famous hamsters? ;)

                          -- Kein Mitleid Für Die Mehrheit

                          C 1 Reply Last reply
                          0
                          • A Anton Afanasyev

                            Thats exactly what I myself was thinking...And since Canada is a little far from Antarctica...you get the point :) Thanks for the input, guess I'm not the only one thinking this way.

                            :badger:

                            S Offline
                            S Offline
                            Simon P Stevens
                            wrote on last edited by
                            #13

                            Glad I could help. :)

                            Anton Afanasyev wrote:

                            Canada is a little far from Antarctica

                            Although I've heard it can get pretty cold up at the top end :laugh:

                            Simon

                            1 Reply Last reply
                            0
                            • J Jorgen Sigvardsson

                              Is Mike one of your (in)famous hamsters? ;)

                              -- Kein Mitleid Für Die Mehrheit

                              C Offline
                              C Offline
                              Chris Maunder
                              wrote on last edited by
                              #14

                              :rolleyes: No, I meant Michael Wilk[^]

                              cheers, Chris Maunder

                              CodeProject.com : C++ MVP

                              1 Reply Last reply
                              0
                              Reply
                              • Reply as topic
                              Log in to reply
                              • Oldest to Newest
                              • Newest to Oldest
                              • Most Votes


                              • Login

                              • Don't have an account? Register

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • World
                              • Users
                              • Groups