Skip to content

Commit

Permalink
[FLINK-7810] [build] Switch from custom Flakka to Akka 2.4.x
Browse files Browse the repository at this point in the history
We can do this now that we dropped support for Scala 2.10.

This closes apache#4807
  • Loading branch information
aljoscha authored and StephanEwen committed Oct 14, 2017
1 parent a6039ca commit 5a5006c
Show file tree
Hide file tree
Showing 15 changed files with 65 additions and 76 deletions.
4 changes: 2 additions & 2 deletions flink-clients/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
16 changes: 8 additions & 8 deletions flink-mesos/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,14 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-actor_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-actor_${scala.binary.version}</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-remote_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_${scala.binary.version}</artifactId>
<scope>provided</scope>
<exclusions>
<!-- exclude the lower/wrong version of Protobuf here -->
Expand All @@ -81,8 +81,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-slf4j_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-slf4j_${scala.binary.version}</artifactId>
<scope>provided</scope>
</dependency>

Expand Down Expand Up @@ -138,8 +138,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>

Expand Down
6 changes: 0 additions & 6 deletions flink-queryable-state/flink-queryable-state-java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,6 @@ under the License.
<scope>test</scope>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.apache.flink</groupId>
<artifactId>flink-runtime_${scala.binary.version}</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,9 +227,9 @@ under the License.
<exclude>org.scala-lang:scala-library</exclude>
<exclude>org.scala-lang:scala-compiler</exclude>
<exclude>org.scala-lang:scala-reflect</exclude>
<exclude>com.data-artisans:flakka-actor_*</exclude>
<exclude>com.data-artisans:flakka-remote_*</exclude>
<exclude>com.data-artisans:flakka-slf4j_*</exclude>
<exclude>com.typesafe.akka:akka-actor_*</exclude>
<exclude>com.typesafe.akka:akka-remote_*</exclude>
<exclude>com.typesafe.akka:akka-slf4j_*</exclude>
<exclude>io.netty:netty-all</exclude>
<exclude>io.netty:netty</exclude>
<exclude>commons-fileupload:commons-fileupload</exclude>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -229,9 +229,9 @@ under the License.
<exclude>org.scala-lang:scala-library</exclude>
<exclude>org.scala-lang:scala-compiler</exclude>
<exclude>org.scala-lang:scala-reflect</exclude>
<exclude>com.data-artisans:flakka-actor_*</exclude>
<exclude>com.data-artisans:flakka-remote_*</exclude>
<exclude>com.data-artisans:flakka-slf4j_*</exclude>
<exclude>com.typesafe.akka:akka-actor_*</exclude>
<exclude>com.typesafe.akka:akka-remote_*</exclude>
<exclude>com.typesafe.akka:akka-slf4j_*</exclude>
<exclude>io.netty:netty-all</exclude>
<exclude>io.netty:netty</exclude>
<exclude>commons-fileupload:commons-fileupload</exclude>
Expand Down
4 changes: 2 additions & 2 deletions flink-runtime-web/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>

Expand Down
16 changes: 8 additions & 8 deletions flink-runtime/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,18 +110,18 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-actor_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-actor_${scala.binary.version}</artifactId>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-remote_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_${scala.binary.version}</artifactId>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-slf4j_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-slf4j_${scala.binary.version}</artifactId>
</dependency>

<dependency>
Expand Down Expand Up @@ -212,8 +212,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,6 @@ protected void run() {
assertTrue(ioManager.isProperlyShutDown());
assertTrue(memManager.isShutdown());
} finally {
TestingUtils.stopActorsGracefully(Arrays.asList(jobManager, taskManager));

if (actorSystem != null) {
actorSystem.shutdown();

Expand Down
4 changes: 2 additions & 2 deletions flink-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -561,15 +561,11 @@ public Integer map(Integer value) throws Exception {

((ResponseSavepoint) Await.result(savepointFuture, deadline.timeLeft())).savepoint();
LOG.info("Retrieved savepoint: " + savepointPath + ".");

} finally {
// Shut down the Flink cluster (thereby canceling the job)
LOG.info("Shutting down Flink cluster.");
flink.shutdown();
flink.awaitTermination();

} finally {
flink.shutdown();
flink.awaitTermination();
}

try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,6 @@ public void testProgramWithAutoParallelism() {
e.printStackTrace();
fail(e.getMessage());
}
finally {
try {
cluster.stop();
}
catch (Throwable t) {
// ignore exceptions on shutdown
}
}
}

private static class ParallelismDependentInputFormat extends GenericInputFormat<Integer> {
Expand Down
4 changes: 2 additions & 2 deletions flink-yarn-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,11 @@ public abstract class YarnTestBase extends TestLogger {
protected static final String[] WHITELISTED_STRINGS = {
"akka.remote.RemoteTransportExceptionNoStackTrace",
// workaround for annoying InterruptedException logging:
// https://issues.apache.org/jira/browse/YARN-1022
"java.lang.InterruptedException"
// https://issues.apache.org/jira/browse/YARN-1022
"java.lang.InterruptedException",
// very specific on purpose
"Remote connection to [null] failed with java.net.ConnectException: Connection refused",
"java.io.IOException: Connection reset by peer"
};

// Temp directory which is deleted after the unit test.
Expand Down
22 changes: 14 additions & 8 deletions flink-yarn/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -68,23 +68,29 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-actor_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-actor_${scala.binary.version}</artifactId>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-remote_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_${scala.binary.version}</artifactId>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-camel_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-camel_${scala.binary.version}</artifactId>
<exclusions>
<exclusion>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-core</artifactId>
</exclusion>
</exclusions>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<scope>test</scope>
</dependency>

Expand Down
30 changes: 15 additions & 15 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ under the License.
<flink.reuseForks>true</flink.reuseForks>
<log4j.configuration>log4j-test.properties</log4j.configuration>
<guava.version>18.0</guava.version>
<akka.version>2.3-custom</akka.version>
<akka.version>2.4.20</akka.version>
<java.version>1.8</java.version>
<slf4j.version>1.7.7</slf4j.version>
<log4j.version>1.2.17</log4j.version>
Expand Down Expand Up @@ -399,32 +399,32 @@ under the License.
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-actor_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-actor_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-remote_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-remote_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-slf4j_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-slf4j_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-camel_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-camel_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
</dependency>

<dependency>
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
<scope>test</scope>
</dependency>
Expand Down Expand Up @@ -692,8 +692,8 @@ under the License.
com.sun.tools.javac.code.Symbol$CompletionFailure:
class file for akka.testkit.TestKit not found"
-->
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
<scope>provided</scope>
</dependency>
Expand Down Expand Up @@ -838,8 +838,8 @@ under the License.
com.sun.tools.javac.code.Symbol$CompletionFailure:
class file for akka.testkit.TestKit not found"
-->
<groupId>com.data-artisans</groupId>
<artifactId>flakka-testkit_${scala.binary.version}</artifactId>
<groupId>com.typesafe.akka</groupId>
<artifactId>akka-testkit_${scala.binary.version}</artifactId>
<version>${akka.version}</version>
<scope>provided</scope>
</dependency>
Expand Down

0 comments on commit 5a5006c

Please sign in to comment.