+pro add Akka Streams HTTP to master build
> merged akka-bench-jmh-dev with akka-bench-jmh > renamed akka-stream-tck to more correctly named akka-stream-tests-tck > merged java8 tests with normal tests in http
This commit is contained in:
parent
0763a150e2
commit
f6147972d7
53 changed files with 503 additions and 21 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -41,6 +41,7 @@ _dump
|
||||||
_mb
|
_mb
|
||||||
activemq-data
|
activemq-data
|
||||||
akka-contrib/rst_preprocessed/
|
akka-contrib/rst_preprocessed/
|
||||||
|
akka-docs-dev/rst_preprocessed/
|
||||||
akka-docs/_build/
|
akka-docs/_build/
|
||||||
akka-docs/exts/
|
akka-docs/exts/
|
||||||
akka-docs/rst_preprocessed/
|
akka-docs/rst_preprocessed/
|
||||||
|
|
|
||||||
|
|
@ -18,9 +18,9 @@ These guidelines mainly apply to Typesafe’s “mature” projects - not necess
|
||||||
|
|
||||||
Depending on which version (or sometimes module) you want to work on, you should target a specific branch as explained below:
|
Depending on which version (or sometimes module) you want to work on, you should target a specific branch as explained below:
|
||||||
|
|
||||||
* `master` – development branch of Akka 2.4.x
|
* `master` – active development branch of Akka 2.4.x
|
||||||
* `release-2.3` – maintanance branch of Akka 2.3.x
|
* `release-2.3` – maintanance branch of Akka 2.3.x
|
||||||
* `release 2.3-dev` – development branch of Akka Streams and HTTP (only)
|
* similarily `release-2.#` branches contain legacy versions of Akka
|
||||||
|
|
||||||
## General Workflow
|
## General Workflow
|
||||||
|
|
||||||
|
|
|
||||||
12
akka-http-core/build.sbt
Normal file
12
akka-http-core/build.sbt
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.httpCore
|
||||||
|
|
||||||
|
Dependencies.httpCore
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http-core").value
|
||||||
13
akka-http-marshallers-java/akka-http-jackson/build.sbt
Normal file
13
akka-http-marshallers-java/akka-http-jackson/build.sbt
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.httpJackson
|
||||||
|
|
||||||
|
Dependencies.httpJackson
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http-jackson").value
|
||||||
|
|
||||||
12
akka-http-marshallers-scala/akka-http-spray-json/build.sbt
Normal file
12
akka-http-marshallers-scala/akka-http-spray-json/build.sbt
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.httpSprayJson
|
||||||
|
|
||||||
|
Dependencies.httpSprayJson
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http-spray-json").value
|
||||||
12
akka-http-marshallers-scala/akka-http-xml/build.sbt
Normal file
12
akka-http-marshallers-scala/akka-http-xml/build.sbt
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.httpXml
|
||||||
|
|
||||||
|
Dependencies.httpXml
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http-xml").value
|
||||||
12
akka-http-testkit/build.sbt
Normal file
12
akka-http-testkit/build.sbt
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.httpTestkit
|
||||||
|
|
||||||
|
Dependencies.httpTestkit
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http-testkit").value
|
||||||
8
akka-http-tests/build.sbt
Normal file
8
akka-http-tests/build.sbt
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
Dependencies.httpTests
|
||||||
15
akka-http/build.sbt
Normal file
15
akka-http/build.sbt
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
import spray.boilerplate.BoilerplatePlugin._
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.http
|
||||||
|
|
||||||
|
Dependencies.http
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-http").value
|
||||||
|
|
||||||
|
Boilerplate.settings
|
||||||
20
akka-parsing/build.sbt
Normal file
20
akka-parsing/build.sbt
Normal file
|
|
@ -0,0 +1,20 @@
|
||||||
|
import akka.{ AkkaBuild, Dependencies, Formatting, SphinxDoc }
|
||||||
|
import akka.ValidatePullRequest._
|
||||||
|
import com.typesafe.sbt.SbtScalariform.ScalariformKeys
|
||||||
|
import com.typesafe.sbt.SbtSite.site
|
||||||
|
import com.typesafe.sbt.site.SphinxSupport._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
enablePlugins(ScaladocNoVerificationOfDiagrams)
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.docFormatSettings
|
||||||
|
|
||||||
|
site.settings
|
||||||
|
|
||||||
|
Dependencies.parsing
|
||||||
|
|
||||||
|
unmanagedSourceDirectories in ScalariformKeys.format in Test <<= unmanagedSourceDirectories in Test
|
||||||
|
|
||||||
|
AkkaBuild.dontPublishSettings
|
||||||
1
akka-stream-and-http/build.sbt
Normal file
1
akka-stream-and-http/build.sbt
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
enablePlugins(akka.UnidocRoot, akka.TimeStampede, akka.UnidocWithPrValidation)
|
||||||
12
akka-stream-testkit/build.sbt
Normal file
12
akka-stream-testkit/build.sbt
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.streamTestkit
|
||||||
|
|
||||||
|
Dependencies.streamTestkit
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-stream-testkit").value
|
||||||
8
akka-stream-tests-tck/build.sbt
Normal file
8
akka-stream-tests-tck/build.sbt
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
Dependencies.streamTestsTck
|
||||||
8
akka-stream-tests/build.sbt
Normal file
8
akka-stream-tests/build.sbt
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
Dependencies.streamTests
|
||||||
15
akka-stream/build.sbt
Normal file
15
akka-stream/build.sbt
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
import akka._
|
||||||
|
import com.typesafe.tools.mima.plugin.MimaKeys
|
||||||
|
import spray.boilerplate.BoilerplatePlugin._
|
||||||
|
|
||||||
|
AkkaBuild.defaultSettings
|
||||||
|
|
||||||
|
Formatting.formatSettings
|
||||||
|
|
||||||
|
OSGi.stream
|
||||||
|
|
||||||
|
Dependencies.stream
|
||||||
|
|
||||||
|
MimaKeys.previousArtifacts := akkaStreamAndHttpPreviousArtifacts("akka-stream").value
|
||||||
|
|
||||||
|
Boilerplate.settings
|
||||||
|
|
@ -8,9 +8,7 @@ import java.io.FileInputStream
|
||||||
import java.io.InputStreamReader
|
import java.io.InputStreamReader
|
||||||
import java.util.Properties
|
import java.util.Properties
|
||||||
|
|
||||||
import akka.TestExtras.GraphiteBuildEvents
|
|
||||||
import akka.TestExtras.JUnitFileReporting
|
import akka.TestExtras.JUnitFileReporting
|
||||||
import akka.TestExtras.StatsDMetrics
|
|
||||||
import com.typesafe.sbt.S3Plugin.S3
|
import com.typesafe.sbt.S3Plugin.S3
|
||||||
import com.typesafe.sbt.S3Plugin.s3Settings
|
import com.typesafe.sbt.S3Plugin.s3Settings
|
||||||
import com.typesafe.sbt.pgp.PgpKeys.publishSigned
|
import com.typesafe.sbt.pgp.PgpKeys.publishSigned
|
||||||
|
|
@ -42,7 +40,7 @@ object AkkaBuild extends Build {
|
||||||
base = file("."),
|
base = file("."),
|
||||||
settings = parentSettings ++ Release.settings ++
|
settings = parentSettings ++ Release.settings ++
|
||||||
SphinxDoc.akkaSettings ++ Dist.settings ++ s3Settings ++
|
SphinxDoc.akkaSettings ++ Dist.settings ++ s3Settings ++
|
||||||
GraphiteBuildEvents.settings ++ Protobuf.settings ++ Seq(
|
Protobuf.settings ++ Seq(
|
||||||
parallelExecution in GlobalScope := System.getProperty("akka.parallelExecution", parallelExecutionByDefault.toString).toBoolean,
|
parallelExecution in GlobalScope := System.getProperty("akka.parallelExecution", parallelExecutionByDefault.toString).toBoolean,
|
||||||
Dist.distExclude := Seq(actorTests.id, docs.id, samples.id, osgi.id),
|
Dist.distExclude := Seq(actorTests.id, docs.id, samples.id, osgi.id),
|
||||||
|
|
||||||
|
|
@ -74,7 +72,9 @@ object AkkaBuild extends Build {
|
||||||
// samples don't work with dbuild right now
|
// samples don't work with dbuild right now
|
||||||
aggregate = Seq(actor, testkit, actorTests, remote, remoteTests, camel,
|
aggregate = Seq(actor, testkit, actorTests, remote, remoteTests, camel,
|
||||||
cluster, clusterMetrics, clusterTools, clusterSharding, distributedData,
|
cluster, clusterMetrics, clusterTools, clusterSharding, distributedData,
|
||||||
slf4j, persistence, persistenceQuery, persistenceTck, kernel, osgi, contrib, multiNodeTestkit, benchJmh, typed, protobuf)
|
slf4j, persistence, persistenceQuery, persistenceTck, kernel, osgi, contrib, multiNodeTestkit, benchJmh, typed, protobuf,
|
||||||
|
streamAndHttp
|
||||||
|
)
|
||||||
).disablePlugins(ValidatePullRequest)
|
).disablePlugins(ValidatePullRequest)
|
||||||
|
|
||||||
lazy val actor = Project(
|
lazy val actor = Project(
|
||||||
|
|
@ -185,7 +185,11 @@ object AkkaBuild extends Build {
|
||||||
lazy val persistenceQuery = Project(
|
lazy val persistenceQuery = Project(
|
||||||
id = "akka-persistence-query-experimental",
|
id = "akka-persistence-query-experimental",
|
||||||
base = file("akka-persistence-query"),
|
base = file("akka-persistence-query"),
|
||||||
dependencies = Seq(persistence % "compile;provided->provided;test->test", testkit % "compile;test->test")
|
dependencies = Seq(
|
||||||
|
stream,
|
||||||
|
persistence % "compile;provided->provided;test->test",
|
||||||
|
testkit % "compile;test->test",
|
||||||
|
streamTestkit % "compile;test->test")
|
||||||
)
|
)
|
||||||
|
|
||||||
lazy val persistenceTck = Project(
|
lazy val persistenceTck = Project(
|
||||||
|
|
@ -194,6 +198,208 @@ object AkkaBuild extends Build {
|
||||||
dependencies = Seq(persistence % "compile;provided->provided;test->test", testkit % "compile;test->test")
|
dependencies = Seq(persistence % "compile;provided->provided;test->test", testkit % "compile;test->test")
|
||||||
)
|
)
|
||||||
|
|
||||||
|
lazy val streamAndHttp = Project(
|
||||||
|
id = "akka-stream-and-http-experimental",
|
||||||
|
base = file("akka-stream-and-http"),
|
||||||
|
settings = parentSettings ++ Release.settings ++
|
||||||
|
SphinxDoc.akkaSettings ++
|
||||||
|
Dist.settings ++
|
||||||
|
Protobuf.settings ++ Seq(
|
||||||
|
unidocProjectFilter in (ScalaUnidoc, unidoc) := inAnyProject,
|
||||||
|
Dist.distExclude := Seq(),
|
||||||
|
// testMailbox in GlobalScope := System.getProperty("akka.testMailbox", "false").toBoolean,
|
||||||
|
parallelExecution in GlobalScope := System.getProperty("akka.parallelExecution", "false").toBoolean,
|
||||||
|
Publish.defaultPublishTo in ThisBuild <<= crossTarget / "repository"
|
||||||
|
// sources in JavaDoc <<= junidocSources,
|
||||||
|
|
||||||
|
// javacOptions in JavaDoc ++= Seq("-Xdoclint:none"), TODO likely still needed
|
||||||
|
// artifactName in packageDoc in JavaDoc := ((sv, mod, art) => "" + mod.name + "_" + sv.binary + "-" + mod.revision + "-javadoc.jar"),
|
||||||
|
// packageDoc in Compile <<= packageDoc in JavaDoc,
|
||||||
|
|
||||||
|
// // generate online version of docs
|
||||||
|
// sphinxInputs in Sphinx <<= sphinxInputs in Sphinx in LocalProject(docsDev.id) map { inputs => inputs.copy(tags = inputs.tags :+ "online") },
|
||||||
|
// // don't regenerate the pdf, just reuse the akka-docs version
|
||||||
|
// generatedPdf in Sphinx <<= generatedPdf in Sphinx in LocalProject(docsDev.id) map identity,
|
||||||
|
// generatedEpub in Sphinx <<= generatedEpub in Sphinx in LocalProject(docsDev.id) map identity,
|
||||||
|
|
||||||
|
// publishArtifact in packageSite := false
|
||||||
|
),
|
||||||
|
aggregate = Seq(parsing, stream, streamTestkit, streamTests, streamTestsTck, httpParent)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpParent = Project(
|
||||||
|
id = "akka-http-parent-experimental",
|
||||||
|
base = file("akka-http-parent"),
|
||||||
|
settings = parentSettings,
|
||||||
|
aggregate = Seq(
|
||||||
|
httpCore,
|
||||||
|
http,
|
||||||
|
httpTestkit,
|
||||||
|
httpTests, httpTestsJava8,
|
||||||
|
httpMarshallersScala, httpMarshallersJava
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpCore = Project(
|
||||||
|
id = "akka-http-core-experimental",
|
||||||
|
base = file("akka-http-core"),
|
||||||
|
dependencies = Seq(parsing, streamTestkit % "test->test", stream),
|
||||||
|
settings = defaultSettings
|
||||||
|
// ++ (if (GenJavaDocEnabled) Seq(
|
||||||
|
// // genjavadoc needs to generate synthetic methods since the java code uses them
|
||||||
|
// scalacOptions += "-P:genjavadoc:suppressSynthetic=false",
|
||||||
|
// // FIXME: see #18056
|
||||||
|
// sources in JavaDoc ~= (_.filterNot(_.getPath.contains("Access$minusControl$minusAllow$minusOrigin")))
|
||||||
|
// ) else Nil
|
||||||
|
// )
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val http = Project(
|
||||||
|
id = "akka-http-experimental",
|
||||||
|
base = file("akka-http"),
|
||||||
|
dependencies = Seq(httpCore),
|
||||||
|
settings =
|
||||||
|
defaultSettings ++
|
||||||
|
Seq(
|
||||||
|
scalacOptions in Compile += "-language:_"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val streamTestkit = Project(
|
||||||
|
id = "akka-stream-testkit",
|
||||||
|
base = file("akka-stream-testkit"), // TODO that persistence dependency
|
||||||
|
dependencies = Seq(stream, persistence % "compile;provided->provided;test->test", testkit % "compile;test->test"),
|
||||||
|
settings = defaultSettings ++ experimentalSettings
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpTestkit = Project(
|
||||||
|
id = "akka-http-testkit-experimental",
|
||||||
|
base = file("akka-http-testkit"),
|
||||||
|
dependencies = Seq(http, streamTestkit),
|
||||||
|
settings =
|
||||||
|
defaultSettings ++ Seq(
|
||||||
|
scalacOptions in Compile += "-language:_"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpTests = Project(
|
||||||
|
id = "akka-http-tests-experimental",
|
||||||
|
base = file("akka-http-tests"),
|
||||||
|
dependencies = Seq(httpTestkit % "test", httpSprayJson, httpXml, httpJackson),
|
||||||
|
settings =
|
||||||
|
defaultSettings ++ Seq(
|
||||||
|
publishArtifact := false,
|
||||||
|
scalacOptions in Compile += "-language:_"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpMarshallersScala = Project(
|
||||||
|
id = "akka-http-marshallers-scala-experimental",
|
||||||
|
base = file("akka-http-marshallers-scala"),
|
||||||
|
settings = parentSettings
|
||||||
|
).aggregate(httpSprayJson, httpXml)
|
||||||
|
|
||||||
|
lazy val httpXml =
|
||||||
|
httpMarshallersScalaSubproject("xml")
|
||||||
|
|
||||||
|
lazy val httpSprayJson =
|
||||||
|
httpMarshallersScalaSubproject("spray-json")
|
||||||
|
.settings(Dependencies.httpSprayJson)
|
||||||
|
.settings(OSGi.httpSprayJson: _*)
|
||||||
|
|
||||||
|
lazy val httpMarshallersJava = Project(
|
||||||
|
id = "akka-http-marshallers-java-experimental",
|
||||||
|
base = file("akka-http-marshallers-java"),
|
||||||
|
settings = defaultSettings ++ parentSettings
|
||||||
|
).aggregate(httpJackson)
|
||||||
|
|
||||||
|
lazy val httpJackson =
|
||||||
|
httpMarshallersJavaSubproject("jackson")
|
||||||
|
|
||||||
|
def httpMarshallersScalaSubproject(name: String) =
|
||||||
|
Project(
|
||||||
|
id = s"akka-http-$name-experimental",
|
||||||
|
base = file(s"akka-http-marshallers-scala/akka-http-$name"),
|
||||||
|
dependencies = Seq(http),
|
||||||
|
settings = defaultSettings
|
||||||
|
)
|
||||||
|
|
||||||
|
def httpMarshallersJavaSubproject(name: String) =
|
||||||
|
Project(
|
||||||
|
id = s"akka-http-$name-experimental",
|
||||||
|
base = file(s"akka-http-marshallers-java/akka-http-$name"),
|
||||||
|
dependencies = Seq(http),
|
||||||
|
settings = defaultSettings
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpTestsJava8 = Project(
|
||||||
|
id = "akka-http-tests-java8-experimental",
|
||||||
|
base = file("akka-http-tests-java8"),
|
||||||
|
dependencies = Seq(http, httpJackson, httpTestkit % "test"),
|
||||||
|
settings =
|
||||||
|
defaultSettings ++
|
||||||
|
Seq(
|
||||||
|
publishArtifact := false,
|
||||||
|
Dependencies.httpTestsJava8,
|
||||||
|
fork in run := true,
|
||||||
|
connectInput := true,
|
||||||
|
javacOptions in compile := Seq("-source", "8"),
|
||||||
|
fork in Test := true,
|
||||||
|
// test discovery is broken when sbt isn't run with a Java 8 compatible JVM, so we define a single
|
||||||
|
// Suite where all tests need to be registered
|
||||||
|
definedTests in Test := {
|
||||||
|
def pseudoJUnitRunWithFingerprint =
|
||||||
|
// we emulate a junit-interface fingerprint here which cannot be accessed statically
|
||||||
|
new sbt.testing.AnnotatedFingerprint {
|
||||||
|
def annotationName = "org.junit.runner.RunWith"
|
||||||
|
def isModule = false
|
||||||
|
}
|
||||||
|
Seq(new TestDefinition("AllJavaTests", pseudoJUnitRunWithFingerprint, false, Array.empty))
|
||||||
|
},
|
||||||
|
// don't ignore Suites which is the default for the junit-interface
|
||||||
|
testOptions += Tests.Argument(TestFrameworks.JUnit, "--ignore-runners="),
|
||||||
|
mainClass in run in Test := Some("akka.http.javadsl.SimpleServerApp")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val macroParadise = Seq(
|
||||||
|
DependencyHelpers.versionDependentDeps(
|
||||||
|
Dependencies.Compile.scalaReflect % "provided"
|
||||||
|
),
|
||||||
|
addCompilerPlugin("org.scalamacros" % "paradise" % "2.0.1" cross CrossVersion.full)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val parsing = Project(
|
||||||
|
id = "akka-parsing-experimental",
|
||||||
|
base = file("akka-parsing"),
|
||||||
|
settings = defaultSettings ++ OSGi.parsing ++ macroParadise ++ Seq(
|
||||||
|
scalacOptions += "-language:_",
|
||||||
|
// ScalaDoc doesn't like the macros
|
||||||
|
sources in doc in Compile := List()
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val stream = Project(
|
||||||
|
id = "akka-stream-experimental",
|
||||||
|
base = file("akka-stream"),
|
||||||
|
dependencies = Seq(actor),
|
||||||
|
settings = defaultSettings ++ experimentalSettings
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val streamTests = Project(
|
||||||
|
id = "akka-stream-tests-experimental",
|
||||||
|
base = file("akka-stream-tests"),
|
||||||
|
dependencies = Seq(streamTestkit % "test->test", stream),
|
||||||
|
settings = defaultSettings ++ experimentalSettings
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val streamTestsTck = Project(
|
||||||
|
id = "akka-stream-tck-experimental",
|
||||||
|
base = file("akka-stream-tck"),
|
||||||
|
dependencies = Seq(streamTestkit % "test->test", stream),
|
||||||
|
settings = defaultSettings ++ experimentalSettings
|
||||||
|
)
|
||||||
|
|
||||||
lazy val kernel = Project(
|
lazy val kernel = Project(
|
||||||
id = "akka-kernel",
|
id = "akka-kernel",
|
||||||
base = file("akka-kernel"),
|
base = file("akka-kernel"),
|
||||||
|
|
@ -402,7 +608,7 @@ object AkkaBuild extends Build {
|
||||||
testOptions += Tests.Argument(TestFrameworks.JUnit, "-v", "-a")
|
testOptions += Tests.Argument(TestFrameworks.JUnit, "-v", "-a")
|
||||||
) ++
|
) ++
|
||||||
mavenLocalResolverSettings ++
|
mavenLocalResolverSettings ++
|
||||||
JUnitFileReporting.settings ++ StatsDMetrics.settings
|
JUnitFileReporting.settings
|
||||||
|
|
||||||
def akkaPreviousArtifacts(id: String): Def.Initialize[Set[sbt.ModuleID]] = Def.setting {
|
def akkaPreviousArtifacts(id: String): Def.Initialize[Set[sbt.ModuleID]] = Def.setting {
|
||||||
if (enableMiMa) {
|
if (enableMiMa) {
|
||||||
|
|
@ -428,6 +634,11 @@ object AkkaBuild extends Build {
|
||||||
else Set.empty
|
else Set.empty
|
||||||
}
|
}
|
||||||
|
|
||||||
|
def akkaStreamAndHttpPreviousArtifacts(id: String): Def.Initialize[Set[sbt.ModuleID]] = Def.setting {
|
||||||
|
// TODO fix MiMa for 2.4 Akka streams
|
||||||
|
Set.empty
|
||||||
|
}
|
||||||
|
|
||||||
def loadSystemProperties(fileName: String): Unit = {
|
def loadSystemProperties(fileName: String): Unit = {
|
||||||
import scala.collection.JavaConverters._
|
import scala.collection.JavaConverters._
|
||||||
val file = new File(fileName)
|
val file = new File(fileName)
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import sbt._
|
||||||
import Keys._
|
import Keys._
|
||||||
|
|
||||||
object Dependencies {
|
object Dependencies {
|
||||||
|
import DependencyHelpers._
|
||||||
|
|
||||||
lazy val scalaTestVersion = settingKey[String]("The version of ScalaTest to use.")
|
lazy val scalaTestVersion = settingKey[String]("The version of ScalaTest to use.")
|
||||||
lazy val scalaStmVersion = settingKey[String]("The version of ScalaSTM to use.")
|
lazy val scalaStmVersion = settingKey[String]("The version of ScalaSTM to use.")
|
||||||
|
|
@ -20,9 +21,6 @@ object Dependencies {
|
||||||
object Compile {
|
object Compile {
|
||||||
// Compile
|
// Compile
|
||||||
|
|
||||||
// FIXME: change to project dependency once akka-stream merged to master
|
|
||||||
val akkaStream = "com.typesafe.akka" %% "akka-stream-experimental" % "2.0.1"
|
|
||||||
|
|
||||||
val camelCore = "org.apache.camel" % "camel-core" % "2.13.4" exclude("org.slf4j", "slf4j-api") // ApacheV2
|
val camelCore = "org.apache.camel" % "camel-core" % "2.13.4" exclude("org.slf4j", "slf4j-api") // ApacheV2
|
||||||
|
|
||||||
// when updating config version, update links ActorSystem ScalaDoc to link to the updated version
|
// when updating config version, update links ActorSystem ScalaDoc to link to the updated version
|
||||||
|
|
@ -30,8 +28,12 @@ object Dependencies {
|
||||||
val netty = "io.netty" % "netty" % "3.10.3.Final" // ApacheV2
|
val netty = "io.netty" % "netty" % "3.10.3.Final" // ApacheV2
|
||||||
val scalaStm = Def.setting { "org.scala-stm" %% "scala-stm" % scalaStmVersion.value } // Modified BSD (Scala)
|
val scalaStm = Def.setting { "org.scala-stm" %% "scala-stm" % scalaStmVersion.value } // Modified BSD (Scala)
|
||||||
|
|
||||||
|
val scalaXml = "org.scala-lang.modules" %% "scala-xml" % "1.0.1" // Scala License
|
||||||
|
val scalaReflect = ScalaVersionDependentModuleID.versioned("org.scala-lang" % "scala-reflect" % _) // Scala License
|
||||||
|
|
||||||
val slf4jApi = "org.slf4j" % "slf4j-api" % "1.7.12" // MIT
|
val slf4jApi = "org.slf4j" % "slf4j-api" % "1.7.12" // MIT
|
||||||
// mirrored in OSGi sample
|
|
||||||
|
// mirrored in OSGi sample
|
||||||
val uncommonsMath = "org.uncommons.maths" % "uncommons-maths" % "1.2.2a" exclude("jfree", "jcommon") exclude("jfree", "jfreechart") // ApacheV2
|
val uncommonsMath = "org.uncommons.maths" % "uncommons-maths" % "1.2.2a" exclude("jfree", "jcommon") exclude("jfree", "jfreechart") // ApacheV2
|
||||||
val osgiCore = "org.osgi" % "org.osgi.core" % "4.3.1" // ApacheV2
|
val osgiCore = "org.osgi" % "org.osgi.core" % "4.3.1" // ApacheV2
|
||||||
val osgiCompendium= "org.osgi" % "org.osgi.compendium" % "4.3.1" // ApacheV2
|
val osgiCompendium= "org.osgi" % "org.osgi.compendium" % "4.3.1" // ApacheV2
|
||||||
|
|
@ -39,6 +41,21 @@ object Dependencies {
|
||||||
// TODO remove with metrics from akka-cluster
|
// TODO remove with metrics from akka-cluster
|
||||||
val sigar = "org.fusesource" % "sigar" % "1.6.4" // ApacheV2
|
val sigar = "org.fusesource" % "sigar" % "1.6.4" // ApacheV2
|
||||||
|
|
||||||
|
// reactive streams
|
||||||
|
val reactiveStreams = "org.reactivestreams" % "reactive-streams" % "1.0.0" // CC0
|
||||||
|
|
||||||
|
// ssl-config
|
||||||
|
val sslConfigAkka = "com.typesafe" %% "ssl-config-akka" % "0.1.0" // ApacheV2
|
||||||
|
|
||||||
|
// For akka-http spray-json support
|
||||||
|
val sprayJson = "io.spray" %% "spray-json" % "1.3.2" // ApacheV2
|
||||||
|
|
||||||
|
// For akka-http-jackson support
|
||||||
|
val jackson = "com.fasterxml.jackson.core" % "jackson-databind" % "2.4.3" // ApacheV2
|
||||||
|
|
||||||
|
// For akka-http-testkit-java
|
||||||
|
val junit = "junit" % "junit" % "4.11" // Common Public License 1.0
|
||||||
|
|
||||||
object Docs {
|
object Docs {
|
||||||
val sprayJson = "io.spray" %% "spray-json" % "1.3.2" % "test"
|
val sprayJson = "io.spray" %% "spray-json" % "1.3.2" % "test"
|
||||||
val gson = "com.google.code.gson" % "gson" % "2.3.1" % "test"
|
val gson = "com.google.code.gson" % "gson" % "2.3.1" % "test"
|
||||||
|
|
@ -59,8 +76,6 @@ object Dependencies {
|
||||||
val log4j = "log4j" % "log4j" % "1.2.14" % "test" // ApacheV2
|
val log4j = "log4j" % "log4j" % "1.2.14" % "test" // ApacheV2
|
||||||
val junitIntf = "com.novocode" % "junit-interface" % "0.11" % "test" // MIT
|
val junitIntf = "com.novocode" % "junit-interface" % "0.11" % "test" // MIT
|
||||||
val scalaXml = "org.scala-lang.modules" %% "scala-xml" % "1.0.4" % "test"
|
val scalaXml = "org.scala-lang.modules" %% "scala-xml" % "1.0.4" % "test"
|
||||||
// FIXME: change to project dependency once akka-stream merged to master
|
|
||||||
val akkaStreamTestkit = "com.typesafe.akka" %% "akka-stream-testkit-experimental" % "2.0.1" % "test"
|
|
||||||
|
|
||||||
// metrics, measurements, perf testing
|
// metrics, measurements, perf testing
|
||||||
val metrics = "com.codahale.metrics" % "metrics-core" % "3.0.2" % "test" // ApacheV2
|
val metrics = "com.codahale.metrics" % "metrics-core" % "3.0.2" % "test" // ApacheV2
|
||||||
|
|
@ -72,19 +87,25 @@ object Dependencies {
|
||||||
// sigar logging
|
// sigar logging
|
||||||
val slf4jJul = "org.slf4j" % "jul-to-slf4j" % "1.7.12" % "test" // MIT
|
val slf4jJul = "org.slf4j" % "jul-to-slf4j" % "1.7.12" % "test" // MIT
|
||||||
val slf4jLog4j = "org.slf4j" % "log4j-over-slf4j" % "1.7.12" % "test" // MIT
|
val slf4jLog4j = "org.slf4j" % "log4j-over-slf4j" % "1.7.12" % "test" // MIT
|
||||||
|
|
||||||
|
lazy val sprayJson = Compile.sprayJson % "test"
|
||||||
|
|
||||||
|
// reactive streams tck
|
||||||
|
val reactiveStreamsTck = "org.reactivestreams" % "reactive-streams-tck" % "1.0.0" % "test" // CC0
|
||||||
}
|
}
|
||||||
|
|
||||||
object Provided {
|
object Provided {
|
||||||
// TODO remove from "test" config
|
// TODO remove from "test" config
|
||||||
val sigarLoader = "io.kamon" % "sigar-loader" % "1.6.6-rev002" % "optional;provided;test" // ApacheV2
|
val sigarLoader = "io.kamon" % "sigar-loader" % "1.6.6-rev002" % "optional;provided;test" // ApacheV2
|
||||||
|
|
||||||
val levelDB = "org.iq80.leveldb" % "leveldb" % "0.7" % "optional;provided" // ApacheV2
|
val levelDB = "org.iq80.leveldb" % "leveldb" % "0.7" % "optional;provided" // ApacheV2
|
||||||
val levelDBNative = "org.fusesource.leveldbjni" % "leveldbjni-all" % "1.8" % "optional;provided" // New BSD
|
val levelDBNative = "org.fusesource.leveldbjni" % "leveldbjni-all" % "1.8" % "optional;provided" // New BSD
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
import Compile._
|
import Compile._
|
||||||
|
// TODO check if `l ++=` everywhere expensive?
|
||||||
val l = libraryDependencies
|
val l = libraryDependencies
|
||||||
|
|
||||||
val actor = l ++= Seq(config)
|
val actor = l ++= Seq(config)
|
||||||
|
|
@ -98,13 +119,13 @@ object Dependencies {
|
||||||
val remoteTests = l ++= Seq(Test.junit, Test.scalatest.value, Test.scalaXml)
|
val remoteTests = l ++= Seq(Test.junit, Test.scalatest.value, Test.scalaXml)
|
||||||
|
|
||||||
val cluster = l ++= Seq(Test.junit, Test.scalatest.value)
|
val cluster = l ++= Seq(Test.junit, Test.scalatest.value)
|
||||||
|
|
||||||
val clusterTools = l ++= Seq(Test.junit, Test.scalatest.value)
|
val clusterTools = l ++= Seq(Test.junit, Test.scalatest.value)
|
||||||
|
|
||||||
val clusterSharding = l ++= Seq(Provided.levelDB, Provided.levelDBNative, Test.junit, Test.scalatest.value, Test.commonsIo)
|
val clusterSharding = l ++= Seq(Provided.levelDB, Provided.levelDBNative, Test.junit, Test.scalatest.value, Test.commonsIo)
|
||||||
|
|
||||||
val clusterMetrics = l ++= Seq(Provided.sigarLoader, Test.slf4jJul, Test.slf4jLog4j, Test.logback, Test.mockito)
|
val clusterMetrics = l ++= Seq(Provided.sigarLoader, Test.slf4jJul, Test.slf4jLog4j, Test.logback, Test.mockito)
|
||||||
|
|
||||||
val distributedData = l ++= Seq(Test.junit, Test.scalatest.value)
|
val distributedData = l ++= Seq(Test.junit, Test.scalatest.value)
|
||||||
|
|
||||||
val slf4j = l ++= Seq(slf4jApi, Test.logback)
|
val slf4j = l ++= Seq(slf4jApi, Test.logback)
|
||||||
|
|
@ -113,7 +134,7 @@ object Dependencies {
|
||||||
|
|
||||||
val persistence = l ++= Seq(Provided.levelDB, Provided.levelDBNative, Test.scalatest.value, Test.junit, Test.commonsIo, Test.scalaXml)
|
val persistence = l ++= Seq(Provided.levelDB, Provided.levelDBNative, Test.scalatest.value, Test.junit, Test.commonsIo, Test.scalaXml)
|
||||||
|
|
||||||
val persistenceQuery = l ++= Seq(akkaStream, Test.scalatest.value, Test.junit, Test.commonsIo, Test.akkaStreamTestkit)
|
val persistenceQuery = l ++= Seq(Test.scalatest.value, Test.junit, Test.commonsIo)
|
||||||
|
|
||||||
val persistenceTck = l ++= Seq(Test.scalatest.value.copy(configurations = Some("compile")), Test.junit.copy(configurations = Some("compile")))
|
val persistenceTck = l ++= Seq(Test.scalatest.value.copy(configurations = Some("compile")), Test.junit.copy(configurations = Some("compile")))
|
||||||
|
|
||||||
|
|
@ -126,6 +147,69 @@ object Dependencies {
|
||||||
val docs = l ++= Seq(Test.scalatest.value, Test.junit, Test.junitIntf, Docs.sprayJson, Docs.gson)
|
val docs = l ++= Seq(Test.scalatest.value, Test.junit, Test.junitIntf, Docs.sprayJson, Docs.gson)
|
||||||
|
|
||||||
val contrib = l ++= Seq(Test.junitIntf, Test.commonsIo)
|
val contrib = l ++= Seq(Test.junitIntf, Test.commonsIo)
|
||||||
|
|
||||||
val benchJmh = l ++= Seq(Provided.levelDB, Provided.levelDBNative)
|
val benchJmh = l ++= Seq(Provided.levelDB, Provided.levelDBNative)
|
||||||
|
|
||||||
|
// akka stream & http
|
||||||
|
|
||||||
|
lazy val httpCore = l ++= Seq(
|
||||||
|
Test.sprayJson, // for WS Autobahn test metadata
|
||||||
|
Test.junitIntf, Test.junit, Test.scalatest.value)
|
||||||
|
|
||||||
|
lazy val http = l ++= Seq()
|
||||||
|
|
||||||
|
// special, since it also includes a compiler plugin
|
||||||
|
lazy val parsing = Seq(
|
||||||
|
DependencyHelpers.versionDependentDeps(
|
||||||
|
Dependencies.Compile.scalaReflect % "provided"
|
||||||
|
),
|
||||||
|
addCompilerPlugin("org.scalamacros" % "paradise" % "2.0.1" cross CrossVersion.full)
|
||||||
|
)
|
||||||
|
|
||||||
|
lazy val httpTestkit = l ++= Seq(
|
||||||
|
Test.junit, Test.junitIntf, Compile.junit % "provided", Test.scalatest.value.copy(configurations = Some("provided; test")))
|
||||||
|
|
||||||
|
// TODO collapse those
|
||||||
|
lazy val httpTests = l ++= Seq(Test.junit, Test.scalatest.value, Test.junitIntf)
|
||||||
|
lazy val httpTestsJava8 = l ++= Seq(Test.junit, Test.junitIntf)
|
||||||
|
|
||||||
|
lazy val httpXml = versionDependentDeps(scalaXml)
|
||||||
|
|
||||||
|
lazy val httpSprayJson = versionDependentDeps(sprayJson)
|
||||||
|
|
||||||
|
lazy val httpJackson = l ++= Seq(jackson)
|
||||||
|
|
||||||
|
lazy val stream = l ++= Seq[sbt.ModuleID](
|
||||||
|
sslConfigAkka,
|
||||||
|
reactiveStreams,
|
||||||
|
Test.junitIntf,
|
||||||
|
Test.scalatest.value)
|
||||||
|
|
||||||
|
lazy val streamTestkit = l ++= Seq(Test.scalatest.value, Test.scalacheck.value, Test.junit)
|
||||||
|
|
||||||
|
lazy val streamTests = l ++= Seq(Test.scalatest.value, Test.scalacheck.value, Test.junit, Test.junitIntf, Test.commonsIo)
|
||||||
|
|
||||||
|
lazy val streamTestsTck = l ++= Seq(Test.scalatest.value, Test.scalacheck.value, Test.junit, Test.reactiveStreamsTck)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
object DependencyHelpers {
|
||||||
|
case class ScalaVersionDependentModuleID(modules: String => Seq[ModuleID]) {
|
||||||
|
def %(config: String): ScalaVersionDependentModuleID =
|
||||||
|
ScalaVersionDependentModuleID(version => modules(version).map(_ % config))
|
||||||
|
}
|
||||||
|
object ScalaVersionDependentModuleID {
|
||||||
|
implicit def liftConstantModule(mod: ModuleID): ScalaVersionDependentModuleID = versioned(_ => mod)
|
||||||
|
|
||||||
|
def versioned(f: String => ModuleID): ScalaVersionDependentModuleID = ScalaVersionDependentModuleID(v => Seq(f(v)))
|
||||||
|
def fromPF(f: PartialFunction[String, ModuleID]): ScalaVersionDependentModuleID =
|
||||||
|
ScalaVersionDependentModuleID(version => if (f.isDefinedAt(version)) Seq(f(version)) else Nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use this as a dependency setting if the dependencies contain both static and Scala-version
|
||||||
|
* dependent entries.
|
||||||
|
*/
|
||||||
|
def versionDependentDeps(modules: ScalaVersionDependentModuleID*): Def.Setting[Seq[ModuleID]] =
|
||||||
|
libraryDependencies <++= scalaVersion(version => modules.flatMap(m => m.modules(version)))
|
||||||
|
}
|
||||||
|
|
@ -44,6 +44,43 @@ object OSGi {
|
||||||
|
|
||||||
val remote = exports(Seq("akka.remote.*"))
|
val remote = exports(Seq("akka.remote.*"))
|
||||||
|
|
||||||
|
val parsing = exports(Seq("akka.parboiled2.*", "akka.shapeless.*"),
|
||||||
|
imports = Seq(optionalResolution("scala.quasiquotes")))
|
||||||
|
|
||||||
|
val httpCore = exports(Seq("akka.http.*"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.parboiled2.*"),
|
||||||
|
streamAndHttpImport("akka.shapeless.*")))
|
||||||
|
|
||||||
|
val http = exports(Seq("akka.http.impl.server",
|
||||||
|
"akka.http.scaladsl.server.*", "akka.http.javadsl.server.*",
|
||||||
|
"akka.http.scaladsl.client", "akka.http.scaladsl.coding", "akka.http.scaladsl.common",
|
||||||
|
"akka.http.scaladsl.marshalling", "akka.http.scaladsl.unmarshalling"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.http.*"),
|
||||||
|
streamAndHttpImport("akka.parboiled2.*")))
|
||||||
|
|
||||||
|
val httpTestkit = exports(Seq("akka.http.scaladsl.testkit.*", "akka.http.javadsl.testkit.*"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.http.*")))
|
||||||
|
|
||||||
|
val httpSprayJson = exports(Seq("akka.http.scaladsl.marshallers.sprayjson"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.http.*")))
|
||||||
|
|
||||||
|
val httpXml = exports(Seq("akka.http.scaladsl.marshallers.xml"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.http.*")))
|
||||||
|
|
||||||
|
val httpJackson = exports(Seq("akka.http.javadsl.marshallers.jackson"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*"),
|
||||||
|
streamAndHttpImport("akka.http.*")))
|
||||||
|
|
||||||
|
val stream = exports(Seq("akka.stream.*"))
|
||||||
|
|
||||||
|
val streamTestkit = exports(Seq("akka.stream.testkit.*"),
|
||||||
|
imports = Seq(streamAndHttpImport("akka.stream.*")))
|
||||||
|
|
||||||
val slf4j = exports(Seq("akka.event.slf4j.*"))
|
val slf4j = exports(Seq("akka.event.slf4j.*"))
|
||||||
|
|
||||||
val persistence = exports(Seq("akka.persistence.*"),
|
val persistence = exports(Seq("akka.persistence.*"),
|
||||||
|
|
@ -65,6 +102,7 @@ object OSGi {
|
||||||
)
|
)
|
||||||
def defaultImports(scalaVersion: String) = Seq("!sun.misc", akkaImport(), configImport(), scalaImport(scalaVersion), "*")
|
def defaultImports(scalaVersion: String) = Seq("!sun.misc", akkaImport(), configImport(), scalaImport(scalaVersion), "*")
|
||||||
def akkaImport(packageName: String = "akka.*") = versionedImport(packageName, "2.4", "2.5")
|
def akkaImport(packageName: String = "akka.*") = versionedImport(packageName, "2.4", "2.5")
|
||||||
|
def streamAndHttpImport(packageName: String) = versionedImport(packageName, "2.0", "2.4") // TODO not sure about the range
|
||||||
def configImport(packageName: String = "com.typesafe.config.*") = versionedImport(packageName, "1.3.0", "1.4.0")
|
def configImport(packageName: String = "com.typesafe.config.*") = versionedImport(packageName, "1.3.0", "1.4.0")
|
||||||
def scalaImport(version: String) = {
|
def scalaImport(version: String) = {
|
||||||
val packageName = "scala.*"
|
val packageName = "scala.*"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue