• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Webmail with CFPOP

Contributor ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

I wrote a webmail using the CFPOP tag of CF.

And it seems to me very slow.

I do not know why it is so slow to retrieve mails.

When having heavy attachments, if I use the action "gethearderonly" or "getall"

it takes the same time, and very long.

seems that attchments are loaded also with "getheaderonly", but I cannot see them in the attached folder.

They come to attached folder when using "getall".

Why, so slow,

may be webmail are depending of factors which I do not know ?

(linked to the Mail server or ....)

The webmail "roundcube" at the host, retrieve mails instantatly (almost).

Thanks for any comments.

TOPICS
Advanced techniques

Views

987

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

To be honest, there's no way anyone can answer this except from you. What parts are slow? Have you tried debugging, which will show you exactly where the slowdowns are? Put any timers in?

As you say, could be the mailserver. Could be the POP3 protocol. Could be the webserver.

I'd start by turning on debugging to see which tags are running slowly.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Dec 01, 2011 Dec 01, 2011

Copy link to clipboard

Copied

Thanks, I did what you said.

The result in time is in the image.

There is one of the mail, with 2 attached images of 15Mo (big, but can happen now with the actual cameras)

Then the CFPOP took 25seconds to get it (in "getonlyheaders").

If I use the "getall" it takes the same time.

The same retrieving with RoundCube, took less than 1 second.

With no big attachements, it is acceptable (but long to retrieve for example 50 mails)

I need to retrieve all at first round, because I want to reorder them by local date.

Then I display only 20 by 20.

webmail_time.jpg

It seems to me that the "gethearderonly" load the attchments. (I am in CF9).

<cfpop action="GETHEADERONLY" name="all_mails" server="#session.mail_server#" username="#session.UserName#" password="#session.pwd#">

Thanks for any suggestion.

Pierre.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Dec 02, 2011 Dec 02, 2011

Copy link to clipboard

Copied

To be honest I've seen people try what you're doing before, I even considered it myself once but ColdFusion is simply not the tool for the job. Most webmail interfaces are written in something extremely lightweight behind the scenes like Python or Perl, not an enormous stack of Java bloat.

The CFPOP tag is not a key part of CF, it's just one of many tags they've bolted on as a feature. It's slow, it's not tuned particularly well and it's not very flexible. I suspect you'll struggle to achieve what you're after here and should consider other options.

The POP3 protocol is for downloading mails to a client, and is not designed to be a two-way protocol for real-time display of data. You may have more luck with CFIMAP perhaps.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Dec 02, 2011 Dec 02, 2011

Copy link to clipboard

Copied

LATEST

OK, thanks for your coment.

Pierre.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation