Skip to content

Commit ae8984b

Browse files
committed
Apply minor patches to ease onboarding to Pekko
1 parent 14ac09d commit ae8984b

File tree

72 files changed

+218
-124
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+218
-124
lines changed

.github/dependabot.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: "daily"

.github/workflows/standard-workflow.yml

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ name: Standard Workflow
22

33
on: workflow_call
44

5+
concurrency:
6+
group: ${{ github.head_ref }}
7+
cancel-in-progress: true
8+
59
jobs:
610
code-style-check:
711
runs-on: ubuntu-latest
@@ -10,29 +14,29 @@ jobs:
1014
- name: Check out
1115
uses: actions/checkout@v2
1216

13-
- name: Setup Scala
14-
uses: olafurpg/setup-scala@v10
15-
with:
16-
java-version: adopt@1.11
17-
18-
- name: Resolve dependencies
19-
run: sbt update
20-
21-
- name: Run code checks
17+
- name: Run simple checks
2218
run: |
2319
PATH=$PATH:./scripts
2420
set -x
21+
enforce-issue-number-for-todos
2522
enforce-newline-at-eof
2623
prohibit-trailing-whitespace
27-
enforce-issue-number-for-todos
2824
2925
npm install --global remark-cli remark-lint-no-dead-urls remark-validate-links
3026
validate-markdown-links
3127
28+
- name: Setup Scala
29+
uses: olafurpg/setup-scala@v10
30+
with:
31+
java-version: adopt@1.11
32+
3233
- name: Check code style
3334
# Curiously, scalafmtCheckAll doesn't cover *.sbt files, hence scalafmtSbtCheck is needed as well
3435
run: sbt scalafmtCheckAll scalafmtSbtCheck "scalafixAll --check"
3536

37+
- name: Substitute sbt plugin snapshot version
38+
run: ./scripts/substitute-sbt-plugin-snapshot-version
39+
3640
- name: Check code style - examples/event-migration
3741
run: sbt scalafmtCheckAll scalafmtSbtCheck "scalafixAll --check"
3842
working-directory: examples/event-migration
@@ -57,9 +61,6 @@ jobs:
5761
with:
5862
java-version: adopt@1.11
5963

60-
- name: Resolve dependencies
61-
run: sbt update
62-
6364
- name: Compile
6465
run: sbt compile Test/compile
6566

@@ -84,9 +85,6 @@ jobs:
8485
with:
8586
java-version: adopt@1.11
8687

87-
- name: Resolve dependencies
88-
run: sbt update
89-
9088
- name: Compile
9189
run: sbt compile Test/compile
9290

@@ -110,9 +108,6 @@ jobs:
110108
with:
111109
java-version: adopt@1.11
112110

113-
- name: Resolve dependencies
114-
run: sbt update
115-
116111
- name: Compile
117112
run: sbt compile Test/compile
118113

@@ -151,6 +146,9 @@ jobs:
151146
with:
152147
java-version: adopt@1.11
153148

149+
- name: Substitute sbt plugin snapshot version
150+
run: ./scripts/substitute-sbt-plugin-snapshot-version
151+
154152
- name: Test event-migration-examples
155153
run: sbt test
156154
working-directory: examples/event-migration

.remarkrc.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
plugins:
2+
lint-no-dead-urls:
3+
skipUrlPatterns:
4+
# TODO (#325): remove these patterns
5+
- https://mvnrepository.com/artifact/org.virtuslab.ash # failing for some reason
6+
- https://mvnrepository.com/artifact/org.virtuslab.psh
7+
- https://oss.sonatype.org/content/repositories/snapshots/org/virtuslab/psh/
8+
- https://repo1.maven.org/maven2/org/virtuslab/psh/
9+
validate-links: {}

.scala-steward.conf

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,29 +4,31 @@ commits.message = "Scala-Steward: Update ${artifactName} from ${currentVersion}
44

55
buildRoots = [
66
".",
7+
"examples/akka-cluster-app/",
78
"examples/akka-persistence-app/",
89
"examples/event-migration/",
9-
"examples/example-app/",
1010
"sbt-akka-serialization-helper/src/sbt-test/sbt-dumpschema/dependencies",
1111
"sbt-akka-serialization-helper/src/sbt-test/sbt-dumpschema/simple",
1212
]
1313

