[FEATURE] Empty Trash on Exit for POP3 and IMAP

VERIFIED FIXED in M16

Status

MailNews Core
Backend
P4
normal
VERIFIED FIXED
18 years ago
9 years ago

People

(Reporter: laurel, Assigned: jefft)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [nsbeta2+][5/16]?? days -- stuck, need a service ensure imap empty trash finished prior shutdown)

Attachments

(1 attachment)

(Reporter)

Description

18 years ago
The current Account Setup spec indicates POP mail server panel will have a pref
for Empty Trash on Exit.   Via comments in bug #14087 alecf indicated this will
indeed be implemented at some point in seamonkey. This is a tracking bug.

The pref was in 4.x only for IMAP servers, not available in POP prefs.
The pref is located in the mail server panel, 4.x in prefs dialog and seamonkey
in Account Setup dialog.

Updated

18 years ago
Target Milestone: M15

Comment 1

18 years ago
Assign to jefft, cc bienvenu and mscott. Not a B1 feature, so setting M15.

Updated

18 years ago
Assignee: phil → jefft
(Assignee)

Updated

18 years ago
Status: NEW → ASSIGNED

Comment 2

18 years ago
Doesn't work for me with IMAP either. Per the alecf's comment, I assume, it

isn't implemented at all. Am I correct? If yes, we should change the summary.

Comment 3

18 years ago
*** Bug 29783 has been marked as a duplicate of this bug. ***

Updated

18 years ago
Summary: [FEATURE] Empty Trash on Exit for POP3 → [FEATURE] Empty Trash on Exit for POP3 and IMAP
(Assignee)

Updated

18 years ago
Priority: P3 → P2
Whiteboard: ETA 04/07/00

Updated

18 years ago
QA Contact: lchiang → huang
(Assignee)

Comment 4

18 years ago
jglick, do we have a pref design for Empty Trash On Exit for Pop3 accout?

Comment 5

18 years ago
move to M16.  Not M15 stoppers
Target Milestone: M15 → M16

Comment 6

18 years ago
http://gooey/client/5.0/specs/mail/accountSetup/accountSetup.html#AccountSetting
s

Section on Account - Server - POP
(Assignee)

Comment 7

18 years ago
Empty trash on exit for Imap seems not that easy to do because of the nature of 
the asynchronous operation plus the connection caching. I thought I could empty 
the trash prior the account manager close down all cached connections. However, 
this is not working at the moment. Although I implemented the nsIUrlListner for 
nsImapIncomingserver. OnStartRunningUrl and OnStopRunningUrl never get hit.

Comment 8

18 years ago
Hey Jeff, if you aren't seeing the on start and on stop calls for the url
listener you implemented, maybe it isn't getting attached to the url you are
interested in? What url is getting run that you want to be a listener on? I
maybe be able to help you debug this part if you need it.
(Assignee)

Comment 9

18 years ago
I am sure that the url listener is getting added correctly to the url listener 
manager. I'll look into more.

Comment 10

18 years ago
As I understand it, Jeff is running this url as the app is exiting. Highly 
unlikely that it gets to run.

Comment 11

18 years ago
Oh dear. I see. Yes in that case there's a strong chance the url isn't getting
run so we wouldn't see the on stop and on start calls.
(Assignee)

Comment 12

18 years ago
Created attachment 7492 [details] [diff] [review]
A partial fix.
(Assignee)

Comment 13

18 years ago
I am basically stocked on this one. I need to find a way to ensure that the 
async imap empty trash to finish prior shutting down the app. Low priority for 
the feature now...
Priority: P2 → P4
Whiteboard: ETA 04/07/00 → ETA 04/07/00 -- stocked, need a service ensure imap empty trash finished prior shutdown

Comment 14

18 years ago
Jeff - P4 priority means that the feature won't be in the product when it ships. 
Will this feature make it?  
Whiteboard: ETA 04/07/00 -- stocked, need a service ensure imap empty trash finished prior shutdown → ETA 04/07/00 -- stuck, need a service ensure imap empty trash finished prior shutdown
(Assignee)

Comment 15

