You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pekko.apache.org by fa...@apache.org on 2023/01/18 09:02:49 UTC
[incubator-pekko-projection] branch main updated: pekko name and license/notice in jars (#4)
This is an automated email from the ASF dual-hosted git repository.
fanningpj pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-pekko-projection.git
The following commit(s) were added to refs/heads/main by this push:
new 8b9192e pekko name and license/notice in jars (#4)
8b9192e is described below
commit 8b9192e04e12d4299458f9fc20a534928a4c449c
Author: PJ Fanning <pj...@users.noreply.github.com>
AuthorDate: Wed Jan 18 10:02:44 2023 +0100
pekko name and license/notice in jars (#4)
---
NOTICE | 11 +++++++++++
README.md | 7 ++++---
build.sbt | 14 ++++++++++++--
project/MetaInfLicenseNoticeCopy.scala | 30 ++++++++++++++++++++++++++++++
4 files changed, 57 insertions(+), 5 deletions(-)
diff --git a/NOTICE b/NOTICE
new file mode 100644
index 0000000..d535e88
--- /dev/null
+++ b/NOTICE
@@ -0,0 +1,11 @@
+Apache Pekko Projections
+Copyright 2022, 2023 The Apache Software Foundation
+
+This product includes software developed at
+The Apache Software Foundation (https://www.apache.org/).
+
+This product contains significant parts that were originally based on software from Lightbend (Akka <https://akka.io/>).
+Copyright (C) 2020-2022 Lightbend Inc. <https://www.lightbend.com>
+
+Apache Pekko Projections is derived from Akka Projections 1.2.x, the last version that was distributed under the
+Apache License, Version 2.0 License.
diff --git a/README.md b/README.md
index c9538aa..8dd72ed 100644
--- a/README.md
+++ b/README.md
@@ -1,5 +1,6 @@
-# Akka Projections
+# Apache Pekko Projections
-Akka Projections provides an abstraction for consuming a stream of `Envelope` (where `Envelope` contains a payload and a trackable offset). This streams can originate from persisted events, Kafka topics, or other Alpakka connectors.
+Apache Pekko Projections provides an abstraction for consuming a stream of `Envelope` (where `Envelope` contains a payload and a trackable offset). This streams can originate from persisted events, Kafka topics,
+or other Apache Pekko connectors.
-Akka Projections also provides tools to track, restart and distribute these projections.
+Apache Pekko Projections also provides tools to track, restart and distribute these projections.
diff --git a/build.sbt b/build.sbt
index 70cf84d..3160ddd 100644
--- a/build.sbt
+++ b/build.sbt
@@ -6,6 +6,7 @@ lazy val core =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.core)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.settings(
name := "akka-projection-core",
Compile / packageBin / packageOptions += Package.ManifestAttributes(
@@ -19,6 +20,7 @@ lazy val coreTest =
.disablePlugins(MimaPlugin)
.settings(Defaults.itSettings)
.settings(Dependencies.coreTest)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.settings(publish / skip := true)
.dependsOn(core)
.dependsOn(testkit % Test)
@@ -29,6 +31,7 @@ lazy val testkit =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.testKit)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
// provides offset storage backed by a JDBC table
@@ -38,6 +41,7 @@ lazy val jdbc =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.jdbc)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
.dependsOn(coreTest % "test->test")
.dependsOn(testkit % Test)
@@ -49,6 +53,7 @@ lazy val slick =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.slick)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(jdbc)
.dependsOn(core)
.dependsOn(coreTest % "test->test")
@@ -61,6 +66,7 @@ lazy val cassandra =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.cassandra)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
// strictly speaking it is not needed to have test->test here.
// Cassandra module doesn't have tests, only integration tests
@@ -72,6 +78,7 @@ lazy val cassandra =
lazy val eventsourced =
Project(id = "akka-projection-eventsourced", base = file("akka-projection-eventsourced"))
.settings(Dependencies.eventsourced)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
.dependsOn(testkit % Test)
@@ -82,6 +89,7 @@ lazy val kafka =
.settings(headerSettings(IntegrationTest))
.settings(Defaults.itSettings)
.settings(Dependencies.kafka)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
.dependsOn(testkit % Test)
.dependsOn(slick % "test->test;it->it")
@@ -91,6 +99,7 @@ lazy val `durable-state` =
Project(id = "akka-projection-durable-state", base = file("akka-projection-durable-state"))
.configs(IntegrationTest)
.settings(Dependencies.state)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(core)
.dependsOn(testkit % Test)
.settings(
@@ -103,6 +112,7 @@ lazy val examples = project
.disablePlugins(MimaPlugin)
.settings(Defaults.itSettings)
.settings(Dependencies.examples)
+ .settings(MetaInfLicenseNoticeCopy.settings)
.dependsOn(slick % "test->test")
.dependsOn(jdbc % "test->test")
.dependsOn(cassandra % "test->test;test->it")
@@ -117,7 +127,7 @@ lazy val docs = project
.disablePlugins(MimaPlugin)
.dependsOn(core, testkit)
.settings(
- name := "Akka Projections",
+ name := "Apache Pekko Projections",
publish / skip := true,
makeSite := makeSite.dependsOn(LocalRootProject / ScalaUnidoc / doc).value,
previewPath := (Paradox / siteSubdirName).value,
@@ -127,7 +137,7 @@ lazy val docs = project
Compile / paradoxProperties ++= Map(
"project.url" -> "https://doc.akka.io/docs/akka-projection/current/",
"canonical.base_url" -> "https://doc.akka.io/docs/akka-projection/current",
- "github.base_url" -> "https://github.com/akka/akka-projection",
+ "github.base_url" -> "https://github.com/apache/incubator-pekko-projection",
"akka.version" -> Dependencies.Versions.akka,
// Akka
"extref.akka.base_url" -> s"https://doc.akka.io/docs/akka/${Dependencies.AkkaVersionInDocs}/%s",
diff --git a/project/MetaInfLicenseNoticeCopy.scala b/project/MetaInfLicenseNoticeCopy.scala
new file mode 100644
index 0000000..1965dc5
--- /dev/null
+++ b/project/MetaInfLicenseNoticeCopy.scala
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * license agreements; and to You under the Apache License, version 2.0:
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * This file is part of the Apache Pekko project, which was derived from Akka.
+ */
+
+import sbt.Keys._
+import sbt._
+
+/**
+ * Copies LICENSE and NOTICE files into jar META-INF dir
+ */
+object MetaInfLicenseNoticeCopy {
+
+ val settings: Seq[Setting[_]] = inConfig(Compile)(
+ Seq(
+ resourceGenerators += copyFileToMetaInf(resourceManaged, "LICENSE"),
+ resourceGenerators += copyFileToMetaInf(resourceManaged, "NOTICE")))
+
+ def copyFileToMetaInf(dir: SettingKey[File], fileName: String) = Def.task[Seq[File]] {
+ val fromFile = (LocalRootProject / baseDirectory).value / fileName
+ val toFile = resourceManaged.value / "META-INF" / fileName
+ IO.copyFile(fromFile, toFile)
+ Seq(toFile)
+ }
+
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pekko.apache.org
For additional commands, e-mail: commits-help@pekko.apache.org