This repository has been archived by the owner on Nov 15, 2023. It is now read-only.
forked from akka/alpakka-kafka
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
127 lines (109 loc) · 5.16 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
language: scala
sudo: false
services:
- docker
before_install:
# fetch full history for correct current and previous version detection
- git fetch --unshallow
# using jabba for custom jdk management
- if [ ! -f ~/.jabba/jabba.sh ]; then curl -sL https://raw.githubusercontent.com/shyiko/jabba/0.11.2/install.sh | bash ; fi
- . ~/.jabba/jabba.sh
- jabba install adopt@~1.8.0-222
- jabba install adopt@~1.11.0-4
script:
- jabba use ${JDK:=adopt@~1.8.0-222}
- java -version
- sbt -jvm-opts .jvmopts-travis "$CMD"
jobs:
include:
- stage: check
env: CMD="verifyCodeStyle"
name: "Code style check. Run locally with: sbt verifyCodeStyle"
- env: CMD=";++2.11.12 Test/compile ;++2.11.12 It/compile"
name: "Compile all code with fatal warnings for Scala 2.11. Run locally with: env CI=true sbt ';++2.11.12 Test/compile ;++2.11.12 It/compile'"
if: type != cron
- env: CMD=";++2.13.1 Test/compile ;++2.13.1 It/compile"
name: "Compile all code with fatal warnings for Scala 2.13. Run locally with: env CI=true sbt ';++2.13.1 Test/compile ;++2.13.1 It/compile'"
- env: CMD="+clusterSharding/Test/compile
name: "Compile cluster-sharding module for all supported Scala versions. Run locally with: env CI=true sbt '+clusterSharding/Test/compile'"
- env: CMD="verifyDocs"
name: "Create all API docs for artifacts/website and all reference docs. Run locally with: sbt verifyDocs"
- env: CMD="mimaReportBinaryIssues"
name: "Check binary compatibility. Run locally with: sbt mimaReportBinaryIssues"
- stage: test
env: CMD="++2.11.12 test"
name: "Run tests with Scala 2.11 and AdoptOpenJDK 8"
if: type != cron
- env: CMD="++2.12.10 test"
name: "Run tests with Scala 2.12 and AdoptOpenJDK 8"
- env: CMD="++2.13.1 test"
name: "Run tests with Scala 2.13 and AdoptOpenJDK 8"
- env:
- JDK="adopt@~1.11.0-4"
- _JAVA_OPTIONS="-XX:+UnlockExperimentalVMOptions -XX:+UseJVMCICompiler"
- CMD="++2.11.12 test"
name: "Run tests with Scala 2.11 and AdoptOpenJDK 11"
if: type != cron
- env:
- JDK="adopt@~1.11.0-4"
- _JAVA_OPTIONS="-XX:+UnlockExperimentalVMOptions -XX:+UseJVMCICompiler"
- CMD="++2.12.10 test"
name: "Run tests with Scala 2.12 and AdoptOpenJDK 11"
- env:
- JDK="adopt@~1.11.0-4"
- _JAVA_OPTIONS="-XX:+UnlockExperimentalVMOptions -XX:+UseJVMCICompiler"
- CMD="++2.13.1 test"
name: "Run tests with Scala 2.13 and AdoptOpenJDK 11"
- stage: integration
env: CMD="tests/it:test"
name: "Run multi-broker and long running integration tests"
- env: CMD="benchmarks/it:compile"
name: "Compile benchmark tests"
- stage: whitesource
env: CMD=";whitesourceCheckPolicies ;whitesourceUpdate"
- env: CMD=";clusterSharding/whitesourceCheckPolicies ;clusterSharding/whitesourceUpdate"
- stage: publish
env: CMD="+publish"
name: "Publish artifacts for all Scala versions"
- env: CMD="+clusterSharding/publish"
name: "Publish akka-stream-kafka-cluster-sharding for all its supported Scala versions"
- script: openssl aes-256-cbc -K $encrypted_d80875c2ae41_key -iv $encrypted_d80875c2ae41_iv -in .travis/travis_alpakka_kafka_rsa.enc -out .travis/id_rsa -d && eval "$(ssh-agent -s)" && chmod 600 .travis/id_rsa && ssh-add .travis/id_rsa && sbt -jvm-opts .jvmopts-travis '++2.13.1 docs/publishRsync'
name: "Publish API and reference documentation"
stages:
# runs on master commits and PRs
- name: check
if: NOT tag =~ ^v
# runs on master commits and PRs
- name: test
if: NOT tag =~ ^v
# runs on master commits and PRs
- name: integration
if: NOT tag =~ ^v
# runs on main repo master commits and version-tagged commits
- name: whitesource
if: repo = akka/alpakka-kafka AND ( ( branch = master AND type = push ) OR tag =~ ^v )
# runs on main repo master commits and version-tagged commits
- name: publish
if: repo = akka/alpakka-kafka AND ( ( branch = master AND type = push ) OR tag =~ ^v )
after_failure:
- docker-compose logs
- find . -name "*.log" -exec ./scripts/cat-log.sh {} \;
before_cache:
- find $HOME/.ivy2/ -name "ivydata-*.properties" -print -delete
- find $HOME/.sbt -name "*.lock" -print -delete
cache:
directories:
- $HOME/.cache/coursier
- $HOME/.ivy2/cache
- $HOME/.sbt
- $HOME/.jabba
env:
global:
# encrypt with: travis encrypt WHITESOURCE_PASSWORD=...
- secure: "ed6tomZjtrq85XLGvpoA1KUcZ55OoWiPdwN0ujqRTTGilOG2p9jAZCARYNSXWdSAtga0gKoW1nCy7SMzl3lcdP5Hlj7MK96R5h7QTHeTh5k8R/aG5fFilWnrvY2rsh0EvuINUkjvyl/jRxDDQpN8mm0NZwHRdsK0sMly4G6XNdY="
# encrypt with: travis encrypt BINTRAY_USER=...
- secure: "NLb9af0D3zS8UIHYqK86sLapFIN/iBpgXwjhc3t8e7bbVRVS1VKMNoqpzn75sd7rgYsComWboFUAo1oDMnGuOTf2onVOLDPWmp4QK568DVQTlEJ9rSI02RijjoPx4ViksI7wbh7Lz9VtupQVnBYU34Ozn7tuK12NGEHxQd9fCNE="
# encrypt with: travis encrypt BINTRAY_PASS=...
- secure: "DAhVvZ5hBy1MAznBCrQu6Rw6Pa7pCmqkpsYQFxG+y8Hsvi37WNMfyCOYcR6VnunMYWHDaFJ8LaqgWx8O4Usrl6JxZYt2J/jT7axKLqpsZg7xWaB2++tFWI2lZJewvb6EnPIZuEdr5oVKnazD5f55mxSqprOAHebim5IOXVaRGS0="
# override default akka.test.timefactor
- AKKA_TEST_TIMEFACTOR=10.0