Salta al contenuto principale


Tens of thousands of Message queues


!Friendica Admins I posted before about this and we tried a bunch of things. I moved from cron to daemon and managed to burn 100k Message queues in a few days. Then it stopped at burning them so fast. We checked and 99% of them are AddContact. With debugging enabled here is a sample of what the log shows me: https://paste.trom.tf/ayovelucug.sql

One of the Warnings is:
2022-06-15T04:10:29Z worker [WARNING]: Contact lock had not been acquired {"worker_id":"5a518d7","worker_cmd":"AddContact"} - {"file":"Contact.php","line":1280,"function":"getIdForURL","uid":"289a24","process_id":17436}

My Friendica works fine, but can someone help me with this issue? Maybe I have come across some nasty Friendica bug.
in reply to Tio

Can you have a look in the workerqueue table for entries with the command equals to "AddContact"? How many are there?
in reply to Michael 🇺🇦

I am unsure how to exactly do that. But as soon as I figure it out I will do it and let you know. Thx

Friendica Admins reshared this.

in reply to Tio

@Tio did you ever try to optimize the friendica database (especially the contact table) ?
@Tio

Friendica Admins reshared this.

in reply to Luca Nucifora

I did it with mysqloptimize -p friendica

Friendica Admins reshared this.

in reply to Tio

Please change that line https://github.com/friendica/friendica/blob/stable/src/Worker/AddContact.php#L36 to public static function execute(int $uid = 0, string $url = '')

This should help to get rid of that message.
Questa voce è stata modificata (3 anni fa)

Friendica Admins reshared this.

in reply to Michael 🇺🇦

Great I did that. Do I need to restart any service? Let's see if it has an effect on Message queues. And thanks!
Questa voce è stata modificata (3 anni fa)

Friendica Admins reshared this.

in reply to Tio

grep "AddContact" /var/www/friendica/friendica.log | wc -l
0


Ok so that error seems to be gone now.

Friendica Admins reshared this.

in reply to Tio

Now here's an updated log file, 100 times smaller in size https://paste.trom.tf/anijuvakux.pl - we still have a lot of message queues tho...

Friendica Admins reshared this.

in reply to Tio

I guess this is now some "wait and see". The log looks fine on the first glance.
Questa voce è stata modificata (3 anni fa)

Friendica Admins reshared this.

in reply to Michael 🇺🇦

Message queues
4100 - 66074

That's the situation now. If you think is worth waiting more I will, else if you have any idea what else I could try....I'd appreciate it.

Friendica Admins reshared this.

in reply to Tio

What does this command currently returns:
select command, count(*) from workerqueue where not done and not retrial group by command;
Questa voce è stata modificata (3 anni fa)

Friendica Admins reshared this.

in reply to Michael 🇺🇦

This:

I see a lot of FetchFeaturedPosts and UpdateContact

Friendica Admins reshared this.

in reply to Tio

This looks totally okay to me.
Questa voce è stata modificata (3 anni fa)

Friendica Admins reshared this.

in reply to Michael 🇺🇦

Ok then I am reassured now. :) I mean you are the mastermind behind Friendica so probably I can't get a better opinion than yours :D - thank you for the help and I am simply going to ignore these large numbers.

Friendica Admins reshared this.

in reply to Tio

@Tio@Michael Vogel My #like went immediately through, so I guess you have some backlog of old (yet not unimportant) there.

Friendica Admins reshared this.

Unknown parent

Roland Häder🇩🇪
@Hank G ☑️@Michael Vogel@Tio Instead of `done` = 0 you can also use NOT `done`. It works perfectly fine. I have learned this from this community.

Friendica Admins reshared this.