Answers.Body: <p>a Couple of thoughts:</p>
  
  <ul>
  <li><p>The Site URL is not the issue. Yes it has changed but I've confirmed
  older URLs have not been deprecated - and are fully functional. </p></li>
  <li><p>I just verified on a site/project that Using 1.5.3, Civi 4.6.26 on D7 recurring job starts and finishes successfully - with a standard CiviCRM cron (set job to ON on scheduled jobs page)</p></li>
  <li><p>You definitively want no PDF receipts to go out with your Email<br>
  receipts. If you are still getting DOMPDF errors - do you have any<br>
  other custom functionality that's trying to create/attach a PDF?</p></li>
  <li><p>The recurring payments job - sends the tokens to iATSPayments -> and 
  immediately receives a transaction ID. There is no IPN. </p></li>
  <li><p>Try this: go to your Reports -> Create Reports from Templates -> and 
  go to iATS Payments Recurring Contributions Report -> Preview Report 
  -> do you have any next scheduled contribution dates in the past? If so then let's try trigger them manually:</p></li>
  <li><p>Go to your Scheduled jobs and on the right side -> hit Execute Now. Check the log -> did it run successfully? </p></li>
  <li><p>If not go to this Table: civicrm_iats_request_log and check to see which requests were made; then check the civicrm_iats_response_log for any answers from iATS.</p></li>
  </ul>
  
  <p>Ok let us know what you find out. </p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T04:09:55.730Z
Answers.LastActivityDate: 2017-02-23T04:09:55.730Z
Answers.UserDisplayName: KarinG - Semper IT
Answers.Body: <p>Resolved. As Karin pointed out, the problem is with dompdf. I discovered that there is a setting in "Administration=>CiviContribute=>civiContribute Component Settings=>Enable Tax and Invoicing=>Automatically email invoice when user purchases online" that NEEDS TO BE OFF in order for the transactions to complete through CivCRM via the iATS Payments Recurring Contributions scheduled job. Otherwise the job starts and never finishes (it also does not send a "success alert" to the user after making a one-time contribution and does not update the "next scheduled date" field in the recurring table.) I had completely overlooked this (probably obvious culprit) when I searched for functionality that tries to create/attach PDFs to transaction emails.</p>
  
  <p>Karin, you may want to test this yourself. Don't know if this conflict exists for 4.7x.</p>
  
  <p>As of now, I believe that this is the only setting that was causing the problems with the job not finishing. I will gradually turn other settings back "on" to further test (right now all my custom scheduled jobs and the settings for sending attached PDFs to receipts are "OFF"). </p>
  
  <p>Whew! Working now. Certainly don't need "invoice" functionality at all. Thank you Karin and Allen for all your kind help!</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T18:19:13.613Z
Answers.Text: Phew! DOMPDF has lots of memory/issues - and has already been replaced by TCPDF in Core in several places (like e.g. mailing labels generation) - but auto PDF anything is a scary idea - it's not payment processor specific.
Answers.UserDisplayName: KarinG - Semper IT
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T18:38:58.977Z
Answers.Text: That sounds like a feature that should not be so easy to turn on, and not in core at all if it breaks a normal install routinely without appropriate messaging or logging.
Answers.UserDisplayName: Alan Dixon
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T16:39:44.567Z
Answers.LastActivityDate: 2017-02-23T16:39:44.567Z
Answers.UserDisplayName: John Richardson
Answers.Body: <p>I'm curious about the observation that it only started happening after a Civi upgrade from 4.6.19 to 4.6.26. I notice that 4.6.19 came out just before 1.5.3 and 1.5.3 is still the recommended release for 4.6. In other words, if it was triggered by your civi upgrade, I suspect there is something else more subtle going on, and it's unrelated to iATS.</p>
  
  <p>In any case, that job shouldn't be failing silently -- that suggests a critical error before it even gets started. I'd recommend turning on all your logging, manually triggering the job, and then seeing what comes up in your logs.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T18:04:04.117Z
Answers.Text: Alan, the issue is fully resolved and had nothing to do with the upgrade. See my answer above. The setting in the invoice component just happened to be enabled AT THE SAME TIME that we upgraded (I was just checking it out). A coincidence. So, I believe the failure has to do with only this setting. Take a look at the answer I posted. Like I said, don't know if the "incompatibility" (Invoice component enabled with "send invoice" and iats recurring payments scheduled job) is still a problem in 4.7, but it was a big problem for me in 4.6.26.
Answers.UserDisplayName: John Richardson
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T18:43:17.817Z
Answers.Text: Ah, thanks. Just to pursue this line of thought a bit further, I would expect that if dompdf (or any other function) causes the code execution to stop, there would be some trace, somewhere, and knowing the specifics might help us prevent a recurrence. Any chance you have access perhaps to your php and/or http log? I'm still guessing it was a critical error that didn't allow the iats extension job to even do it's normal error handling to report back to you.
Answers.UserDisplayName: Alan Dixon
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T18:47:35.000Z
Answers.Text: Yes. You are right. Something critical happened and I got no alert or error from iats logs in scheduled jobs (or anywhere else that I know of). I should have access to logs you mention. Where are they? How do I enable? If its not something I can see here I can ask the server admin.
Answers.UserDisplayName: John Richardson
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-23T17:43:39.243Z
Answers.LastActivityDate: 2017-02-23T17:43:39.243Z
Answers.UserDisplayName: Alan Dixon
Body: <p>Using 1.5.3, Civi 4.6.26 on D7. In scheduled jobs, the "iATS Payments Recurring Contributions" job is set to run daily. The logs for this event show a record for "Starting execution of iATS Payments Recurring Contributions" but no record for "Finished execution of iATS Payments Recurring Contributions". No "With Result: Success", etc. This has been happening only since February 10 when we updated CiviCRM from 4.6.19 to CiviCRM 4.6.26. Before that, the logs appear as usual with starting and finishing.</p>
  
  <p>The question I am asking may be related to a question I asked last week at <a href="https://civicrm.stackexchange.com/questions/17223/why-does-the-user-not-get-a-transaction-complete-or-success-confirmation-mes">Why does the user not get a &quot;transaction complete&quot; or &quot;success&quot; confirmation message after submitting an online transaction?</a> This question is still unresolved (I followed KarinG's suggestion and turned off the "send PDF with receipt", but still don't know why it isn't working properly). Probably is related.</p>
  
  <p>I am assuming that iATS server is supposed to send something (IPN?) to complete the process in Civi and that either it is failing to send, or we are not receiving or CiviCRM is not interpreting what is received properly.</p>
  
  <p>In any case, just to double-check, what should the url settings be in my iATS payments configuration (I have three different processors enabled: credit card, ACH and POS swipe)? I haven't changed anything recently, other than the update, but I just want to make sure the processor is still properly configured (I can't seem to find any documentation on the urls for the iats payments config).</p>
  
  <p>Thank you in advance, Karin, for any help or insight you can give.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-21T18:56:17.800Z
