Hi Nico,

yes, I did.
I also run from the terminal "./mvnw clean verify -Pintegration-test" and I
get the same error

I also invalidated cache, deleted the
~/.m2/...flink dir.
~/.idea
Imported to IntelliJ from scratch

I am sure that the class is in "flink-runtime_2.12" dependency.
When I start my Job from IntelliJ using my dev profile it works. But when I
use the int-test profile defined on maven it doesn't. I literally copied
everything from one profile to another and it still does not work.

<dependency>
          <groupId>org.apache.flink</groupId>
          <artifactId>flink-runtime_2.12</artifactId>
          <version>${flink.version}</version>
          <exclusions>
            <exclusion>
              <groupId>com.sun.jersey</groupId>
              <artifactId>*</artifactId>
            </exclusion>
            <exclusion>
              <groupId>javax.servlet</groupId>
              <artifactId>servlet-api</artifactId>
            </exclusion>
          </exclusions>
          <type>test-jar</type> <!-- If I remove this line I get another
error -->
          <scope>test</scope> <!-- same error with or without this -->
        </dependency>

Worth mention also that I had to add this dependency to get rid of the
error "ClassNotFoundException
org.apache.kafka.common.protocol.SecurityProtocol". Addind it on my
int-test profile does not solve the first error as well.
<dependency>
          <groupId>org.springframework.kafka</groupId>
          <artifactId>spring-kafka-test</artifactId>
          <!--<version>2.8.0</version>-->
          <!--<scope>test</scope>-->
        </dependency>

*--*
*-- Felipe Gutierrez*
*-- skype: felipe.o.gutierrez*


On Fri, Nov 26, 2021 at 11:22 AM Nicolaus Weidner <
nicolaus.weid...@ververica.com> wrote:

> Hi Felipe,
>
> just a quick question to make sure: did you do a full rebuild of your
> project after changing the Spring boot version?
>
> Best,
> Nico
>
> On Thu, Nov 25, 2021 at 8:01 PM Felipe Gutierrez <
> felipe.o.gutier...@gmail.com> wrote:
>
>> Hi community,
>>
>> I am using Flink 1.11 + Java 8 and I was updating my application from
>> Spring boot 1 to spring boot 2.6. Then my Integration Test of Flink + Kafka
>> started giving me this error: "java.lang.NoClassDefFoundError:
>> scala/concurrent/ExecutionContext$parasitic$". The older version of spring
>> boot 1 I didn't have this error. The exact line on my INT test is where I
>> use:
>>
>> org.apache.flink.runtime.minicluster.TestingMiniCluster flink;
>> flink.start();
>>
>> I also have this line that I am thinking to replace. but I don't think it
>> is related
>> import scala.concurrent.duration.FiniteDuration;
>> private FiniteDuration timeout = new FiniteDuration(15L,
>> TimeUnit.SECONDS);
>>
>> I tried to add this dependency but it didn't make any difference.
>> <dependency>
>>       <groupId>org.scala-lang</groupId>
>>       <artifactId>scala-library</artifactId>
>>       <version>2.12.0</version>
>>     </dependency>
>>
>> Does anybody have an idea of what I am missing?
>>
>> Full stack trace:
>> java.lang.NoClassDefFoundError:
>> scala/concurrent/ExecutionContext$parasitic$
>>
>> at
>> scala.concurrent.java8.FuturesConvertersImplCompat$.InternalCallbackExecutor(FuturesConvertersImplCompat.scala:7)
>> at scala.compat.java8.FutureConverters$.toJava(FutureConverters.scala:72)
>> at
>> scala.compat.java8.FutureConverters$FutureOps$.toJava$extension(FutureConverters.scala:195)
>> at akka.pattern.Patterns$.ask(Patterns.scala:94)
>> at akka.pattern.Patterns.ask(Patterns.scala)
>> at
>> org.apache.flink.runtime.rpc.akka.SupervisorActor.startAkkaRpcActor(SupervisorActor.java:173)
>> at
>> org.apache.flink.runtime.rpc.akka.AkkaRpcService.registerAkkaRpcActor(AkkaRpcService.java:293)
>> at
>> org.apache.flink.runtime.rpc.akka.AkkaRpcService.startServer(AkkaRpcService.java:221)
>> at org.apache.flink.runtime.rpc.RpcEndpoint.<init>(RpcEndpoint.java:129)
>> at
>> org.apache.flink.runtime.metrics.dump.MetricQueryService.<init>(MetricQueryService.java:75)
>> at
>> org.apache.flink.runtime.metrics.dump.MetricQueryService.createMetricQueryService(MetricQueryService.java:252)
>> at
>> org.apache.flink.runtime.metrics.MetricRegistryImpl.startQueryService(MetricRegistryImpl.java:182)
>> at
>> org.apache.flink.runtime.minicluster.MiniCluster.start(MiniCluster.java:307)
>>
>> Thanks,
>> Felipe
>> *--*
>> *-- Felipe Gutierrez*
>> *-- skype: felipe.o.gutierrez*
>>
>

Reply via email to