18 years ago
I don't know. The workaround is manually doing it. This is sort of an 
architeture issue. I don't have a solution yet.

Comment 16

18 years ago
> The workaround is manually doing it.

That's a workaround for beta quality, but not for a final product. Without this
feature, the Trash delete model is useless. (Compare Windows Explorer: I always
delete and immediately empty trashcan - *very* annoying.)

I understand the problem, but we should make sure, it is resolved for final. Who
is the relevant developer, so I can bug him (or dance on his head, if necessary
;-) )? Is there a bug filed on that?
(Assignee)

Comment 17

18 years ago
No, there is no bug filed and it's not a final decision yet. dp would be 
the person to start with.

Comment 18

18 years ago
I can file a bug on DP, but I don't know what it should say.  Then, we can make 
this bug dependent on that one.  Ben - want to file the bug?

Updated

18 years ago
Depends on: 35704
(Assignee)

Updated

18 years ago
Whiteboard: ETA 04/07/00 -- stuck, need a service ensure imap empty trash finished prior shutdown → ?? days -- stuck, need a service ensure imap empty trash finished prior shutdown

Comment 19

18 years ago
beta2 nomination (not sure, if [FEATURE] implies that)
Keywords: nsbeta2

Comment 20

18 years ago
I've talked about this issue with bienvenu - I don't think we need anything from 
DP on this - I think we need to be notified when the last mail window goes away, 
which we should know from the mail session, which tracks nsIMsgWindows.
(Assignee)

Comment 21

18 years ago
I am afraid this won't work if the user quits from the browser window. It works 
only when we still have the browser window open.

Comment 22

18 years ago
if that's not working them something in our architecture is broken. It should 
not matter what window you quit from.

When the user quits, all windows should all close, and the onunload handlers 
should all fire. Each unload handler in each mail window should unregister the 
associated nsIMsgWindow object. When that list reaches zero, we should have some 
sort of notification system which tells us that everything has shut down.
(Assignee)

Comment 23

18 years ago
The problem is really asynchoronous operation. No one waits for us to complete 
unless there is a mechnism in place. See 35704 for some explanation.

Comment 24

18 years ago
oh! I see what you're saying. that's quite a conundrum.

Comment 25

18 years ago
Putting on [nsbeta2+][5/16] radar.  This is a feature MUST complete work by 
05/16 or we may pull this feature for PR2.
Whiteboard: ?? days -- stuck, need a service ensure imap empty trash finished prior shutdown → [nsbeta2+][5/16]?? days -- stuck, need a service ensure imap empty trash finished prior shutdown
(Assignee)

Comment 26

18 years ago
I have found a way to fix this. Fix checked in.
Status: ASSIGNED → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → FIXED

Comment 27

18 years ago
Cool! How did you solve the problem?
(Assignee)

Comment 28

18 years ago
It's kind of hack. I guess depends on how you view it. Apparently, as dp and 
waterson pointed out the event queue isn't dead at the moment when xp-shutdown 
notification were sent out. What I did was using PR_CMonitorEnter(), 
PR_CMonitorExit(), PR_CWait() and ProcessPendingEvent() along with 
the nsIUrlListener interface to do the trick.

Comment 29

18 years ago
By using 05-18-08-M16 commercial build.
It seems that the UI "Empty Trash on Exit" for POP3 & IMAP still not implement 
yet from account setup UI.
This bug is logged for backend.
Jeff, would you provide the verification for me to verify this bug?

(Assignee)

Comment 30

18 years ago
UI is implemented but have problems with getting/setting the value. Add the 
following pref to your prefs.js

user_pref("mail.server.server1.empty_trash_on_exit", true);
 

Comment 31

18 years ago
Sorry for the delay....I actually already verified on WinNT & Linux 
platforms....but since this bug need to verified on all the platform....(I had 
problem for my Mac 9.0 machine)...

Finally, verified on all the platforms by using:
WinNT 05-19-09-M16 commercial build
Linux 05-19/22-08-M16 commercial build 
Mac 05-22-08-M16 commercial build
Marking as verified.

Status: RESOLVED → VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.