Comments.Text: I have had similar issues with the other iATS job.  See here: http://civicrm.stackexchange.com/questions/13127/iats-ach-eft-payment-verification-scheduled-job-not-finishing?rq=1 for reference.  Are you able to complete the job if you run it from the command line (via drush or through your cron setup)?
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-21T18:57:34.657Z
Comments.Text: Perhaps relevant: I also experienced an issue with the Recurring iATS job: http://civicrm.stackexchange.com/questions/14544/error-fetching-http-headers-iats-recurring-contribution?rq=1
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-21T20:07:39.947Z
Comments.Text: Were you able to resolve these using the suggestions? If so, it appears that Karin suggested using two separate server Crons to run scheduled payments and verify as opposed to the iATS "Scheduled Jobs" (turned off?) in the Civi Admin GUI. Is that correct?
Comments.UserDisplayName: John Richardson
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-21T21:22:17.673Z
Comments.Text: Turns out there were a number of ways to come at this, but Karin's suggestions got us in the right direction.  We have both jobs ENABLED in the Scheduled jobs, and we have a cron run that executes the execute function.  The Recurring job is set to Daily via Scheduled jobs, and Verification is run hourly.  Another kicker for us was we were often running the Recurring job when iATS was down for maintenance between 12-1am PST.  We had to account for time differences in our cron run with where our server is located so we didn't run the job during maintenance hours.
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-21T21:28:46.817Z
Comments.Text: /usr/bin/php /usr/bin/drush --root='SITE ROOT LOCATION ON SERVER' --uri='SITE URL' -u 1 civicrm-api job.execute auth=0 -y   The time setting for this job is 7 0-7,10-23 * * *.  The 7 minutes past the hour is so that other hourly jobs can finish first.  The 0-7,10-23 accounts for the time difference and skips 12:07am and 1:07am (for Daylight Saving Time).  If this ends up helping you in some way, I'll write it up as an answer all formal-like. :-)
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-22T22:34:39.090Z
Comments.Text: Hi Allen, can you tell me what your iats url settings are for your payment processor config?
Comments.UserDisplayName: John Richardson
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-22T22:56:17.440Z
Comments.Text: https://www.iatspayments.com/NetGate/ProcessLinkv2.asmx?WSDL  -- that's for both the Site URL setting and the Recurring Payments URL setting.
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-22T23:32:01.503Z
Comments.Text: Thanks for your help. Mine is different. I do not have "v2" in this string. Mine is:  
  iatspayments.com/NetGate/ProcessLink.asmx?WSDL I am running 1.5.3. I wonder why mine is different. Think I should change to match yours?
