james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rdon...@apache.org
Subject svn commit: r754875 - in /james/server/trunk: imapserver-function/src/main/java/org/apache/james/imapserver/ imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/ stage/org.apache.james/jars/
Date Mon, 16 Mar 2009 11:04:02 GMT
Author: rdonkin
Date: Mon Mar 16 11:04:02 2009
New Revision: 754875

URL: http://svn.apache.org/viewvc?rev=754875&view=rev
Log:
Upgraded IMAP. IMAP-67 https://issues.apache.org/jira/browse/IMAP-67

Added:
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-deployment-0.1-SNAPSHOT.jar
  (with props)
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-jpa-0.1-SNAPSHOT.jar
  (with props)
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-store-0.1-SNAPSHOT.jar
  (with props)
Modified:
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/DefaultImapFactory.java
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapHandler.java
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapServer.java
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManager.java
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManagerProvider.java
    james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultUserManager.java
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-api-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-decode-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-mailbox-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-message-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-processor-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-seda-0.1-SNAPSHOT.jar
    james/server/trunk/stage/org.apache.james/jars/apache-james-imap-torque-0.1-SNAPSHOT.jar

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/DefaultImapFactory.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/DefaultImapFactory.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/DefaultImapFactory.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/DefaultImapFactory.java
Mon Mar 16 11:04:02 2009
@@ -34,7 +34,7 @@
 import org.apache.james.mailboxmanager.torque.DefaultMailboxManagerProvider;
 import org.apache.james.mailboxmanager.torque.DefaultMailboxManager;
 import org.apache.james.mailboxmanager.torque.DefaultUserManager;
-import org.apache.james.mailboxmanager.manager.MailboxManagerProvider;
+import org.apache.james.imap.mailbox.MailboxManagerProvider;
 import org.apache.james.services.FileSystem;
 import org.apache.james.user.impl.file.FileUserMetaDataRepository;
 

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapHandler.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapHandler.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapHandler.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapHandler.java
Mon Mar 16 11:04:02 2009
@@ -89,7 +89,7 @@
 
             // Write welcome message
                  
-            response.okResponse(null, hello);
+            response.hello(hello);
 
             session = new ImapSessionImpl();
             
@@ -100,6 +100,9 @@
                 helper.getWatchdog().reset();
             }
             helper.getWatchdog().stop();
+            if (session != null) {
+                session.logout();
+            }
             
             getLogger().info(
                     "Connection from " + helper.getRemoteHost() + " (" + helper.getRemoteIP()

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapServer.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapServer.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapServer.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/imapserver/ImapServer.java
Mon Mar 16 11:04:02 2009
@@ -19,6 +19,9 @@
 
 package org.apache.james.imapserver;
 
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+
 import java.util.Date;
 import java.util.concurrent.CountDownLatch;
 import java.util.concurrent.TimeUnit;
@@ -35,10 +38,10 @@
 import org.apache.james.api.user.UsersRepository;
 import org.apache.james.imap.main.ImapRequestHandler;
 import org.apache.james.imapserver.DefaultImapFactory;
-import org.apache.james.mailboxmanager.MailboxSession;
-import org.apache.james.mailboxmanager.mailbox.Mailbox;
-import org.apache.james.mailboxmanager.manager.MailboxManager;
-import org.apache.james.mailboxmanager.manager.MailboxManagerProvider;
+import org.apache.james.imap.mailbox.MailboxSession;
+import org.apache.james.imap.mailbox.Mailbox;
+import org.apache.james.imap.mailbox.MailboxManager;
+import org.apache.james.imap.mailbox.MailboxManagerProvider;
 import org.apache.james.services.FileSystem;
 import org.apache.james.socket.AbstractJamesService;
 import org.apache.james.socket.ProtocolHandler;
@@ -176,14 +179,21 @@
         final MailboxSession session = mailboxManager.createSession();
         try
         {
-            final Mailbox mailbox = mailboxManager.getMailbox(name, true);
+            final Mailbox mailbox = mailboxManager.getMailbox(name);
             
             if (mailbox == null) {
                 final String error = "Mailbox for user " + username
                         + " was not found on this server.";
                 throw new MessagingException(error);
             }
-            mailbox.appendMessage(mail, new Date(), null, session);
+
+            final ByteArrayOutputStream baos = new ByteArrayOutputStream();
+            mail.writeTo(baos);
+            mailbox.appendMessage(baos.toByteArray() , new Date(), session, true);
+        }
+        catch (IOException e)
+        {
+            throw new MessagingException("Failed to write mail message", e);
         }
         finally 
         {

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManager.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManager.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManager.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManager.java
Mon Mar 16 11:04:02 2009
@@ -32,7 +32,7 @@
 import org.apache.commons.configuration.BaseConfiguration;
 import org.apache.commons.configuration.PropertiesConfiguration;
 import org.apache.commons.logging.impl.AvalonLogger;
-import org.apache.james.mailboxmanager.MailboxManagerException;
+import org.apache.james.imap.mailbox.MailboxException;
 import org.apache.james.mailboxmanager.torque.om.MailboxRowPeer;
 import org.apache.james.mailboxmanager.torque.om.MessageBodyPeer;
 import org.apache.james.mailboxmanager.torque.om.MessageFlagsPeer;
@@ -111,7 +111,7 @@
                 } catch (TorqueException e1) {
 
                 }
-                throw new MailboxManagerException(e);
+                throw new MailboxException(e);
             }
         }
     }

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManagerProvider.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManagerProvider.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManagerProvider.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultMailboxManagerProvider.java
Mon Mar 16 11:04:02 2009
@@ -19,9 +19,9 @@
 
 package org.apache.james.mailboxmanager.torque;
 
