Remove some of Unused import warning (#24650)

This commit is contained in:
Jimin Hsieh 2018-03-16 19:08:29 +08:00 committed by Arnout Engelen
parent a878e6c9fa
commit 2c2b8ba001
150 changed files with 85 additions and 323 deletions

View file

@ -164,7 +164,6 @@ class CoordinatedShutdownSpec extends AkkaSpec(ConfigFactory.parseString(
}
"run from a given phase" in {
import system.dispatcher
val phases = Map(
"a" emptyPhase,
"b" phase("a"),
@ -188,7 +187,6 @@ class CoordinatedShutdownSpec extends AkkaSpec(ConfigFactory.parseString(
}
"only run once" in {
import system.dispatcher
val phases = Map("a" emptyPhase)
val co = new CoordinatedShutdown(extSys, phases)
co.addTask("a", "a1") { ()
@ -244,7 +242,6 @@ class CoordinatedShutdownSpec extends AkkaSpec(ConfigFactory.parseString(
}
"abort if recover=off" in {
import system.dispatcher
val phases = Map(
"a" emptyPhase,
"b" Phase(dependsOn = Set("a"), timeout = 100.millis, recover = false, enabled = true),
@ -288,7 +285,6 @@ class CoordinatedShutdownSpec extends AkkaSpec(ConfigFactory.parseString(
}
"be possible to add tasks in later phase from task in earlier phase" in {
import system.dispatcher
val phases = Map(
"a" emptyPhase,
"b" phase("a"))

View file

@ -19,7 +19,7 @@ import org.scalatest.{ BeforeAndAfterAll, BeforeAndAfterEach }
import scala.annotation.tailrec
import scala.collection.immutable
import scala.concurrent.duration._
import scala.concurrent.{ Await, Future, Promise }
import scala.concurrent.{ Await, Future }
import scala.language.postfixOps
object TypedActorSpec {

View file

@ -4,8 +4,6 @@
package akka.actor.dungeon
import java.io.NotSerializableException
import akka.actor.Actor
import akka.actor.Props

View file

@ -4,8 +4,8 @@
package akka.io
import java.io.{ File, IOException }
import java.net.{ InetSocketAddress, ServerSocket, URLClassLoader }
import java.io.IOException
import java.net.{ InetSocketAddress, ServerSocket }
import java.nio.ByteBuffer
import java.nio.channels._
import java.nio.channels.spi.SelectorProvider

View file

@ -7,7 +7,6 @@ package akka.pattern
import akka.actor._
import akka.testkit.{ TestProbe, AkkaSpec }
import akka.util.Timeout
import org.scalatest.concurrent.ScalaFutures
import scala.concurrent.Await
import scala.concurrent.duration._

View file

@ -6,7 +6,6 @@ package akka.pattern
import akka.actor._
import akka.testkit.{ AkkaSpec, TestProbe, ImplicitSender }
import org.scalatest.concurrent.ScalaFutures
import scala.concurrent.Promise
import scala.concurrent.duration._

View file

@ -7,7 +7,6 @@ package akka.pattern.extended
import akka.actor._
import akka.testkit.AkkaSpec
import akka.util.Timeout
import org.scalatest.concurrent.ScalaFutures
import scala.concurrent.duration._
object ExplicitAskSpec {

View file

@ -10,7 +10,7 @@ import java.util.{ BitSet ⇒ ProgrammaticJavaDummy }
import java.util.{ Date SerializableDummy }
import akka.actor.setup.ActorSystemSetup
import akka.actor.{ ActorSystem, BootstrapSetup, ExtendedActorSystem, Terminated }
import akka.actor.{ ActorSystem, BootstrapSetup, ExtendedActorSystem }
import akka.testkit.{ AkkaSpec, TestKit, TestProbe }
import com.typesafe.config.ConfigFactory

View file

@ -6,8 +6,6 @@ package akka
import akka.annotation.InternalApi
import scala.annotation.varargs
final class UnsupportedAkkaVersion private[akka] (msg: String) extends RuntimeException(msg)
object AkkaVersion {

View file

@ -4,9 +4,8 @@
package akka.actor
import akka.annotation.{ ApiMayChange, DoNotInherit }
import akka.annotation.DoNotInherit
import akka.japi.pf.ReceiveBuilder
import akka.japi.pf.UnitPFBuilder
import scala.runtime.BoxedUnit
import java.util.Optional

View file

@ -5,7 +5,6 @@
package akka.actor
import akka.util.JavaDurationConverters
import scala.concurrent.duration.FiniteDuration
/**

View file

@ -8,7 +8,6 @@ import java.lang.reflect.{ Modifier, ParameterizedType, TypeVariable }
import akka.japi.Creator
import akka.util.Reflect
import scala.annotation.varargs
import scala.language.existentials
import scala.annotation.tailrec
import java.lang.reflect.Constructor

View file

@ -20,8 +20,6 @@ import java.util.concurrent.ThreadLocalRandom
import scala.util.control.NonFatal
import akka.dispatch.MessageDispatcher
import akka.util.Reflect
import akka.japi.pf.ReceiveBuilder
import akka.actor.AbstractActor.Receive
import akka.annotation.InternalApi
/**

View file

@ -10,7 +10,7 @@ import akka.dispatch.sysmsg._
import java.lang.{ IllegalStateException, UnsupportedOperationException }
import akka.serialization.{ JavaSerializer, Serialization }
import akka.event.{ EventStream, Logging, LoggingAdapter, MarkerLoggingAdapter }
import akka.event.{ EventStream, Logging, MarkerLoggingAdapter }
import scala.annotation.tailrec
import java.util.concurrent.ConcurrentHashMap

View file

@ -6,7 +6,6 @@ package akka.actor
import java.util.concurrent.atomic.AtomicReference
import akka.annotation.InternalApi
import akka.routing._
import akka.util.WildcardIndex
import com.typesafe.config._

View file

@ -9,7 +9,6 @@ import akka.dispatch._
import akka.routing._
import scala.collection.immutable
import scala.language.existentials
import scala.reflect.ClassTag
/**

View file

@ -6,7 +6,6 @@ package akka.actor
import scala.concurrent.duration.FiniteDuration
import akka.annotation.DoNotInherit
import akka.dispatch.Envelope
import akka.util.OptionVal
/**

View file

@ -5,7 +5,6 @@
package akka.actor.dungeon
import scala.annotation.tailrec
import scala.util.{ Failure, Success, Try }
import akka.AkkaException
import akka.dispatch.{ Envelope, Mailbox }

View file

@ -13,7 +13,6 @@ import java.util.concurrent.{ Executor, ExecutorService, Callable }
import scala.util.{ Try, Success, Failure }
import java.util.concurrent.CompletionStage
import java.util.concurrent.CompletableFuture
import scala.collection.immutable
import akka.compat
/**

View file

@ -9,7 +9,7 @@ import java.lang.invoke.MethodType.methodType
import java.util.Collections
import java.util.concurrent.TimeUnit.MICROSECONDS
import java.util.concurrent._
import java.util.concurrent.atomic.{ AtomicInteger, AtomicReference }
import java.util.concurrent.atomic.AtomicReference
import java.util.concurrent.locks.LockSupport
import java.lang.Integer.reverseBytes

View file

@ -4,8 +4,6 @@
package akka.event
import language.implicitConversions
import akka.actor.{ ActorRef, ActorSystem }
import akka.event.Logging.simpleName
import akka.util.Subclassification

View file

@ -11,7 +11,6 @@ import com.typesafe.config.Config
import akka.actor.ActorSystem
import akka.actor.ActorRef
import akka.dispatch.ProducesMessageQueue
import akka.event.Logging.Debug
import akka.event.Logging.LogEvent
trait LoggerMessageQueueSemantics

View file

@ -9,7 +9,7 @@ import java.util.concurrent.atomic.AtomicInteger
import akka.actor.ActorSystem.Settings
import akka.actor._
import akka.annotation.{ DoNotInherit, InternalApi }
import akka.annotation.DoNotInherit
import akka.dispatch.RequiresMessageQueue
import akka.event.Logging._
import akka.util.ReentrantGuard

View file

@ -12,7 +12,7 @@ import scala.annotation.{ tailrec, varargs }
import scala.collection.IndexedSeqOptimized
import scala.collection.mutable.{ Builder, WrappedArray }
import scala.collection.immutable
import scala.collection.immutable.{ IndexedSeq, VectorBuilder, VectorIterator }
import scala.collection.immutable.{ IndexedSeq, VectorBuilder }
import scala.collection.generic.CanBuildFrom
import scala.reflect.ClassTag
import java.nio.charset.{ Charset, StandardCharsets }

View file

@ -12,7 +12,7 @@ import scala.util.control.NonFatal
import akka.util.Timeout
import akka.testkit._
import scala.concurrent.stm._
import java.util.concurrent.{ CountDownLatch, TimeUnit }
import java.util.concurrent.{ CountDownLatch }
class CountDownFunction[A](num: Int = 1) extends Function1[A, A] {
val latch = new CountDownLatch(num)

View file

@ -4,12 +4,10 @@
package akka.actor
import akka.testkit.TestProbe
import com.typesafe.config.ConfigFactory
import org.openjdk.jmh.annotations._
import java.util.concurrent.TimeUnit
import scala.concurrent.Await
import scala.annotation.tailrec
import BenchmarkActors._
import scala.concurrent.duration._

View file

@ -8,20 +8,13 @@ import java.nio.ByteBuffer
import java.util.Random
import java.util.concurrent.TimeUnit
import akka.dispatch.forkjoin.ThreadLocalRandom
import akka.io.DirectByteBufferPool
import akka.testkit.TestProbe
import com.typesafe.config.ConfigFactory
import org.openjdk.jmh.annotations._
import scala.concurrent.Await
import scala.concurrent.duration._
@State(Scope.Benchmark)
@BenchmarkMode(Array(Mode.AverageTime))
@OutputTimeUnit(TimeUnit.NANOSECONDS)
class DirectByteBufferPoolBenchmark {
import DirectByteBufferPoolBenchmark._
private val MAX_LIVE_BUFFERS = 8192

View file

@ -5,20 +5,14 @@
package akka.remote.artery
import java.util.concurrent.TimeUnit
import akka.NotUsed
import akka.actor.ActorSystem
import akka.stream.scaladsl._
import com.typesafe.config.ConfigFactory
import org.openjdk.jmh.annotations._
import scala.concurrent.Lock
import scala.util.Success
import akka.stream.impl.fusing.GraphStages
import org.reactivestreams._
import scala.concurrent.Await
import scala.concurrent.duration._
import akka.stream.ActorMaterializer
import akka.stream.ActorMaterializerSettings
import java.util.concurrent.Semaphore
import akka.stream.OverflowStrategy
import java.util.concurrent.CyclicBarrier
import java.util.concurrent.CountDownLatch

View file

@ -8,7 +8,6 @@ import java.util.concurrent.TimeUnit
import akka.actor.ActorSystem
import akka.stream.scaladsl._
import akka.{ Done, NotUsed }
import org.openjdk.jmh.annotations._
import scala.concurrent._

View file

@ -8,7 +8,6 @@ import java.util.concurrent.{ CountDownLatch, TimeUnit }
import akka.NotUsed
import akka.actor.ActorSystem
import akka.stream.impl.fusing.GraphStages
import akka.stream.scaladsl._
import akka.stream.stage._
import org.openjdk.jmh.annotations.{ OperationsPerInvocation, _ }

View file

@ -10,10 +10,6 @@ import akka.actor.ActorSystem
import akka.stream.scaladsl._
import com.typesafe.config.ConfigFactory
import org.openjdk.jmh.annotations._
import java.util.concurrent.Semaphore
import scala.util.Success
import akka.stream.impl.fusing.GraphStages
import org.reactivestreams._
import scala.concurrent.Await
import scala.concurrent.duration._
import akka.remote.artery.BenchTestSource

View file

@ -6,9 +6,7 @@ package akka.stream
import java.util.concurrent.{ Semaphore, TimeUnit }
import akka.NotUsed
import akka.actor.ActorSystem
import akka.stream.impl.fusing.GraphStages
import akka.stream.scaladsl._
import com.typesafe.config.ConfigFactory
import org.openjdk.jmh.annotations._

View file

@ -9,13 +9,12 @@ import java.util.concurrent.TimeUnit
import akka.actor.ActorSystem
import akka.stream.scaladsl._
import akka.stream.{ ActorMaterializer, Attributes, IOResult }
import akka.stream.{ ActorMaterializer, IOResult }
import akka.util.ByteString
import akka.{ Done, NotUsed }
import org.openjdk.jmh.annotations.{ BenchmarkMode, OutputTimeUnit, Scope, State, _ }
import org.openjdk.jmh.annotations.{ BenchmarkMode, Scope, State, _ }
import scala.concurrent.duration._
import scala.concurrent.{ Await, Future, Promise }
import scala.concurrent.{ Await, Future }
@State(Scope.Benchmark)
@BenchmarkMode(Array(Mode.AverageTime))

View file

@ -7,9 +7,8 @@ package akka.util
import java.nio.ByteBuffer
import java.util.concurrent.TimeUnit
import akka.util.ByteString.{ ByteString1, ByteString1C, ByteStrings }
import akka.util.ByteString.{ ByteString1C, ByteStrings }
import org.openjdk.jmh.annotations._
import org.openjdk.jmh.infra.Blackhole
@State(Scope.Benchmark)
@Measurement(timeUnit = TimeUnit.MILLISECONDS)

View file

@ -4,7 +4,6 @@
package akka.util
import java.nio.ByteBuffer
import java.util.concurrent.TimeUnit
import akka.util.ByteString.{ ByteString1C, ByteStrings }

View file

@ -10,8 +10,6 @@ import akka.actor._
import scala.concurrent.duration._
import akka.dispatch.Mapper
import scala.language.existentials
/**
* Mixed in by Actor implementations that consume message from Camel endpoints.
*/

View file

@ -10,8 +10,6 @@ import org.apache.camel.impl.DefaultExchange
import org.apache.camel.{ Exchange, ExchangePattern }
import org.scalatest.FunSuite
import scala.language.implicitConversions
class CamelExchangeAdapterTest extends FunSuite with SharedCamelSystem {
test("mustSetInMessageFromRequestMessage") {

View file

@ -5,7 +5,6 @@
package akka.camel
import language.postfixOps
import language.existentials
import akka.actor._
import org.scalatest.Matchers

View file

@ -10,7 +10,7 @@ import org.scalatest.Matchers
import org.scalatest.mock.MockitoSugar
import org.apache.camel.ProducerTemplate
import org.scalatest.WordSpec
import akka.event.{ LoggingAdapter, MarkerLoggingAdapter }
import akka.event.MarkerLoggingAdapter
import akka.actor.ActorSystem.Settings
import com.typesafe.config.ConfigFactory
import org.apache.camel.impl.DefaultCamelContext

View file

@ -18,12 +18,12 @@ import org.scalatest.{ BeforeAndAfterAll, BeforeAndAfterEach, Suite, WordSpecLik
import akka.camel.TestSupport._
import java.util.concurrent.{ CountDownLatch, TimeoutException }
import org.mockito.{ ArgumentMatcher, ArgumentMatchers, Mockito, Matchers MMatchers }
import org.mockito.{ ArgumentMatcher, ArgumentMatchers, Mockito }
import org.scalatest.Matchers
import akka.actor.Status.Failure
import com.typesafe.config.ConfigFactory
import akka.actor.ActorSystem.Settings
import akka.event.{ LoggingAdapter, MarkerLoggingAdapter }
import akka.event.MarkerLoggingAdapter
import akka.testkit.{ TestKit, TestLatch, TestProbe, TimingTest }
import org.apache.camel.impl.DefaultCamelContext

View file

@ -8,7 +8,6 @@ import akka.actor.Actor
import akka.actor.ActorLogging
import akka.actor.Props
import akka.actor.Address
import akka.cluster.InternalClusterAction
import akka.cluster.ClusterEvent
import akka.cluster.Member
import akka.cluster.Cluster

View file

@ -23,7 +23,6 @@ import akka.cluster.ddata.ORSet
import akka.cluster.ddata.ORSetKey
import akka.cluster.ddata.Replicator._
import akka.actor.Stash
import akka.cluster.ddata.DistributedData
import akka.persistence.PersistentActor
import akka.persistence.SnapshotOffer
import akka.persistence.SaveSnapshotSuccess
@ -370,7 +369,6 @@ private[akka] class RememberEntityStarter(
requestor: ActorRef) extends Actor with ActorLogging {
import context.dispatcher
import scala.concurrent.duration._
import RememberEntityStarter.Tick
var waitingForAck = ids
@ -487,7 +485,6 @@ private[akka] class PersistentShard(
typeName, shardId, entityProps, settings, extractEntityId, extractShardId, handOffStopMessage)
with RememberingShard with PersistentActor with ActorLogging {
import ShardRegion.{ EntityId, Msg }
import Shard._
import settings.tuningParameters._
@ -583,7 +580,7 @@ private[akka] class DDataShard(
typeName, shardId, entityProps, settings, extractEntityId, extractShardId, handOffStopMessage)
with RememberingShard with Stash with ActorLogging {
import ShardRegion.{ EntityId, Msg }
import ShardRegion.EntityId
import Shard._
import settings.tuningParameters._

View file

@ -4,9 +4,6 @@
package akka.cluster.sharding
import scala.concurrent.duration._
import scala.language.postfixOps
import akka.cluster.sharding.ShardRegion.EntityId
import akka.testkit.AkkaSpec

View file

@ -4,18 +4,10 @@
package akka.cluster.sharding
import akka.cluster.sharding.ShardRegion.EntityId
import akka.testkit.AkkaSpec
import scala.concurrent.{ Await, Future }
import scala.concurrent.duration._
import akka.testkit.TimingTest
import scala.concurrent.duration.Duration.DurationIsOrdered
class ConstantRateEntityRecoveryStrategySpec extends AkkaSpec {
import system.dispatcher
/*
val strategy = EntityRecoveryStrategy.constantStrategy(system, 1.second, 2)
"ConstantRateEntityRecoveryStrategy" must {

View file

@ -13,7 +13,6 @@ import akka.actor.Props
import akka.cluster.Cluster
import akka.cluster.MemberStatus
import akka.cluster.UniqueAddress
import akka.remote.RARP
import akka.testkit.AkkaSpec
import akka.testkit.TestProbe
import com.typesafe.config.ConfigFactory

View file

@ -9,7 +9,6 @@ import akka.actor.ActorSystem
import akka.actor.PoisonPill
import akka.cluster.Cluster
import akka.cluster.MemberStatus
import akka.remote.RARP
import akka.testkit.AkkaSpec
import akka.testkit.TestActors
import akka.testkit.TestProbe

View file

@ -12,18 +12,16 @@ import akka.cluster.ClusterEvent._
import akka.dispatch.{ RequiresMessageQueue, UnboundedMessageQueueSemantics }
import akka.Done
import akka.actor.CoordinatedShutdown.Reason
import akka.cluster.ClusterUserAction.JoinTo
import akka.pattern.ask
import akka.remote.QuarantinedEvent
import akka.util.Timeout
import com.typesafe.config.{ Config, ConfigFactory }
import com.typesafe.config.Config
import scala.collection.immutable
import scala.concurrent.duration._
import scala.concurrent.Future
import scala.concurrent.Promise
import scala.util.control.NonFatal
import language.existentials
/**
* Base trait for all cluster messages. All ClusterMessage's are serializable.

View file

@ -6,7 +6,7 @@ package akka.cluster
import scala.annotation.tailrec
import scala.collection.immutable
import akka.actor.{ Actor, ActorLogging, ActorPath, ActorRef, ActorSelection, Address, DeadLetterSuppression, RootActorPath }
import akka.actor.{ Actor, ActorLogging, ActorPath, ActorSelection, Address, DeadLetterSuppression, RootActorPath }
import akka.cluster.ClusterEvent._
import akka.remote.FailureDetectorRegistry
import akka.remote.HeartbeatMessage

View file

@ -4,15 +4,14 @@
package akka.cluster
import akka.actor.{ Actor, ActorLogging, ActorSelection, Address, NoSerializationVerificationNeeded, RootActorPath }
import akka.actor.{ Actor, ActorLogging, ActorSelection, Address, NoSerializationVerificationNeeded }
import akka.annotation.InternalApi
import akka.cluster.ClusterEvent._
import akka.cluster.ClusterSettings.DataCenter
import akka.event.Logging
import akka.remote.FailureDetectorRegistry
import akka.util.ConstantFun
import scala.collection.{ SortedSet, immutable, breakOut }
import scala.collection.{ SortedSet, breakOut }
/**
* INTERNAL API

View file

@ -6,9 +6,8 @@ package akka.cluster
import akka.ConfigurationException
import akka.actor.{ ActorSystem, ExtendedActorSystem, Props }
import com.typesafe.config.Config
import scala.concurrent.duration.{ Duration, FiniteDuration }
import scala.concurrent.duration.FiniteDuration
/**
* INTERNAL API

View file

@ -4,7 +4,7 @@
package akka.cluster
import scala.collection.{ SortedSet, immutable }
import scala.collection.immutable
import ClusterSettings.DataCenter
import MemberStatus._
import akka.annotation.InternalApi

View file

@ -4,13 +4,11 @@
package akka.cluster
import akka.actor.{ ActorSystem, Address }
import akka.actor.ActorSystem
import akka.cluster.MemberStatus.Removed
import akka.testkit.TestKitBase
import com.typesafe.config.{ Config, ConfigFactory }
import scala.collection.{ immutable im }
/**
* Builds on TestKitBase to provide some extra utilities to run cluster test.
*

View file

@ -4,15 +4,11 @@
package akka.cluster
import akka.actor.{ ActorSystem, Address }
import akka.cluster.InternalClusterAction.LeaderActionsTick
import akka.cluster.MemberStatus.{ Removed, Up }
import akka.cluster.MemberStatus.Up
import akka.testkit.{ AkkaSpec, LongRunningTest }
import com.typesafe.config.{ Config, ConfigFactory }
import org.scalatest.{ Matchers, WordSpec }
import scala.concurrent.duration._
import scala.collection.JavaConverters._
import scala.collection.{ immutable im }
object JoinConfigCompatCheckerSpec {

View file

@ -19,7 +19,6 @@ import akka.actor.ActorRef
import akka.testkit.TestKitExtension
import akka.actor.ActorIdentity
import akka.actor.Identify
import com.typesafe.config.ConfigValueFactory
object ReliableProxySpec extends MultiNodeConfig {
val local = role("local")

View file

@ -8,8 +8,7 @@ import akka.actor.{ ActorRef, PoisonPill }
import akka.contrib.circuitbreaker.CircuitBreakerProxy._
import akka.testkit.{ AkkaSpec, TestProbe }
import akka.util.Timeout
import org.scalatest.time.{ Millis, Second, Span }
import org.scalatest.{ GivenWhenThen, Matchers }
import org.scalatest.GivenWhenThen
import scala.concurrent.duration._
import scala.language.postfixOps

View file

@ -8,7 +8,7 @@ import akka.cluster.Cluster
import akka.cluster.UniqueAddress
import akka.util.HashCode
import akka.annotation.InternalApi
import akka.cluster.ddata.ORMap.{ AtomicDeltaOp, ZeroTag }
import akka.cluster.ddata.ORMap.ZeroTag
import scala.collection.immutable

View file

@ -285,8 +285,6 @@ final class ORSet[A] private[akka] (
extends DeltaReplicatedData
with ReplicatedDataSerialization with RemovedNodePruning with FastMerge {
import ORSet.{ AddDeltaOp, RemoveDeltaOp }
type T = ORSet[A]
type D = ORSet.DeltaOp

View file

@ -23,12 +23,9 @@ import akka.serialization.BaseSerializer
import akka.protobuf.{ ByteString, GeneratedMessage }
import akka.util.ByteString.UTF_8
import scala.collection.immutable.TreeMap
import akka.cluster.UniqueAddress
import java.io.NotSerializableException
import akka.cluster.ddata.protobuf.msg.ReplicatorMessages.OtherMessage
import akka.cluster.ddata.ORSet.DeltaOp
private object ReplicatedDataSerializer {
/*

View file

@ -14,7 +14,6 @@ import akka.actor.ExtendedActorSystem
import akka.actor.Props
import akka.cluster.ddata.GSet
import akka.cluster.ddata.GSetKey
import akka.cluster.ddata.PruningState
import akka.cluster.ddata.PruningState.PruningInitialized
import akka.cluster.ddata.PruningState.PruningPerformed
import akka.cluster.ddata.Replicator._

View file

@ -73,8 +73,6 @@ trait Player { this: TestConductorExt ⇒
* set in [[akka.remote.testconductor.Conductor]]`.startController()`.
*/
def startClient(name: RoleName, controllerAddr: InetSocketAddress): Future[Done] = {
import ClientFSM._
import akka.actor.FSM._
import Settings.BarrierTimeout
if (_client ne null) throw new IllegalStateException("TestConductorClient already started")

View file

@ -4,7 +4,6 @@
package akka.osgi
import language.existentials
import java.net.URL
import java.util.Enumeration
import org.osgi.framework.{ BundleContext, Bundle }

View file

@ -9,7 +9,7 @@ import akka.actor.SupervisorStrategy._
import akka.actor.Terminated
import akka.actor._
import akka.dispatch.sysmsg.SystemMessage
import akka.event.{ LogMarker, Logging, LoggingAdapter, MarkerLoggingAdapter }
import akka.event.{ LogMarker, Logging, MarkerLoggingAdapter }
import akka.pattern.pipe
import akka.remote.EndpointManager.{ Link, ResendState, Send }
import akka.remote.EndpointWriter.{ FlushAndStop, StoppedReading }

View file

@ -5,7 +5,6 @@
package akka.remote
import akka.event.Logging.Warning
import akka.event.jul.Logger
import akka.remote.FailureDetector.Clock
import java.util.concurrent.atomic.AtomicReference
import scala.annotation.tailrec

View file

@ -24,11 +24,9 @@ import akka.dispatch.{ RequiresMessageQueue, UnboundedMessageQueueSemantics }
import akka.remote.artery.ArteryTransport
import akka.remote.artery.aeron.ArteryAeronUdpTransport
import akka.remote.artery.ArterySettings
import akka.remote.artery.ArterySettings.AeronUpd
import akka.util.OptionVal
import akka.remote.artery.OutboundEnvelope
import akka.remote.artery.SystemMessageDelivery.SystemMessageEnvelope
import akka.remote.serialization.ActorRefResolveCache
import akka.remote.serialization.ActorRefResolveThreadLocalCache
import akka.remote.artery.tcp.ArteryTcpTransport

View file

@ -4,11 +4,10 @@
package akka.remote
import scala.concurrent.duration._
import scala.annotation.tailrec
import scala.util.control.NonFatal
import akka.actor.{ Actor, ActorPath, ActorPathExtractor, ActorRef, ActorSystemImpl, AddressTerminated, Deploy, InternalActorRef, Nobody, Props, VirtualPathContainer }
import akka.event.{ AddressTerminatedTopic, LogMarker, LoggingAdapter, MarkerLoggingAdapter }
import akka.event.{ AddressTerminatedTopic, LogMarker, MarkerLoggingAdapter }
import akka.dispatch.sysmsg.{ DeathWatchNotification, SystemMessage, Watch }
import akka.actor.ActorRefWithCell
import akka.actor.ActorRefScope
@ -24,7 +23,6 @@ import java.util.concurrent.ConcurrentHashMap
import scala.collection.immutable
import akka.dispatch.sysmsg.Unwatch
import akka.NotUsed
/**
* INTERNAL API

View file

@ -4,7 +4,6 @@
package akka.remote
import akka.ConfigurationException
import akka.actor._
import akka.dispatch.sysmsg.{ DeathWatchNotification, Watch }
import akka.dispatch.{ RequiresMessageQueue, UnboundedMessageQueueSemantics }

View file

@ -22,8 +22,6 @@ import akka.util.{ OptionVal, Unsafe }
import scala.concurrent.duration._
import scala.concurrent.{ Future, Promise }
import scala.util.control.NonFatal
import akka.util.ByteStringBuilder
import java.nio.ByteOrder
import akka.remote.artery.OutboundHandshake.HandshakeReq
import akka.serialization.SerializerWithStringManifest

View file

@ -168,7 +168,6 @@ private[remote] class OutboundControlJunction(
override def createLogicAndMaterializedValue(inheritedAttributes: Attributes) = {
val logic = new GraphStageLogic(shape) with InHandler with OutHandler with StageLogging with OutboundControlIngress {
import OutboundControlJunction._
val sendControlMessageCallback = getAsyncCallback[ControlMessage](internalSendControlMessage)
private val maxControlMessageBufferSize: Int = outboundContext.settings.Advanced.OutboundControlQueueSize

View file

@ -7,8 +7,6 @@ package akka.remote.artery
import akka.annotation.InternalApi
import akka.stream.scaladsl.PartitionHub
import org.agrona.concurrent.OneToOneConcurrentArrayQueue
import java.util.concurrent.atomic.AtomicInteger
import org.agrona.concurrent.ManyToManyConcurrentArrayQueue
/**
* INTERNAL API

View file

@ -28,7 +28,6 @@ private[akka] object ImmutableLongMap {
*/
private[akka] class ImmutableLongMap[A >: Null] private (
private val keys: Array[Long], private val values: Array[A])(implicit t: ClassTag[A]) {
import ImmutableLongMap.MaxScanLength
val size: Int = keys.length

View file

@ -6,7 +6,6 @@ package akka.remote.artery
import akka.actor.InternalActorRef
import akka.util.OptionVal
import akka.actor.Address
import akka.actor.ActorRef
/**

View file

@ -7,14 +7,12 @@ package akka.remote.artery
import akka.actor.ActorRef
import akka.actor.ActorSelection
import akka.actor.ActorSelectionMessage
import akka.actor.Address
import akka.actor.ExtendedActorSystem
import akka.actor.InternalActorRef
import akka.actor.LocalRef
import akka.actor.PossiblyHarmful
import akka.actor.RepointableRef
import akka.dispatch.sysmsg.SystemMessage
import akka.event.{ LogMarker, Logging, LoggingReceive }
import akka.event.{ LogMarker, Logging }
import akka.remote.RemoteActorRefProvider
import akka.remote.RemoteRef
import akka.util.OptionVal

View file

@ -6,17 +6,12 @@ package akka.remote.artery
import java.util.Queue
import akka.stream.stage.GraphStage
import akka.stream.stage.OutHandler
import akka.stream.Attributes
import akka.stream.Outlet
import akka.stream.SourceShape
import akka.stream.stage.GraphStageLogic
import org.agrona.concurrent.ManyToOneConcurrentArrayQueue
import akka.stream.stage.GraphStageWithMaterializedValue
import org.agrona.concurrent.ManyToOneConcurrentLinkedQueueTail
import org.agrona.concurrent.ManyToOneConcurrentLinkedQueue
import java.util.concurrent.atomic.AtomicInteger
import scala.annotation.tailrec
import scala.concurrent.Promise
@ -24,8 +19,6 @@ import scala.util.Try
import scala.util.Success
import scala.util.Failure
import akka.actor.ActorRef
/**
* INTERNAL API
*/

View file

@ -7,7 +7,6 @@ package akka.remote.artery
import java.util.concurrent.atomic.AtomicReference
import scala.annotation.tailrec
import scala.concurrent.duration._
import akka.actor.Address
import akka.remote.transport.ThrottlerTransportAdapter.Direction
import akka.stream.Attributes

View file

@ -6,8 +6,6 @@ package akka.remote.artery
package aeron
import akka.util.PrettyDuration.PrettyPrintableDuration
import java.nio.ByteBuffer
import java.util.concurrent.atomic.AtomicInteger
import scala.annotation.tailrec
import scala.concurrent.Future
import scala.concurrent.Promise

View file

@ -25,12 +25,10 @@ import akka.remote.RemoteActorRefProvider
import akka.remote.RemoteTransportException
import akka.remote.artery.compress._
import akka.stream.KillSwitches
import akka.stream.SharedKillSwitch
import akka.stream.scaladsl.Flow
import akka.stream.scaladsl.Keep
import akka.stream.scaladsl.Sink
import akka.stream.scaladsl.Source
import akka.util.OptionVal
import io.aeron.Aeron
import io.aeron.AvailableImageHandler
import io.aeron.CncFileDescriptor

View file

@ -5,9 +5,8 @@
package akka.remote.artery.compress
import java.util.Objects
import java.util.concurrent.atomic.AtomicReference
import scala.annotation.{ switch, tailrec }
import scala.annotation.tailrec
import scala.reflect.ClassTag
/**

View file

@ -9,10 +9,8 @@ import java.net.InetSocketAddress
import scala.concurrent.Await
import scala.concurrent.ExecutionContext
import scala.concurrent.ExecutionContextExecutor
import scala.concurrent.Future
import scala.concurrent.Promise
import scala.concurrent.duration._
import scala.util.Failure
import scala.util.Success
import scala.util.Try
@ -30,13 +28,10 @@ import akka.remote.artery.Decoder.InboundCompressionAccess
import akka.remote.artery.compress._
import akka.stream.Attributes
import akka.stream.Attributes.LogLevels
import akka.stream.FlowShape
import akka.stream.Graph
import akka.stream.KillSwitches
import akka.stream.Materializer
import akka.stream.SharedKillSwitch
import akka.stream.SinkShape
import akka.stream.scaladsl.Broadcast
import akka.stream.scaladsl.Flow
import akka.stream.scaladsl.GraphDSL
import akka.stream.scaladsl.Keep

View file

@ -9,7 +9,7 @@ import akka.protobuf.ByteString
import com.typesafe.config.{ Config, ConfigFactory }
import akka.actor.{ Deploy, ExtendedActorSystem, NoScopeGiven, Props, Scope }
import akka.remote.DaemonMsgCreate
import akka.remote.WireFormats.{ DaemonMsgCreateData, DeployData, PropsData, SerializedMessage }
import akka.remote.WireFormats.{ DaemonMsgCreateData, DeployData, PropsData }
import akka.routing.{ NoRouter, RouterConfig }
import scala.reflect.ClassTag

View file

@ -6,8 +6,7 @@ package akka.remote.serialization
import java.nio.{ BufferOverflowException, ByteBuffer }
import akka.actor.{ ExtendedActorSystem, Kill, PoisonPill }
import akka.remote.OversizedPayloadException
import akka.actor.ExtendedActorSystem
import akka.serialization.{ BaseSerializer, ByteBufferSerializer }
import akka.util.ByteString

View file

@ -25,7 +25,6 @@ import scala.util.{ Failure, Success }
import scala.util.control.NonFatal
import akka.dispatch.sysmsg.{ Unwatch, Watch }
import akka.dispatch.{ RequiresMessageQueue, UnboundedMessageQueueSemantics }
import akka.event.LoggingAdapter
import akka.remote.RARP
class ThrottlerProvider extends TransportAdapterProvider {

View file

@ -6,10 +6,8 @@ package akka.remote
import akka.testkit._
import scala.concurrent.duration._
import akka.actor.{ Address, ExtendedActorSystem, ActorSystem }
import akka.actor.{ Address, ActorSystem }
import com.typesafe.config.ConfigFactory
import java.nio.channels.ServerSocketChannel
import java.net.InetSocketAddress
import scala.collection.JavaConverters._
class DaemonicSpec extends AkkaSpec {

View file

@ -4,12 +4,9 @@
package akka.remote
import java.util.concurrent.ThreadLocalRandom
import akka.actor._
import akka.remote.transport._
import akka.testkit._
import akka.util.ByteString
import com.typesafe.config._
import scala.concurrent.duration._

View file

@ -4,7 +4,6 @@
package akka.remote.artery
import akka.testkit.AkkaSpec
import com.typesafe.config.ConfigFactory
import akka.actor.ActorSystem
import akka.remote.transport.netty.NettyTransportSpec._

View file

@ -4,10 +4,8 @@
package akka.remote.artery
import akka.actor.{ Actor, ActorIdentity, ActorSystem, Identify, Props, RootActorPath }
import akka.remote.RARP
import akka.testkit.{ AkkaSpec, ImplicitSender, TestProbe }
import com.typesafe.config.ConfigFactory
import akka.actor.{ Actor, ActorIdentity, Identify, Props }
import akka.testkit.TestProbe
import scala.concurrent.Await
import scala.concurrent.duration._

View file

@ -6,7 +6,7 @@ package akka.remote.artery
import scala.concurrent.duration._
import akka.actor.{ ActorIdentity, ActorSystem, Identify }
import akka.actor.{ ActorIdentity, Identify }
import akka.testkit._
import com.typesafe.config.ConfigFactory
import akka.actor.RootActorPath
@ -22,7 +22,6 @@ object HandshakeDenySpec {
}
class HandshakeDenySpec extends ArteryMultiNodeSpec(HandshakeDenySpec.commonConfig) with ImplicitSender {
import HandshakeDenySpec._
var systemB = newRemoteSystem(name = Some("systemB"))

View file

@ -6,8 +6,8 @@ package akka.remote.artery
import scala.concurrent.duration._
import akka.actor.{ ActorIdentity, ActorSystem, Identify }
import akka.testkit.{ AkkaSpec, ImplicitSender }
import akka.actor.{ ActorIdentity, Identify }
import akka.testkit.ImplicitSender
import akka.testkit.SocketUtil
import akka.testkit.TestActors
import com.typesafe.config.ConfigFactory

View file

@ -7,7 +7,7 @@ package akka.remote.artery
import scala.concurrent.duration._
import akka.actor._
import akka.testkit.{ AkkaSpec, ImplicitSender }
import akka.testkit.ImplicitSender
import akka.testkit.SocketUtil
import akka.testkit.TestActors
import com.typesafe.config.ConfigFactory

View file

@ -4,7 +4,6 @@
package akka.remote.artery
import scala.concurrent.duration._
import org.scalatest.Matchers
import org.scalatest.WordSpec
import akka.util.OptionVal

View file

@ -6,10 +6,8 @@ package akka.remote.artery
import scala.concurrent.duration._
import akka.actor.ActorSystem
import akka.actor.RootActorPath
import akka.remote.RARP
import akka.testkit.AkkaSpec
import akka.testkit.ImplicitSender
import akka.testkit.SocketUtil
import akka.testkit.TestActors

View file

@ -6,12 +6,9 @@ package akka.remote.artery
import scala.concurrent.duration._
import akka.actor.Address
import akka.remote.EndpointManager.Send
import akka.remote.RemoteActorRef
import akka.remote.UniqueAddress
import akka.remote.artery.OutboundHandshake.HandshakeReq
import akka.remote.artery.OutboundHandshake.HandshakeTimeoutException
import akka.remote.artery.SystemMessageDelivery._
import akka.stream.ActorMaterializer
import akka.stream.ActorMaterializerSettings
import akka.stream.scaladsl.Keep
@ -21,7 +18,6 @@ import akka.stream.testkit.scaladsl.TestSink
import akka.stream.testkit.scaladsl.TestSource
import akka.testkit.AkkaSpec
import akka.testkit.ImplicitSender
import akka.testkit.TestProbe
import akka.util.OptionVal
class OutboundHandshakeSpec extends AkkaSpec with ImplicitSender {

View file

@ -7,7 +7,6 @@ package akka.remote.artery
import akka.actor.{ EmptyLocalActorRef, InternalActorRef }
import akka.remote.RemoteActorRef
import akka.testkit.{ EventFilter, TestActors }
import akka.actor.Props
import akka.actor.ExtendedActorSystem
import akka.actor.ActorRefScope

View file

@ -4,10 +4,8 @@
package akka.remote.artery
import akka.actor.{ Actor, ActorIdentity, ActorLogging, ActorRef, ActorRefScope, ActorSelection, ActorSystem, ExtendedActorSystem, Identify, PoisonPill, Props, Terminated }
import akka.remote.RARP
import akka.testkit.{ AkkaSpec, ImplicitSender, SocketUtil, TestActors }
import com.typesafe.config.ConfigFactory
import akka.actor.{ Actor, ActorIdentity, ActorLogging, ActorRef, ActorRefScope, ActorSelection, Identify, PoisonPill, Props, Terminated }
import akka.testkit.{ ImplicitSender, SocketUtil, TestActors }
import scala.concurrent.duration._
import akka.testkit.JavaSerializable

View file

@ -4,11 +4,9 @@
package akka.remote.artery
import akka.actor.{ ActorSystem, ExtendedActorSystem }
import akka.remote.RARP
import akka.actor.ActorSystem
import akka.testkit.SocketUtil._
import akka.testkit.{ AkkaSpec, EventFilter, ImplicitSender, TestActors, TestEvent, TestProbe }
import com.typesafe.config.ConfigFactory
import akka.testkit.{ EventFilter, ImplicitSender, TestActors, TestEvent, TestProbe }
import scala.concurrent.duration._

View file

@ -10,10 +10,8 @@ import com.typesafe.config.ConfigFactory
import akka.actor.RootActorPath
import scala.concurrent.duration._
import akka.testkit.SocketUtil
import akka.event.Logging.Warning
import akka.remote.QuarantinedEvent
import akka.remote.RARP
import akka.remote.RemoteActorRef
object RemoteDeathWatchSpec {
val otherPort = SocketUtil.temporaryLocalPort(udp = true)

View file

@ -4,14 +4,10 @@
package akka.remote.artery
import scala.collection.immutable
import akka.testkit._
import akka.routing._
import akka.actor._
import akka.remote.routing._
import com.typesafe.config._
import akka.testkit.TestActors.echoActorProps
import akka.remote.{ RARP, RemoteScope }
import akka.remote.RARP
object RemoteDeploymentSpec {
class Echo1 extends Actor {

View file

@ -7,7 +7,7 @@ package akka.remote.artery
import akka.actor.{ ActorRef, ActorSystem, ExtendedActorSystem, InternalActorRef }
import akka.event._
import akka.testkit.TestEvent.Mute
import akka.testkit.{ AkkaSpec, EventFilter, TestEvent, TestProbe }
import akka.testkit.{ AkkaSpec, EventFilter, TestProbe }
import akka.util.OptionVal
import java.nio.{ ByteBuffer, CharBuffer }
import java.nio.charset.Charset

View file

@ -7,11 +7,10 @@ package akka.remote.artery
import java.io.NotSerializableException
import java.util.concurrent.ThreadLocalRandom
import akka.actor.{ Actor, ActorRef, ActorSystem, Address, Deploy, ExtendedActorSystem, PoisonPill, Props }
import akka.actor.{ Actor, ActorRef, PoisonPill, Props }
import akka.remote.{ AssociationErrorEvent, DisassociatedEvent, OversizedPayloadException, RARP }
import akka.testkit.{ AkkaSpec, EventFilter, ImplicitSender, TestActors }
import akka.testkit.{ EventFilter, ImplicitSender, TestActors }
import akka.util.ByteString
import com.typesafe.config.ConfigFactory
import scala.concurrent.duration._
@ -29,8 +28,6 @@ class RemoteMessageSerializationSpec extends ArteryMultiNodeSpec("""
akka.actor.serialize-creators = off
""") with ImplicitSender {
import RemoteMessageSerializationSpec._
val maxPayloadBytes = RARP(system).provider.remoteSettings.Artery.Advanced.MaximumFrameSize
val remoteSystem = newRemoteSystem()

View file

@ -4,9 +4,8 @@
package akka.remote.artery
import akka.actor.{ Actor, ActorIdentity, ActorRef, ActorSystem, Deploy, Identify, PoisonPill, Props, RootActorPath }
import akka.remote.RARP
import akka.testkit.{ AkkaSpec, ImplicitSender, TestActors, TestProbe }
import akka.actor.{ Actor, ActorIdentity, ActorRef, Deploy, Identify, PoisonPill, Props, RootActorPath }
import akka.testkit.{ ImplicitSender, TestActors, TestProbe }
import com.typesafe.config.{ Config, ConfigFactory }
import scala.concurrent.duration._

View file

@ -4,12 +4,9 @@
package akka.remote.artery
import scala.concurrent.duration._
import akka.actor.{ ActorIdentity, ActorSystem, ExtendedActorSystem, Identify, RootActorPath }
import akka.remote.RARP
import akka.testkit.{ AkkaSpec, ImplicitSender }
import akka.actor.{ ActorIdentity, Identify, RootActorPath }
import akka.testkit.ImplicitSender
import akka.testkit.TestActors
import com.typesafe.config.ConfigFactory
import akka.testkit.EventFilter
object SerializationErrorSpec {

Some files were not shown because too many files have changed in this diff Show more