title: Why does it not recognize asScala method?
body: <p>I have the following code, that does not compile: </p>
  
  <pre><code>import akka.NotUsed
  import akka.actor.typed.Behavior
  import akka.actor.typed.scaladsl.Behaviors
  import akka.pattern.FutureRef
  import akka.stream.scaladsl._
  import akka.stream.typed.scaladsl.ActorMaterializer
  import org.apache.kafka.clients.admin._
  import scala.jdk.FutureConverters._
  
  
  import scala.concurrent.{ExecutionContext, Future}
  import scala.concurrent.duration
  
  object KafkaDetectorActor {
  
    val create: Behavior[NotUsed] = Behaviors.setup { context =&gt;
      implicit val system = context.system
      implicit val materializer = ActorMaterializer()
      implicit val dispatcher = context.system.dispatchers
  
  
      Behaviors.same
    }
  
    private def health(server: String)(implicit executor: ExecutionContext): Future[Boolean] = {
      val props = new Properties
      props.put(AdminClientConfig.BOOTSTRAP_SERVERS_CONFIG, server)
      props.put(AdminClientConfig.CONNECTIONS_MAX_IDLE_MS_CONFIG, "10000")
      props.put(AdminClientConfig.REQUEST_TIMEOUT_MS_CONFIG, "5000")
  
          AdminClient
            .create(props)
            .listTopics()
            .names()
            .asScala
  
    }
  </code></pre>
  
  <p>where <a href="https://kafka.apache.org/22/javadoc/org/apache/kafka/clients/admin/ListTopicsResult.html#names--" rel="nofollow noreferrer"><code>names</code></a> returns <code>KafkaFuture[java.util.Set[String]]</code>.</p>
  
  <p>It does not recognize <code>asScala</code> method. The <code>scala.jdk.FutureConverters._</code> library is imported. What am I doing wrong?</p>