-import org.apache.james.mailboxmanager.MailboxManagerException;
-import org.apache.james.mailboxmanager.manager.MailboxManager;
-import org.apache.james.mailboxmanager.manager.MailboxManagerProvider;
+import org.apache.james.imap.mailbox.MailboxException;
+import org.apache.james.imap.mailbox.MailboxManager;
+import org.apache.james.imap.mailbox.MailboxManagerProvider;
 
 public class DefaultMailboxManagerProvider implements MailboxManagerProvider {
 
@@ -33,7 +33,7 @@
     }
 
     public MailboxManager getMailboxManager()
-            throws MailboxManagerException {
+            throws MailboxException {
         return mailboxManager;
     }
 }

Modified: james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultUserManager.java
URL: http://svn.apache.org/viewvc/james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultUserManager.java?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
--- james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultUserManager.java
(original)
+++ james/server/trunk/imapserver-function/src/main/java/org/apache/james/mailboxmanager/torque/DefaultUserManager.java
Mon Mar 16 11:04:02 2009
@@ -29,7 +29,7 @@
 import org.apache.james.api.user.UserMetaDataRespository;
 import org.apache.james.api.user.UserRepositoryException;
 import org.apache.james.api.user.UsersRepository;
-import org.apache.james.mailboxmanager.manager.SubscriptionException;
+import org.apache.james.imap.mailbox.SubscriptionException;
 
 /**
  * Stores subscription data in the user meta-data repository.

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-api-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-api-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-decode-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-decode-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Added: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-deployment-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-deployment-0.1-SNAPSHOT.jar?rev=754875&view=auto
==============================================================================
Binary file - no diff available.

Propchange: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-deployment-0.1-SNAPSHOT.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-jpa-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-jpa-0.1-SNAPSHOT.jar?rev=754875&view=auto
==============================================================================
Binary file - no diff available.

Propchange: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-jpa-0.1-SNAPSHOT.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-mailbox-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-mailbox-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-message-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-message-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-processor-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-processor-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-seda-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-seda-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.

Added: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-store-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-store-0.1-SNAPSHOT.jar?rev=754875&view=auto
==============================================================================
Binary file - no diff available.

Propchange: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-store-0.1-SNAPSHOT.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: james/server/trunk/stage/org.apache.james/jars/apache-james-imap-torque-0.1-SNAPSHOT.jar
URL: http://svn.apache.org/viewvc/james/server/trunk/stage/org.apache.james/jars/apache-james-imap-torque-0.1-SNAPSHOT.jar?rev=754875&r1=754874&r2=754875&view=diff
==============================================================================
Binary files - no diff available.



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


Mime
View raw message