Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

optimizing imports

Conflicts:

	finagle-thrift/src/main/java/ThriftServerTest.java
  • Loading branch information...
commit 15b164ebf413187c15d2e681b6ce5c00dd7fb2a3 1 parent 950bfa2
Nick Kallen authored
View
5 finagle-core/src/test/scala/com/twitter/finagle/integration/EmbeddedServer.scala
@@ -14,12 +14,11 @@ import org.jboss.netty.channel.group.DefaultChannelGroup
import org.jboss.netty.handler.codec.http._
import org.jboss.netty.util.HashedWheelTimer
-import com.twitter.util.Duration
import com.twitter.conversions.time._
import com.twitter.ostrich.StatsCollection
import com.twitter.finagle.util.Conversions._
-import com.twitter.finagle.RandomSocket
+import com.twitter.util.{RandomSocket, Duration}
object EmbeddedServer {
def apply() = new EmbeddedServer(RandomSocket())
@@ -75,7 +74,7 @@ class EmbeddedServer(val addr: SocketAddress) {
override def channelOpen(ctx: ChannelHandlerContext, e: ChannelStateEvent) {
if (isConnectionNonresponsive)
ctx.getChannel.setReadable(false)
-
+
channels.add(ctx.getChannel)
stats.incr("opened")
super.channelClosed(ctx, e)
View
17 finagle-thrift/src/main/java/ThriftServerTest.java
@@ -1,22 +1,13 @@
package com.twitter.finagle.javaapi;
-import java.net.InetSocketAddress;
-import java.net.SocketAddress;
-import java.util.concurrent.Executors;
-
-import org.apache.thrift.TBase;
-import org.jboss.netty.bootstrap.*;
-import org.jboss.netty.buffer.*;
-import org.jboss.netty.channel.*;
-import org.jboss.netty.handler.codec.http.*;
-import com.twitter.finagle.service.*;
-import com.twitter.finagle.builder.*;
+import com.twitter.finagle.builder.ServerBuilder;
+import com.twitter.finagle.service.Service;
import com.twitter.finagle.thrift.*;
+import com.twitter.silly.Silly;
import com.twitter.util.Future;
-import com.twitter.util.*;
-import com.twitter.silly.Silly;
+import java.net.InetSocketAddress;
public class ThriftServerTest {
public static void runServer() {
View
2  finagle-thrift/src/main/scala/com/twitter/finagle/thrift/ChannelBufferTransport.scala
@@ -2,7 +2,7 @@ package com.twitter.finagle.thrift
import org.apache.thrift.transport.TTransport
-import org.jboss.netty.buffer.{ChannelBuffer, ChannelBuffers}
+import org.jboss.netty.buffer.ChannelBuffer
class ChannelBufferTransport(underlying: ChannelBuffer) extends TTransport {
override def isOpen = true
View
4 finagle-thrift/src/main/scala/com/twitter/finagle/thrift/ThriftClientCodec.scala
@@ -1,7 +1,7 @@
package com.twitter.finagle.thrift
-import org.apache.thrift.{TBase, TApplicationException}
-import org.apache.thrift.protocol.{TMessage, TMessageType, TProtocol, TBinaryProtocol}
+import org.apache.thrift.TApplicationException
+import org.apache.thrift.protocol.{TMessageType, TBinaryProtocol}
import org.jboss.netty.buffer.{ChannelBuffer, ChannelBuffers}
import org.jboss.netty.channel._
View
6 finagle-thrift/src/main/scala/com/twitter/finagle/thrift/ThriftProcessorHandler.scala
@@ -1,11 +1,9 @@
package com.twitter.finagle.thrift
-import org.jboss.netty.channel.{
- Channels, SimpleChannelUpstreamHandler,
- MessageEvent, ChannelHandlerContext}
+import org.jboss.netty.channel._
import org.jboss.netty.buffer.{ChannelBuffer, ChannelBuffers}
-import org.apache.thrift.{TProcessor, TProcessorFactory}
+import org.apache.thrift.TProcessorFactory
import org.apache.thrift.protocol.TBinaryProtocol
class ThriftProcessorHandler(processorFactory: TProcessorFactory)
View
4 finagle-thrift/src/main/scala/com/twitter/finagle/thrift/ThriftServerCodec.scala
@@ -1,7 +1,7 @@
package com.twitter.finagle.thrift
-import org.apache.thrift.{TBase, TApplicationException}
-import org.apache.thrift.protocol.{TMessage, TMessageType, TProtocol, TBinaryProtocol}
+import org.apache.thrift.TApplicationException
+import org.apache.thrift.protocol.{TMessageType, TBinaryProtocol}
import org.jboss.netty.buffer.{ChannelBuffer, ChannelBuffers}
import org.jboss.netty.channel._
View
2  finagle-thrift/src/main/scala/com/twitter/finagle/thrift/Types.scala
@@ -3,7 +3,7 @@ package com.twitter.finagle.thrift
import scala.reflect.BeanProperty
import org.apache.thrift.protocol.{TMessage, TMessageType, TProtocol}
-import org.apache.thrift.{TFieldIdEnum, TBase, TApplicationException}
+import org.apache.thrift.{TBase, TApplicationException}
/**
* The ThriftCall object represents a thrift dispatch on the
Please sign in to comment.
Something went wrong with that request. Please try again.