IM Confirmations are send to the wrong QueueManager when using DBQeueueManager
OpenPublic

Assigned To
None
Priority
Needs Triage
Subscribers
fschmaus, pztrn
Author
fschmaus
Projects
Description

If a IM confirmation is send by GNU social the following log entry appears:

OpportunisticQueueManager: Got string '<message from="gnusocial@geekpla...' (517 bytes) for transport xmpp-out

but those messages never arrive. If I send e.g. "help" to the GNU social XMPP contact, he will reply with a message like "Unknown user; go to ... to add your address to your", which appear as

DBQueueManager (im): Got string '<message from="gnusocial@geekpla...(226 bytes) for transport xmpp-out   

notice how DBQueueManager is mentioned here

My config.php:

<?php
if (!defined('GNUSOCIAL')) { exit(1); }

$config['site']['logfile'] = '/var/log/gnusocial/gnusocial.log';
$config['daemon']['piddir'] = '/var/run/gnusocial';

$config['site']['name'] = 'GNU Social @ geekplace';

$config['site']['server'] = 'social.geekplace.eu';
$config['site']['path'] = false;

$config['site']['fancy'] = true;

$config['db']['database'] = 'mysqli://xxx:xxx@localhost/gnusocial';

$config['db']['type'] = 'mysql';

foreach(array("Memcache", "Memcached") as $plugin) :
    if (class_exists($plugin)) {
        addPlugin($plugin);
        break;
    }
endforeach;
$config['site']['profile'] = 'community';

$config['queue']['enabled'] = true;
$config['queue']['daemon'] = true;

addPlugin('xmpp',
        array('user'=>'gnusocial','host'=>'mate.geekplace.eu','server'=>'geekplace.eu','password'=>'xxx')
);

addPlugin('Gravatar', array());
addPlugin('Autocomplete');
addPlugin('PiwikAnalytics', array('piwikroot'=>'piwik.geekplace.eu/','piwikId'=>'5'));
fschmaus created this task.Via WebAug 20 2014, 3:00 PM
fschmaus added a subscriber: fschmaus.
fschmaus added a project: GNU social
fschmaus edited the task description. (Show Details)Via WebAug 20 2014, 4:22 PM
pztrn added a subscriber: pztrn.Via WebAug 21 2014, 1:27 AM

Have you disabled OpportunisticQM? AFAIK, it should be forced with unset():

unset($config['plugins']['core']['OpportunisticQM']);
unset($config['plugins']['core']['Cronish']);
fschmaus added a comment.Via WebAug 21 2014, 3:40 AM

Even with the shown lines in config.php the log message continues to be

2014-08-21 07:39:25 LOG_DEBUG: [social.geekplace.eu:18192.9ebddec6 POST /settings/im] OpportunisticQueueManager: Got string '<message from="gnusocial@geekpla...' (517 bytes) for transport xmpp-out
fschmaus edited the task description. (Show Details)Via WebAug 21 2014, 4:05 AM

I've just noticed the followling logs

2014-08-21 08:03:38 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] claiming queue item id = 24243 for transport hubconf
2014-08-21 08:03:38 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] claim succeeded.
2014-08-21 08:03:38 LOG_DEBUG: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] OpportunisticQueueManager: Got array with 4 elements (keys:[sub,mode,token,retries]) for transport hubconf
2014-08-21 08:03:38 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] HubConfQueueHandler::handle: subscribe https://myfriendica.net/pubsub/soloojos/11672 https://social.geekplace.eu/api/statuses/user_timeline/3.atom
2014-08-21 08:03:39 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] HTTPClient: HTTP GET https://myfriendica.net/pubsub/soloojos/11672?hub.mode=subscribe&hub.topic=https%3A%2F%2Fsocial.geekplace.eu%2Fapi%2Fstatuses%2Fuser_timeline%2F3.atom&hub.challenge=xxx&hub.lease_seconds=0&hub.verify_token=xxx - 200 OK
2014-08-21 08:03:39 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] Verified subscribe of https://myfriendica.net/pubsub/soloojos/11672:https://social.geekplace.eu/api/statuses/user_timeline/3.atom
2014-08-21 08:03:39 LOG_INFO: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] OpportunisticQueueManager: [hubconf:array with 4 elements (keys:[sub,mode,token,retries])] Successfully handled item
2014-08-21 08:03:39 LOG_DEBUG: [social.geekplace.eu:17981.fd65bb4f POST /main/push/hub] Opportunistic queue manager finished.

Again OpportunisticQueueManager appears

pztrn added a comment.Via WebSep 10 2014, 10:21 AM

Try adding this in config.php:

unset($config['plugins']['default']['OpportunisticQM']);
unset($config['plugins']['core']['Cronish']);

With that I was able to completely disable OpportunisticQM.

fschmaus added a comment.Via WebSep 10 2014, 10:33 AM

It does work now. Thanks.

So the problem was s/core/default/ for the OpportunisticQM unset directive.

It should be documented somewhere that this needs to be done, or even better

$config['queue']['enabled'] = true;

should have that as side-effect.

pztrn added a comment.Via WebSep 10 2014, 10:59 AM

As I have tested, enabling queue makes no difference in disabling OpportunisticQM. You should set ["queue"]["daemon"]=true and unset OpportunisticQM. And yes, this should be documented.

Add Comment