Author: asankha
Date: Tue Oct 31 19:15:18 2006
New Revision: 469765

URL: http://svn.apache.org/viewvc?view=rev&rev=469765
Log:
committing local changes until I can revisit this later

Modified:
    
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpListener.java
    
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpSender.java
    
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/Worker.java
    
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/impl/ReactorTester.java

Modified: 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpListener.java
URL: 
http://svn.apache.org/viewvc/incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpListener.java?view=diff&rev=469765&r1=469764&r2=469765
==============================================================================
--- 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpListener.java
 (original)
+++ 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpListener.java
 Tue Oct 31 19:15:18 2006
@@ -154,7 +154,8 @@
                 SessionContext sessionContext = 
sessionManager.getSessionContext(sessionKey);
                 msgContext.setSessionContext(sessionContext);
             }*/
-            workerPool.execute(new Worker(cfgCtx, msgContext, request));
+            //workerPool.execute(new Worker(cfgCtx, msgContext, request));
+            new Worker(cfgCtx, msgContext, request).run();
 
         } catch (AxisFault e) {
             HttpResponse response = request.createResponse();

Modified: 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpSender.java
URL: 
http://svn.apache.org/viewvc/incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpSender.java?view=diff&rev=469765&r1=469764&r2=469765
==============================================================================
--- 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpSender.java
 (original)
+++ 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/NHttpSender.java
 Tue Oct 31 19:15:18 2006
@@ -166,7 +166,8 @@
 
         
message.addHeader(org.apache.axis2.transport.niohttp.impl.Constants.CONTENT_TYPE,
             contentType + "; charset=" + format.getCharSetEncoding());
-
+        
message.addHeader(org.apache.axis2.transport.niohttp.impl.Constants.TRANSFER_ENCODING,
+            org.apache.axis2.transport.niohttp.impl.Constants.CHUNKED);
         OutputStream out = message.getOutputStream();
         format.setDoOptimize(msgContext.isDoingMTOM());
         try {

Modified: 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/Worker.java
URL: 
http://svn.apache.org/viewvc/incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/Worker.java?view=diff&rev=469765&r1=469764&r2=469765
==============================================================================
--- 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/Worker.java
 (original)
+++ 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/Worker.java
 Tue Oct 31 19:15:18 2006
@@ -61,7 +61,10 @@
             processGet(response);
 
         } else if (Constants.POST.equals(request.getMethod())) {
+            response.addHeader(Constants.TRANSFER_ENCODING, Constants.CHUNKED);
+            response.addHeader(Constants.CONTENT_TYPE, "text/xml; 
charset=utf-8");
             processPost(response);
+            response.commit();
 
         } else {
             handleException("Unsupported method : " + request.getMethod(), 
null, response);

Modified: 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/impl/ReactorTester.java
URL: 
http://svn.apache.org/viewvc/incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/impl/ReactorTester.java?view=diff&rev=469765&r1=469764&r2=469765
==============================================================================
--- 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/impl/ReactorTester.java
 (original)
+++ 
incubator/synapse/branches/NIO/modules/niohttp/src/org/apache/axis2/transport/niohttp/impl/ReactorTester.java
 Tue Oct 31 19:15:18 2006
@@ -206,9 +206,9 @@
         });
     }
 
-    public void runGenericSynapseUseCase() throws IOException {
+    public void testGenericSynapseUseCase() throws IOException {
 
-        synapseReactor = Reactor.createReactor(null, 9002, false,
+        synapseReactor = Reactor.createReactor(null, 8080, false,
 
             new HttpService() {
 
@@ -243,12 +243,12 @@
         Thread t = new Thread(synapseReactor);
         t.start();
 
-        /*// wait till the reactor is done
+        // wait till the reactor is done
         try {
             t.join();
         } catch (InterruptedException e) {
             e.printStackTrace();
-        }*/
+        }
     }
 
 



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to