Permalink
Switch branches/tags
Commits on Jun 11, 2013
  1. Fixed a ChannelClosedException

    kohsuke committed Jun 11, 2013
    littleproxy is terminating the connection to DeployIt server right after the request headers are sent in an ordinarly termination sequence.
    
    Debug output verbosity increase:
    -------------
    import java.util.logging.*;
    Logger.getLogger("org.littleshoot.proxy").setLevel(Level.ALL);
    def ch = new ConsoleHandler();
    ch.setLevel(Level.ALL);
    Logger.getLogger("org.littleshoot.proxy").addHandler(ch);
    System.out.println("Setup logging to ALL");
    -------------
    
    1. restart the master
    2. setup verbose logging (slow because of classloading)
    3. run the test cycle
    4. watch nohup.out
    
    The first run succeeds and the output from little proxy is:
    
    Jun 10, 2013 4:45:21 PM org.littleshoot.proxy.HttpRelayingHandler messageReceived
    INFO: Finished processing message
    
    In between time out message?
    
    Jun 10, 2013 4:46:02 PM org.littleshoot.proxy.HttpRequestHandler onRelayChannelClose
    INFO: Not closing browser to proxy channel. Still 0 connections and awaiting 0 responses
    
    I then start the next build and the processing of the problematic request is:
    
    Jun 10, 2013 4:47:21 PM org.littleshoot.proxy.HttpRequestHandler processMessage
    
    ------------
    It turns out that the channels that's being created in 16:47 isn't being used. The error is on 0x0b43e0f7 that's created a lot earlier, and it's leaped by the idle thread.
    
    The first read packet that arrived, little-proxy tries to forward that and it tries to send it on a channel that's already closed.
    
    ------------
    
    We think what's going on is that:
    
      - HttpRequestHandler.processMessage creates a new connection but forgets to set to 'this.currentChannelFuture'.
      - a payload arrives and it chokes:
    
       java.nio.channels.ClosedChannelException
        at org.jboss.netty.channel.socket.nio.NioWorker.cleanUpWriteBuffer(NioWorker.java:636)
        at org.jboss.netty.channel.socket.nio.NioWorker.writeFromUserCode(NioWorker.java:369)
        at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink.eventSunk(NioClientSocketPipelineSink.java:117)
        at org.jboss.netty.channel.Channels.write(Channels.java:632)
        at org.jboss.netty.handler.codec.oneone.OneToOneEncoder.handleDownstream(OneToOneEncoder.java:70)
        at org.jboss.netty.channel.Channels.write(Channels.java:611)
        at org.jboss.netty.channel.Channels.write(Channels.java:578)
        at org.jboss.netty.channel.AbstractChannel.write(AbstractChannel.java:259)
        at org.littleshoot.proxy.HttpRequestHandler$1.operationComplete(HttpRequestHandler.java:243)
        at org.jboss.netty.channel.CompleteChannelFuture.addListener(CompleteChannelFuture.java:53)
        at org.littleshoot.proxy.HttpRequestHandler.processChunk(HttpRequestHandler.java:239)
        at org.littleshoot.proxy.HttpRequestHandler.messageReceived(HttpRequestHandler.java:216)
    
    on the upstream, adamfisk/LittleProxy@f540936 introduces a seemingly related change that sets this value.
Commits on Jan 16, 2013
  1. pointer to the Wiki

    kohsuke committed Jan 16, 2013
  2. preparing toward a release

    kohsuke committed Jan 16, 2013
Commits on Jan 11, 2013
  1. bug in the socket handling

    kohsuke committed Jan 11, 2013
Commits on Jan 7, 2013
  1. added help screen

    kohsuke committed Jan 7, 2013
  2. More progress

    kohsuke committed Jan 7, 2013
  3. doc improvements

    kohsuke committed Jan 7, 2013