14-
updates.pin = [
14+
updates.pin = [
1515
# * org.scala-lang.modules:scala-xml_2.12:2.1.0 (early-semver) is selected over 1.2.0
1616
# +- com.github.sbt:sbt-native-packager:1.9.10 (sbtVersion=1.0, scalaVersion=2.12) (depends on 2.1.0)
1717
# +- com.typesafe.play:twirl-api_2.12:1.5.1 (depends on 1.2.0)
18-
{ groupId = "com.github.sbt", artifactId = "sbt-native-packager", version = "1.9.9" },
18+
{ groupId = "com.github.sbt", artifactId = "sbt-native-packager", version = "1.9.9" }
1919

2020
# * org.scala-lang.modules:scala-parser-combinators_2.13:2.1.0 (early-semver) is selected over 1.1.2
2121
# +- org.scalikejdbc:scalikejdbc-core_2.13:4.0.0 (depends on 2.1.0)
2222
# +- com.typesafe:ssl-config-core_2.13:0.4.3 (depends on 1.1.2)
23-
{ groupId = "org.scalikejdbc", version = "3." },
23+
{ groupId = "org.scalikejdbc", version = "3." }
2424

2525
# Since most libraries will pull in slf4j-api v1 for a long time...
2626
# so to spare ourselves dependency overrides & all the hassle with v2, let's stick to v1 as for now.
2727
{ groupId = "org.slf4j", version = "1." }
2828

29-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
29+
# <START-AKKA>
30+
31+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
3032
# 2.7.0 release. So, we want to stick to 2.6.x for now to avoid potential license-connected problems.
3133
{ groupId = "com.typesafe.akka", artifactId="akka-actor", version = "2.6." }
3234
{ groupId = "com.typesafe.akka", artifactId="akka-actor-typed", version = "2.6." }
@@ -41,28 +43,30 @@ updates.pin = [
4143
{ groupId = "com.typesafe.akka", artifactId="akka-serialization-jackson", version = "2.6." }
4244
{ groupId = "com.typesafe.akka", artifactId="akka-persistence-testkit", version = "2.6." }
4345
{ groupId = "com.typesafe.akka", artifactId="akka-persistence-query", version = "2.6." }
44-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
46+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
4547
# 1.3.0 release for akka-projection. So, we want to stick to 1.2.x for now to avoid
4648
# potential license-connected problems.
4749
{ groupId = "com.lightbend.akka", artifactId="akka-projection-eventsourced", version = "1.2." }
4850
{ groupId = "com.lightbend.akka", artifactId="akka-projection-jdbc", version = "1.2." }
49-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
51+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
5052
# 2.2.0 release for akka-grpc. So, we want to stick to 2.1.x for now to avoid potential license-connected problems.
5153
{ groupId = "com.lightbend.akka.grpc", artifactId="akka-grpc-runtime", version = "2.1." }
52-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
54+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
5355
# 10.3.0 release for akka-http. So, we want to stick to 10.2.x for now to avoid potential license-connected problems.
5456
{ groupId = "com.typesafe.akka", artifactId="akka-http", version = "10.2." }
5557
{ groupId = "com.typesafe.akka", artifactId="akka-http-spray-json", version = "10.2." }
5658
{ groupId = "com.typesafe.akka", artifactId="akka-http2-support", version = "10.2." }
57-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
59+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
5860
# 1.2.0 release for akka-management - related modules. So, we want to stick to 1.1.x for now to avoid
5961
# potential license-connected problems.
6062
{ groupId = "com.lightbend.akka.management", artifactId="akka-management", version = "1.1." }
6163
{ groupId = "com.lightbend.akka.management", artifactId="akka-management-cluster-http", version = "1.1." }
6264
{ groupId = "com.lightbend.akka.management", artifactId="akka-management-cluster-bootstrap", version = "1.1." }
6365
{ groupId = "com.lightbend.akka.discovery", artifactId="akka-discovery-kubernetes-api", version = "1.1." }
64-
# Akka will change its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
66+
# Akka changed its license from Apache 2.0 (opensource) to Business Source License 1.1 (commercial) in the
6567
# 5.2.0 release for akka-persistence-jdbc. So, we want to stick to 5.1.x for now to avoid
6668
# potential license-connected problems.
6769
{ groupId = "com.lightbend.akka", artifactId="akka-persistence-jdbc", version = "5.1." }
70+
71+
# <END-AKKA>
6872
]

CONTRIBUTING.md

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -73,18 +73,10 @@ You might as well use any other profiler, but using https://github.com/jvm-profi
7373

7474
### Code quality
7575

76-
Before committing, don't forget to type
77-
```shell
78-
sbt scalafmtAll scalafixAll scalafmtSbt
79-
```
80-
to format the code, .sbt files and check imports. Run this command in the following directories:
81-
- the base directory (`.`)
82-
- `examples/akka-cluster-app`
83-
- `examples/akka-persistence-app`
84-
- `examples/event-migration`
85-
You can use `pre-commit` hook, provided in `./pre-commit`, to do the formatting and checking automatically.
76+
Don't forget to run `./scripts/format-code` before opening a pull request.
77+
You can symlink this file as git `pre-commit` hook, but beware that it runs quite long.
8678

87-
Additionally, all warnings locally are escalated to errors in CI, so make sure there are none.
79+
All local Scala compilation warnings are escalated to errors in CI, so make sure there are none.
8880

8981
### Compatible JDK versions
9082

@@ -118,7 +110,7 @@ The tagged commit is then released to Maven Central.
118110

119111
Note that we are using an [early semantic versioning scheme](https://www.scala-lang.org/blog/2021/02/16/preventing-version-conflicts-with-versionscheme.html#early-semver-and-sbt-version-policy).
120112

121-
### Github Releases
113+
### GitHub Releases
122114

123-
Github Releases are done automatically - with settings defined in the [publish-release-config](.github/publish-release-config.yml) file.
115+
GitHub Releases are done automatically - with settings defined in the [publish-release-config](.github/publish-release-config.yml) file.
124116
Release is published when a new `vX.Y.Z` git tag is pushed.

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2021-2022 VirtusLab
3+
Copyright (c) 2021-2023 VirtusLab
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

0 commit comments

Comments
 (0)