Author Topic: roundcube does a login request on each click  (Read 2943 times)

Offline chazy

  • Newbie
  • *
  • Posts: 2
roundcube does a login request on each click
« on: September 15, 2017, 08:18:44 AM »
Hello there, it's my first time trying roundcube manually. I've use it in the past in bundles like cpanel and the like.

I have my own email server (postfix + dovecot) and I've decided to install roundcube.

I'm wondering why is roundcube doing a login request on each click? For example I click one email message and I can see the journal printing a login request, as slow as:
Quote
Logged out in=292 out=3539

So each time I click on a different message, it takes up to 3.8 seconds. Is this a problem with my server setup? Or is there a configuration in roundcube for this?
I mean why's roundcube requesting them to dovecot each time I click one and not caching them anywhere?
I can also see the request when I click config options. And overall so many requests... I can see one request every 30 seconds while idle.
Maybe it's that I don't fully understand how communication between (web?) mail clients and imap server works but this is not happening with desktop/mobile clients.

With thunderbird, for example, I don't see any request when I open a message, I see them sometimes when I click the inbox, not always though, and not as much as with roundcube.

Can someone please, help me understand why is this happening? It's a poor user experience to have to wait everytime I open a message or click a config in the menu. So is there any way to make roundcube navigation smooth?

Offline alec

  • Hero Member
  • *****
  • Posts: 1,363
Re: roundcube does a login request on each click
« Reply #1 on: September 15, 2017, 02:11:42 PM »
This is how PHP apps work. 4 seconds sounds too much but it depends on IMAP and Roundcube settings.

Offline chazy

  • Newbie
  • *
  • Posts: 2
Re: roundcube does a login request on each click
« Reply #2 on: September 15, 2017, 06:38:52 PM »
I'm just worried it was something I did bad.

So is that the normal behavior for everyone? Would it be possible to use something like memcached, or maybe even better get all mail to javascript? I mean, already built in. If not, I may find the time to look into the code and make some changes to improve this. But it really surprises me this not so efficient method of fetching mail... It could really use some caching either server-side or client-side (the visible ones).

Gmail and hotmail don't behave like this, but I suppose their not written in PHP, plus they have years of development....

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,876
    • SKaero - Custom Roundcube development
Re: roundcube does a login request on each click
« Reply #3 on: September 17, 2017, 03:12:23 PM »
The key difference between Roundcube and Thunderbird is Roundcube reads all mail directly from the mail server where as Thunderbird downloads all of the mail and stores it on the computer only syncing any operation that happens to the mail. It would be very impractical and slow to get all the mail and store it in the browser before doing any operations.

That said Roundcube does have some caching options available including memcached. You can see those options in the <RC root>/config/defaults.inc.php file.