Comments.UserDisplayName: John Richardson
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-22T23:43:49.500Z
Comments.Text: I would. https://github.com/iATSPayments/com.iatspayments.civicrm/issues/125#issuecomment-180042601 iATS updated parameters for processing payments in Feb 2016, so I wonder if the v2 is related.
Comments.UserDisplayName: Allen Hutchison
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-23T03:11:06.020Z
Comments.Text: Thanks! Frustrating. I changed the URLs to match yours. Still no completion of scheduled job. BTW: the verify job completes but not the recurring payments job. If you think of anything to troubleshoot, please let me know. I'm stumped.
Comments.UserDisplayName: John Richardson
Tags: <scheduled-job><iats>
Title: iATS Scheduled job for recurring payments does not "finish" in the logs. How can I fix this or troubleshoot further?
ThreadText: # iATS Scheduled job for recurring payments does not "finish" in the logs. How can I fix this or troubleshoot further?
  
  (Asked by: username_0 on 2017-02-21)
  
  Using 1.5.3, Civi 4.6.26 on D7. In scheduled jobs, the "iATS Payments Recurring Contributions" job is set to run daily. The logs for this event show a record for "Starting execution of iATS Payments Recurring Contributions" but no record for "Finished execution of iATS Payments Recurring Contributions". No "With Result: Success", etc. This has been happening only since February 10 when we updated CiviCRM from 4.6.19 to CiviCRM 4.6.26. Before that, the logs appear as usual with starting and finishing.
  
  The question I am asking may be related to a question I asked last week at [Why does the user not get a "transaction complete" or "success" confirmation message after submitting an online transaction?](https://civicrm.stackexchange.com/questions/17223/why-does-the-user-not-get-a-transaction-complete-or-success-confirmation-mes) This question is still unresolved (I followed username_2's suggestion and turned off the "send PDF with receipt", but still don't know why it isn't working properly). Probably is related.
  
  I am assuming that iATS server is supposed to send something (IPN?) to complete the process in Civi and that either it is failing to send, or we are not receiving or CiviCRM is not interpreting what is received properly.
  
  In any case, just to double-check, what should the url settings be in my iATS payments configuration (I have three different processors enabled: credit card, ACH and POS swipe)? I haven't changed anything recently, other than the update, but I just want to make sure the processor is still properly configured (I can't seem to find any documentation on the urls for the iats payments config).
  
  Thank you in advance, Karin, for any help or insight you can give.
  
  **Tags:** scheduled-job, iats
  
  > **Comments:**
  > **username_1**: I have had similar issues with the other iATS job.  See here: http://civicrm.stackexchange.com/questions/13127/iats-ach-eft-payment-verification-scheduled-job-not-finishing?rq=1 for reference.  Are you able to complete the job if you run it from the command line (via drush or through your cron setup)?  
  > **username_1**: Perhaps relevant: I also experienced an issue with the Recurring iATS job: http://civicrm.stackexchange.com/questions/14544/error-fetching-http-headers-iats-recurring-contribution?rq=1  
  > **username_0**: Were you able to resolve these using the suggestions? If so, it appears that Karin suggested using two separate server Crons to run scheduled payments and verify as opposed to the iATS "Scheduled Jobs" (turned off?) in the Civi Admin GUI. Is that correct?  
  > **username_1**: Turns out there were a number of ways to come at this, but Karin's suggestions got us in the right direction.  We have both jobs ENABLED in the Scheduled jobs, and we have a cron run that executes the execute function.  The Recurring job is set to Daily via Scheduled jobs, and Verification is run hourly.  Another kicker for us was we were often running the Recurring job when iATS was down for maintenance between 12-1am PST.  We had to account for time differences in our cron run with where our server is located so we didn't run the job during maintenance hours.  
  > **username_1**: /usr/bin/php /usr/bin/drush --root='SITE ROOT LOCATION ON SERVER' --uri='SITE URL' -u 1 civicrm-api job.execute auth=0 -y   The time setting for this job is 7 0-7,10-23 * * *.  The 7 minutes past the hour is so that other hourly jobs can finish first.  The 0-7,10-23 accounts for the time difference and skips 12:07am and 1:07am (for Daylight Saving Time).  If this ends up helping you in some way, I'll write it up as an answer all formal-like. :-)  
  > **username_0**: Hi username_1, can you tell me what your iats url settings are for your payment processor config?  
  > **username_1**: https://www.iatspayments.com/NetGate/ProcessLinkv2.asmx?WSDL  -- that's for both the Site URL setting and the Recurring Payments URL setting.  
  > **username_0**: Thanks for your help. Mine is different. I do not have "v2" in this string. Mine is:   iatspayments.com/NetGate/ProcessLink.asmx?WSDL I am running 1.5.3. I wonder why mine is different. Think I should change to match yours?  
  > **username_1**: I would. https://github.com/iATSPayments/com.iatspayments.civicrm/issues/125#issuecomment-180042601 iATS updated parameters for processing payments in Feb 2016, so I wonder if the v2 is related.  
  > **username_0**: Thanks! Frustrating. I changed the URLs to match yours. Still no completion of scheduled job. BTW: the verify job completes but not the recurring payments job. If you think of anything to troubleshoot, please let me know. I'm stumped.  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_2 on 2017-02-23. Score: 1
  
  a Couple of thoughts:
  
  * The Site URL is not the issue. Yes it has changed but I've confirmed
    older URLs have not been deprecated - and are fully functional.
  * I just verified on a site/project that Using 1.5.3, Civi 4.6.26 on D7 recurring job starts and finishes successfully - with a standard CiviCRM cron (set job to ON on scheduled jobs page)
  * You definitively want no PDF receipts to go out with your Email  
    receipts. If you are still getting DOMPDF errors - do you have any  
    other custom functionality that's trying to create/attach a PDF?
  * The recurring payments job - sends the tokens to iATSPayments -> and
    immediately receives a transaction ID. There is no IPN.
  * Try this: go to your Reports -> Create Reports from Templates -> and
    go to iATS Payments Recurring Contributions Report -> Preview Report
    -> do you have any next scheduled contribution dates in the past? If so then let's try trigger them manually:
  * Go to your Scheduled jobs and on the right side -> hit Execute Now. Check the log -> did it run successfully?
  * If not go to this Table: civicrm\_iats\_request\_log and check to see which requests were made; then check the civicrm\_iats\_response\_log for any answers from iATS.
  
  Ok let us know what you find out.
  
  
  ---
  
  ### Answer by username_0 on 2017-02-23. Score: 0
  
  Resolved. As Karin pointed out, the problem is with dompdf. I discovered that there is a setting in "Administration=>CiviContribute=>civiContribute Component Settings=>Enable Tax and Invoicing=>Automatically email invoice when user purchases online" that NEEDS TO BE OFF in order for the transactions to complete through CivCRM via the iATS Payments Recurring Contributions scheduled job. Otherwise the job starts and never finishes (it also does not send a "success alert" to the user after making a one-time contribution and does not update the "next scheduled date" field in the recurring table.) I had completely overlooked this (probably obvious culprit) when I searched for functionality that tries to create/attach PDFs to transaction emails.
  
  Karin, you may want to test this yourself. Don't know if this conflict exists for 4.7x.
  
  As of now, I believe that this is the only setting that was causing the problems with the job not finishing. I will gradually turn other settings back "on" to further test (right now all my custom scheduled jobs and the settings for sending attached PDFs to receipts are "OFF").
  
  Whew! Working now. Certainly don't need "invoice" functionality at all. Thank you Karin and username_1 for all your kind help!
  
  > **Comments:**
  > **username_2**: Phew! DOMPDF has lots of memory/issues - and has already been replaced by TCPDF in Core in several places (like e.g. mailing labels generation) - but auto PDF anything is a scary idea - it's not payment processor specific.  
  > **username_3**: That sounds like a feature that should not be so easy to turn on, and not in core at all if it breaks a normal install routinely without appropriate messaging or logging.  
  
  ---
  
  ### Answer by username_3 on 2017-02-23. Score: 0
  
  I'm curious about the observation that it only started happening after a Civi upgrade from 4.6.19 to 4.6.26. I notice that 4.6.19 came out just before 1.5.3 and 1.5.3 is still the recommended release for 4.6. In other words, if it was triggered by your civi upgrade, I suspect there is something else more subtle going on, and it's unrelated to iATS.
  
  In any case, that job shouldn't be failing silently -- that suggests a critical error before it even gets started. I'd recommend turning on all your logging, manually triggering the job, and then seeing what comes up in your logs.
  
  > **Comments:**
  > **username_0**: username_3, the issue is fully resolved and had nothing to do with the upgrade. See my answer above. The setting in the invoice component just happened to be enabled AT THE SAME TIME that we upgraded (I was just checking it out). A coincidence. So, I believe the failure has to do with only this setting. Take a look at the answer I posted. Like I said, don't know if the "incompatibility" (Invoice component enabled with "send invoice" and iats recurring payments scheduled job) is still a problem in 4.7, but it was a big problem for me in 4.6.26.  
  > **username_3**: Ah, thanks. Just to pursue this line of thought a bit further, I would expect that if dompdf (or any other function) causes the code execution to stop, there would be some trace, somewhere, and knowing the specifics might help us prevent a recurrence. Any chance you have access perhaps to your php and/or http log? I'm still guessing it was a critical error that didn't allow the iats extension job to even do it's normal error handling to report back to you.  
  > **username_0**: Yes. You are right. Something critical happened and I got no alert or error from iats logs in scheduled jobs (or anywhere else that I know of). I should have access to logs you mention. Where are they? How do I enable? If its not something I can see here I can ask the server admin.  
  
  ---
  
  