You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by "Brian Owens (Jira)" <se...@james.apache.org> on 2020/02/12 03:33:00 UTC

[jira] [Created] (JAMES-3064) Cannot delete emails using POP3 connection

Brian Owens created JAMES-3064:
----------------------------------

             Summary: Cannot delete emails using POP3 connection
                 Key: JAMES-3064
                 URL: https://issues.apache.org/jira/browse/JAMES-3064
             Project: James Server
          Issue Type: Bug
          Components: POP3Server
    Affects Versions: 3.4.0
         Environment: Ubuntu 18.04
Oracle Java 1.8.0_211
            Reporter: Brian Owens


Using a POP3 connection to James from a Java application deleting emails from the INBOX folder (only tested INBOX) is not working.  This worked fine in 3.3.0 and previous versions.  I currently have both versions (3.3.0 and 3.4.0) installed and consistently have this issue with 3.4.0.  When I switch back to 3.3.0 it works perfectly.

Below is the basic code I'm running.

{{}}{color:#de350b}{{emailFolder.open(Folder.READ_WRITE);}}{color}
{color:#de350b}{{Message[] messages = emailFolder.getMessages();}}{color}
{color:#de350b}{{for (int i = 0; i < messages.length; i++) {}}{color}
{color:#de350b}{{     messages[i].setFlag(Flags.Flag.DELETED, true);}}{color}
{color:#de350b}{{}}}{color}
{color:#de350b}{{emailFolder.close(true);}}{color}

This is the Java API I'm using.

{color:#de350b}{{<dependency>}}{color}
{color:#de350b}{{    <groupId>com.sun.mail</groupId>}}{color}
{color:#de350b}{{    <artifactId>javax.mail</artifactId>}}{color}
{color:#de350b}{{    <version>1.6.2</version>}}{color}
{color:#de350b}{{</dependency>}}{color}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org