CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Activity Processing - D7 Civi 4.0beta3
Pages: [1]

Author Topic: Activity Processing - D7 Civi 4.0beta3  (Read 904 times)

theMusician

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 3
  • CiviCRM version: 4.0 and 4.0.1
  • CMS version: Drupal 7.0
  • MySQL version: MySQL 5.x
  • PHP version: 5.2
Activity Processing - D7 Civi 4.0beta3
April 13, 2011, 04:28:03 pm
Hi all,

Continuing my exploration of Civi I have been struggling with configuring the Mail Settings to use the Activity Processing feature.

I now have the EmailProcessor.php file working without error messages. However, it will not do Activity Processing. I have added some echo statements to the EmailProcessor.php file to see what is happening and it does not appear to ever get to the Activity Processing step.

Here is the output from EmailProcessor.php with my echo statements added. Italicized text is changed for security reasons.

The type of process is 1 (1 = bounce, 0 = activities)

The email activity id type is 12

retrieve the emailsconnecting to ourmailserver, authenticating as username and selecting INBOX mailboxes found: Outbox, Deleted Items, Sent Items, Calendar, Contacts, Drafts, Journal, Notes, Tasks, Tublitz, Junk E-mail, INBOX, INBOX/CiviMail, INBOX/CiviMail/ignored, INBOX/CiviMail/processed

retrieve the emails line 167

It is creating the folders within the IMAP account but it is not creating the folders in /sites/default/files/civicrm/custom.

The drupal user has full permissions for civimail.

When running the following from the command line:
Code: [Select]
sudo wget http://[i]ourdomain[/i]/fa-drupal7/civiCRM-Demo/sites/all/modules/civicrm/bin/EmailProcessor.php?name=[i]username[/i]&pass=[i]password[/i]&key=[i]sitekey[/i]

I receive the following output on the terminal:
   
    [3] 8969
    [4] 8970

I am not sure what that means but it doesn't seem like there is any issue with permissions and creating folders.

I will keep digging but if anybody has battled with these issues in the past I would be happy to hear your thoughts.

Thank you.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Activity Processing - D7 Civi 4.0beta3
April 13, 2011, 04:51:08 pm

r u sure those messages are when u run the wget command?

U'll need to escape the '&' in the url, use '\&' in the 2 places to prevent goofy *nix things from happening

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

theMusician

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 3
  • CiviCRM version: 4.0 and 4.0.1
  • CMS version: Drupal 7.0
  • MySQL version: MySQL 5.x
  • PHP version: 5.2
Re: Activity Processing - D7 Civi 4.0beta3
April 14, 2011, 08:53:23 am
Right, escape characters in the cli. Thanks for that reminder.

wget now retrieves the file properly.

I am going to continue working through scenarios of how the processor is supposed to handle the activity processing. Keep up the great work.

theMusician

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 3
  • CiviCRM version: 4.0 and 4.0.1
  • CMS version: Drupal 7.0
  • MySQL version: MySQL 5.x
  • PHP version: 5.2
Re: Activity Processing - D7 Civi 4.0beta3
April 14, 2011, 09:35:19 am
Is it proper to use the same e-mail account for bounce processing as well as activity processing?


theMusician

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 3
  • CiviCRM version: 4.0 and 4.0.1
  • CMS version: Drupal 7.0
  • MySQL version: MySQL 5.x
  • PHP version: 5.2
Re: Activity Processing - D7 Civi 4.0beta3
April 14, 2011, 10:28:53 am
Okay further analysis of EmailProcessor.php has helped enlighten me a bit more as to what is going on.

First the bottom portion of the code is processed, Drupal bootstrap.

That outputs the following of my echo statements.
Code: [Select]
Line 386 Log the execution of the script.
EmailProcessor Locked.
time limit set.
cleanup process CiviMail.ignored
cleanup process CiviMail.processed
check to see how the script is being used.

It does not seem to me that the following line, EmailProcessor::process(isCiviMail); ever gets used. This should set the static function _process to whatever value is in $civimail. If I explicitly set this to be 0, the function continues on as if it has a value of 1.

The function continues on outputting the following from my echo statements. I have replaced my mailserver address with the word mailserver in the output below.
Code: [Select]
$isCiviMail value is set to: 1
process() line 123 Mail Settings have been received.The type of process is 1 (1 = bounce, 0 = activities)
The email activity id type is 12
retrieve the emails line 165
connecting to mailserver authenticating as rycooder and selecting INBOX mailboxes found: Outbox, Deleted Items, Sent Items, Calendar, Contacts, Drafts, Journal, Notes, Tasks, Tublitz, Junk E-mail, INBOX/CiviMail/ignored, INBOX/CiviMail/processed, Junk E-mail1, INBOX/CiviMail, INBOX
retrieve the emails line 167

After this the function ends. the Utils/Hook.php file is never callled, message processing does not occur in the following while statement    while ($mails = $store->fetchNext(MAIL_BATCH_SIZE)) { nor in the activities statement  if ( $usedfor == 0 || ! $civiMail ) {. That is expected because $usedfor is 1.

How do I get this script to invoke the rest of the function?

Thank you.

theMusician

  • I post occasionally
  • **
  • Posts: 48
  • Karma: 3
  • CiviCRM version: 4.0 and 4.0.1
  • CMS version: Drupal 7.0
  • MySQL version: MySQL 5.x
  • PHP version: 5.2
Re: Activity Processing - D7 Civi 4.0beta3
April 15, 2011, 03:02:35 pm
I have tried the configuration again in beta2. It still does not work properly for me.

Has anyone else been able to configure Email Activity Processing successfully with any of the 4.0 releases?

Thank you.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Activity Processing - D7 Civi 4.0beta3

This forum was archived on 2017-11-26.