axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hemap...@apache.org
Subject svn commit: r209065 - in /webservices/axis/trunk/java/modules: core/src/org/apache/axis2/transport/mail/server/ samples/
Date Mon, 04 Jul 2005 12:51:24 GMT
Author: hemapani
Date: Mon Jul  4 05:51:22 2005
New Revision: 209065

URL: http://svn.apache.org/viewcvs?rev=209065&view=rev
Log:
remove the print stacktrace and remove the chuncked tests

Modified:
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailServer.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailSorter.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Server.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
    webservices/axis/trunk/java/modules/samples/project.xml

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailServer.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailServer.java?rev=209065&r1=209064&r2=209065&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailServer.java
(original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailServer.java
Mon Jul  4 05:51:22 2005
@@ -2,6 +2,7 @@
 
 import org.apache.axis2.context.ConfigurationContext;
 import org.apache.axis2.context.ConfigurationContextFactory;
+import org.apache.axis2.engine.AxisFault;
 import org.apache.axis2.transport.mail.SimpleMailListener;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
@@ -14,18 +15,18 @@
 	public ConfigurationContext configurationContext = null;
 	protected static Log log = LogFactory.getLog(SimpleMailListener.class.getName());
 
-    public MailServer(String dir, int popPort,int smtpPort) {
+    public MailServer(String dir, int popPort,int smtpPort) throws AxisFault {
             try {
                 ConfigurationContextFactory builder = new ConfigurationContextFactory();
                 configurationContext = builder.buildConfigurationContext(dir);
             } catch (Exception e) {
-                e.printStackTrace();
+                log.error(e);
             }
             try {
                 System.out.println("Sleeping for a bit to let the engine start up.");
                 Thread.sleep(2000);
             } catch (InterruptedException e1) {
-                log.debug(e1.getMessage(), e1);
+                log.error(e1);
             }
             st = new Storage();
             // Start up the two servers and lets have some fun. - CT
@@ -35,13 +36,13 @@
             pop3Server.start();
 
         }
-	public MailServer(ConfigurationContext configurationContext,int popPort,int smtpPort){
+	public MailServer(ConfigurationContext configurationContext,int popPort,int smtpPort) throws
AxisFault{
 	    this.configurationContext = configurationContext;
         try {
             System.out.println("Sleeping for a bit to let the engine start up.");
             Thread.sleep(2000);
         } catch (InterruptedException e1) {
-            log.debug(e1.getMessage(), e1);
+            log.error(e1);
         }
 
 	    st = new Storage();

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailSorter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailSorter.java?rev=209065&r1=209064&r2=209065&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailSorter.java
(original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/MailSorter.java
Mon Jul  4 05:51:22 2005
@@ -95,7 +95,6 @@
             // invoke the Axis engine
             engine.receive(msgContext);
         } catch (Exception e) {
-            e.printStackTrace();
             AxisFault af;
             if (e instanceof AxisFault) {
                 af = (AxisFault) e;

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Server.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Server.java?rev=209065&r1=209064&r2=209065&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Server.java
(original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Server.java
Mon Jul  4 05:51:22 2005
@@ -3,22 +3,27 @@
 import java.io.IOException;
 import java.net.ServerSocket;
 import java.net.Socket;
+
+import org.apache.axis2.engine.AxisFault;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 /**
  * @author Chamil Thanthrimudalige
  */
 
 public class POP3Server extends Thread {
+    protected static Log log = LogFactory.getLog(POP3Server.class.getName());
     private ServerSocket serverSocket;
     private Storage st = null;
 
     
-    public POP3Server(Storage st,int port) {
+    public POP3Server(Storage st,int port) throws AxisFault {
     	this.st = st;
         try {
             serverSocket = new ServerSocket(port);
             System.out.println("Server started on port " + port);
         } catch(IOException e) {
-            e.printStackTrace();
+            throw new AxisFault(e);
         }
     }
 
@@ -29,7 +34,7 @@
                 POP3Worker thread = new POP3Worker(socket, st);
                 thread.start();
             } catch(Exception e) {
-            	e.printStackTrace();
+            	log.error(e);
             }
         }
     }

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java?rev=209065&r1=209064&r2=209065&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
(original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/mail/server/POP3Worker.java
Mon Jul  4 05:51:22 2005
@@ -5,6 +5,10 @@
 
 import javax.mail.MessagingException;
 import javax.mail.internet.MimeMessage;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
 import java.io.*;
 import java.net.Socket;
 import java.util.ArrayList;
@@ -14,6 +18,7 @@
     private Socket socket;
     private Storage st;
     boolean doneProcess = false;
+    protected static Log log = LogFactory.getLog(POP3Server.class.getName());
     int numDeleted = 0 ; //This is a small hack to get the deleting working with the ArrayList.
To keep it simple.
     public POP3Worker(Socket socket, Storage st) {
     		this.socket = socket;
@@ -36,7 +41,7 @@
             }
             socket.close();
         } catch(Exception e) {
-            e.printStackTrace();
+            log.error(e);
         }
 
     }

Modified: webservices/axis/trunk/java/modules/samples/project.xml
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/samples/project.xml?rev=209065&r1=209064&r2=209065&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/samples/project.xml (original)
+++ webservices/axis/trunk/java/modules/samples/project.xml Mon Jul  4 05:51:22 2005
@@ -147,7 +147,7 @@
         <exclude>**/*Abstract*.java</exclude>
 	    <exclude>**/*Util*.java</exclude>
 		<exclude>**/*InteropStubTest.java</exclude>
-	<!--	<exclude>**/*EchoRawXMLChunckedTest.java</exclude> -->
+	        <exclude>**/*EchoRawXMLChunckedTest.java</exclude> >
 		<exclude>**org/apache/axis2/mail/*.java</exclude>
 		<exclude>**org/apache/axis2/mtom/*.java</exclude>
 <!--		<exclude>**/*MailEchoRawXMLTest.java</exclude> 



Mime
View raw message