Build Logs

akka/alpakka • scheduled_3.8.1-RC1-bin-20260102-32e416e-NIGHTLY

Errors

28

Warnings

657

Total Lines

1088

1##################################
2Clonning https://github.com/akka/alpakka.git into /build/repo using revision v6.0.2
3##################################
4Note: switching to '00c6b6099c9557c5a67125ffd012557f93ccc329'.
5
6You are in 'detached HEAD' state. You can look around, make experimental
7changes and commit them, and you can discard any commits you make in this
8state without impacting any branches by switching back to a branch.
9
10If you want to create a new branch to retain commits you create, you may
11do so (now or later) by using -c with the switch command. Example:
12
13 git switch -c <new-branch-name>
14
15Or undo this operation with:
16
17 git switch -
18
19Turn off this advice by setting config variable advice.detachedHead to false
20
21Would override fixed Scala version: 3.2.2
22----
23Preparing build for 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY
24Scala binary version found: 3.8
25Implicitly using source version 3.8
26Scala binary version found: 3.8
27Implicitly using source version 3.8
28Would try to apply common scalacOption (best-effort, sbt/mill only):
29Append: ,REQUIRE:-source:3.8
30Remove: ,-deprecation,-feature,-Xfatal-warnings,-Werror,MATCH:.*-Wconf.*any:e
31
32Try apply source patch:
33Path: project/Dependencies.scala
34Pattern: libraryDependencies :=
35Replacement: libraryDependencies ++=
36Starting compilation server
37Compiling project (Scala 3.7.3, JVM (17))
38Compiled project (Scala 3.7.3, JVM (17))
39Successfully applied pattern 'libraryDependencies := ' in project/Dependencies.scala
40
41Try apply source patch:
42Path: project/Dependencies.scala
43Pattern: val Scala3 = "3.2.2"
44Replacement: val Scala3 = "3.8.1-RC1-bin-20260102-32e416e-NIGHTLY"
45Successfully applied pattern 'val Scala3 = "3.2.2"' in project/Dependencies.scala
46----
47Starting build for 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY
48Execute tests: false
49sbt project found:
50Sbt version 1.9.1 is not supported, minimal supported version is 1.11.5
51Enforcing usage of sbt in version 1.11.5
52No prepare script found for project akka/alpakka
53##################################
54Scala version: 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY
55Targets: com.lightbend.akka%akka-stream-alpakka-amqp com.lightbend.akka%akka-stream-alpakka-avroparquet com.lightbend.akka%akka-stream-alpakka-cassandra com.lightbend.akka%akka-stream-alpakka-csv com.lightbend.akka%akka-stream-alpakka-s3
56Project projectConfig: {"projects":{"exclude":[],"overrides":{}},"java":{"version":"17"},"sbt":{"commands":[],"options":[]},"mill":{"options":[]},"tests":"compile-only","migrationVersions":[],"sourcePatches":[{"path":"project/Dependencies.scala","pattern":"libraryDependencies := ","replaceWith":"libraryDependencies ++= "},{"path":"project/Dependencies.scala","pattern":"val Scala3 = \"3.2.2\"","replaceWith":"val Scala3 = \"<SCALA_VERSION>\""}]}
57##################################
58Using extra scalacOptions: ,REQUIRE:-source:3.8
59Filtering out scalacOptions: ,-deprecation,-feature,-Xfatal-warnings,-Werror,MATCH:.*-Wconf.*any:e
60[sbt_options] declare -a sbt_options=()
61[process_args] java_version = '17'
62[copyRt] java9_rt = '/root/.sbt/1.0/java9-rt-ext-eclipse_adoptium_17_0_8/rt.jar'
63# Executing command line:
64java
65-Dfile.encoding=UTF8
66-Xms1g
67-Xss6M
68-Dcommunitybuild.scala=3.8.1-RC1-bin-20260102-32e416e-NIGHTLY
69-Dcommunitybuild.project.dependencies.add=
70-Xmx7G
71-Xms4G
72-Xss8M
73-Dsbt.script=/root/.sdkman/candidates/sbt/current/bin/sbt
74-Dscala.ext.dirs=/root/.sbt/1.0/java9-rt-ext-eclipse_adoptium_17_0_8
75-jar
76/root/.sdkman/candidates/sbt/1.11.5/bin/sbt-launch.jar
77"setCrossScalaVersions 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY"
78"++3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -v"
79"mapScalacOptions ",REQUIRE:-source:3.8,-Wconf:msg=can be rewritten automatically under:s" ",-deprecation,-feature,-Xfatal-warnings,-Werror,MATCH:.*-Wconf.*any:e""
80"set every credentials := Nil"
81"excludeLibraryDependency com.github.ghik:zerowaste_{scalaVersion} com.olegpy:better-monadic-for_3 org.polyvariant:better-tostring_{scalaVersion} org.wartremover:wartremover_{scalaVersion}"
82"removeScalacOptionsStartingWith -P:wartremover"
83
84moduleMappings
85"runBuild 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY """{"projects":{"exclude":[],"overrides":{}},"java":{"version":"17"},"sbt":{"commands":[],"options":[]},"mill":{"options":[]},"tests":"compile-only","migrationVersions":[],"sourcePatches":[{"path":"project/Dependencies.scala","pattern":"libraryDependencies := ","replaceWith":"libraryDependencies ++= "},{"path":"project/Dependencies.scala","pattern":"val Scala3 = \"3.2.2\"","replaceWith":"val Scala3 = \"<SCALA_VERSION>\""}]}""" com.lightbend.akka%akka-stream-alpakka-amqp com.lightbend.akka%akka-stream-alpakka-avroparquet com.lightbend.akka%akka-stream-alpakka-cassandra com.lightbend.akka%akka-stream-alpakka-csv com.lightbend.akka%akka-stream-alpakka-s3"
86
87[info] welcome to sbt 1.11.5 (Eclipse Adoptium Java 17.0.8)
88[info] loading settings for project repo-build from akka.sbt, plugins.sbt...
89[info] loading project definition from /build/repo/project
90[info] compiling 7 Scala sources to /build/repo/project/target/scala-2.12/sbt-1.0/classes ...
91[info] Non-compiled module 'compiler-bridge_2.12' for Scala 2.12.20. Compiling...
92[info] Compilation completed in 9.095s.
93[info] done compiling
94[info] loading settings for project alpakka from build.sbt...
95[info] resolving key references (68092 settings) ...
96[info]
97[info] ** Welcome to the sbt build definition for Alpakka! **
98[info]
99[info] Useful sbt tasks:
100[info]
101[info] docs/previewSite - builds Paradox and Scaladoc documentation,
102[info] starts a webserver and opens a new browser window
103[info]
104[info] test - runs all the tests for all of the connectors.
105[info] Make sure to run `docker-compose up` first.
106[info]
107[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
108[info]
109[info] mimaReportBinaryIssues - checks whether this current API
110[info] is binary compatible with the released version
111[info]
112[warn] there's a key that's not used by any other settings/tasks:
113[warn]
114[warn] * avroparquet-tests / mimaPreviousArtifacts
115[warn] +- /build/repo/build.sbt:480
116[warn]
117[warn] note: a setting might still be used by a command; to exclude a key from this `lintUnused` check
118[warn] either append it to `Global / excludeLintKeys` or call .withRank(KeyRanks.Invisible) on the key
119Execute setCrossScalaVersions: 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY
120OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in cassandra/crossScalaVersions
121OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in avroparquet/crossScalaVersions
122OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in amqp/crossScalaVersions
123OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in s3/crossScalaVersions
124OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in csv/crossScalaVersions
125OpenCB::Limitting incorrect crossVersions List() -> List(2.13.10) in alpakka/crossScalaVersions
126OpenCB::Changing crossVersion 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY -> 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY in testkit/crossScalaVersions
127[info]
128[info] ** Welcome to the sbt build definition for Alpakka! **
129[info]
130[info] Useful sbt tasks:
131[info]
132[info] docs/previewSite - builds Paradox and Scaladoc documentation,
133[info] starts a webserver and opens a new browser window
134[info]
135[info] test - runs all the tests for all of the connectors.
136[info] Make sure to run `docker-compose up` first.
137[info]
138[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
139[info]
140[info] mimaReportBinaryIssues - checks whether this current API
141[info] is binary compatible with the released version
142[info]
143[info] Setting Scala version to 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY on 6 projects.
144[info] Switching Scala version on:
145[info] s3 (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
146[info] amqp (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
147[info] csv (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
148[info] cassandra (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
149[info] avroparquet (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
150[info] testkit (2.13.10, 2.12.17, 3.8.1-RC1-bin-20260102-32e416e-NIGHTLY)
151[info] Excluding projects:
152[info] ftp (2.13.10, 2.12.17)
153[info] reference (2.13.10, 2.12.17)
154[info] spring-web (2.13.10, 2.12.17)
155[info] sns (2.13.10, 2.12.17)
156[info] google-cloud-pub-sub (2.13.10, 2.12.17)
157[info] jms (2.13.10, 2.12.17)
158[info] unix-domain-socket (2.13.10, 2.12.17)
159[info] slick (2.13.10, 2.12.17)
160[info] geode (2.13.10, 2.12.17)
161[info] azure-storage-queue (2.13.10, 2.12.17)
162[info] dynamodb (2.13.10, 2.12.17)
163[info] google-cloud-bigquery-storage (2.13.10, 2.12.17)
164[info] elasticsearch (2.13.10, 2.12.17)
165[info] docs (2.13.10, 2.12.17)
166[info] google-cloud-pub-sub-grpc (2.13.10, 2.12.17)
167[info] text (2.13.10, 2.12.17)
168[info] mqtt (2.13.10, 2.12.17)
169[info] google-cloud-bigquery (2.13.10, 2.12.17)
170[info] huawei-push-kit (2.13.10, 2.12.17)
171[info] mqtt-streaming (2.13.10, 2.12.17)
172[info] influxdb (2.13.10, 2.12.17)
173[info] csv-bench (2.13.10, 2.12.17)
174[info] aws-event-bridge (2.13.10, 2.12.17)
175[info] xml (2.13.10, 2.12.17)
176[info] sqs (2.13.10, 2.12.17)
177[info] json-streaming (2.13.10, 2.12.17)
178[info] google-fcm (2.13.10, 2.12.17)
179[info] doc-examples (2.13.10, 2.12.17)
180[info] pravega (2.13.10, 2.12.17)
181[info] udp (2.13.10, 2.12.17)
182[info] * alpakka (2.13.10)
183[info] mqtt-streaming-bench (2.13.10, 2.12.17)
184[info] simple-codecs (2.13.10, 2.12.17)
185[info] file (2.13.10, 2.12.17)
186[info] google-common (2.13.10, 2.12.17)
187[info] kinesis (2.13.10, 2.12.17)
188[info] mongodb (2.13.10, 2.12.17)
189[info] ironmq (2.13.10, 2.12.17)
190[info] sse (2.13.10, 2.12.17)
191[info] hbase (2.13.10, 2.12.17)
192[info] kudu (2.13.10, 2.12.17)
193[info] google-cloud-storage (2.13.10, 2.12.17)
194[info] avroparquet-tests (2.13.10, 2.12.17)
195[info] orientdb (2.13.10, 2.12.17)
196[info] couchbase (2.13.10, 2.12.17)
197[info] awslambda (2.13.10, 2.12.17)
198[info] solr (2.13.10, 2.12.17)
199[info] hdfs (2.13.10, 2.12.17)
200[info] Reapplying settings...
201[info]
202[info] ** Welcome to the sbt build definition for Alpakka! **
203[info]
204[info] Useful sbt tasks:
205[info]
206[info] docs/previewSite - builds Paradox and Scaladoc documentation,
207[info] starts a webserver and opens a new browser window
208[info]
209[info] test - runs all the tests for all of the connectors.
210[info] Make sure to run `docker-compose up` first.
211[info]
212[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
213[info]
214[info] mimaReportBinaryIssues - checks whether this current API
215[info] is binary compatible with the released version
216[info]
217Execute mapScalacOptions: ,REQUIRE:-source:3.8,-Wconf:msg=can be rewritten automatically under:s ,-deprecation,-feature,-Xfatal-warnings,-Werror,MATCH:.*-Wconf.*any:e
218[info] Reapplying settings...
219[info]
220[info] ** Welcome to the sbt build definition for Alpakka! **
221[info]
222[info] Useful sbt tasks:
223[info]
224[info] docs/previewSite - builds Paradox and Scaladoc documentation,
225[info] starts a webserver and opens a new browser window
226[info]
227[info] test - runs all the tests for all of the connectors.
228[info] Make sure to run `docker-compose up` first.
229[info]
230[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
231[info]
232[info] mimaReportBinaryIssues - checks whether this current API
233[info] is binary compatible with the released version
234[info]
235[info] Defining Global / credentials, amqp / credentials and 52 others.
236[info] The new values will be used by Global / pgpSelectPassphrase, Global / pgpSigningKey and 269 others.
237[info] Run `last` for details.
238[info] Reapplying settings...
239[info]
240[info] ** Welcome to the sbt build definition for Alpakka! **
241[info]
242[info] Useful sbt tasks:
243[info]
244[info] docs/previewSite - builds Paradox and Scaladoc documentation,
245[info] starts a webserver and opens a new browser window
246[info]
247[info] test - runs all the tests for all of the connectors.
248[info] Make sure to run `docker-compose up` first.
249[info]
250[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
251[info]
252[info] mimaReportBinaryIssues - checks whether this current API
253[info] is binary compatible with the released version
254[info]
255Execute excludeLibraryDependency: com.github.ghik:zerowaste_{scalaVersion} com.olegpy:better-monadic-for_3 org.polyvariant:better-tostring_{scalaVersion} org.wartremover:wartremover_{scalaVersion}
256[info] Reapplying settings...
257OpenCB::Failed to reapply settings in excludeLibraryDependency: Reference to undefined setting:
258
259 Global / allExcludeDependencies from Global / allExcludeDependencies (CommunityBuildPlugin.scala:331)
260 Did you mean unix-domain-socket / allExcludeDependencies ?
261 , retry without global scopes
262[info] Reapplying settings...
263[info]
264[info] ** Welcome to the sbt build definition for Alpakka! **
265[info]
266[info] Useful sbt tasks:
267[info]
268[info] docs/previewSite - builds Paradox and Scaladoc documentation,
269[info] starts a webserver and opens a new browser window
270[info]
271[info] test - runs all the tests for all of the connectors.
272[info] Make sure to run `docker-compose up` first.
273[info]
274[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
275[info]
276[info] mimaReportBinaryIssues - checks whether this current API
277[info] is binary compatible with the released version
278[info]
279Execute removeScalacOptionsStartingWith: -P:wartremover
280[info] Reapplying settings...
281[info]
282[info] ** Welcome to the sbt build definition for Alpakka! **
283[info]
284[info] Useful sbt tasks:
285[info]
286[info] docs/previewSite - builds Paradox and Scaladoc documentation,
287[info] starts a webserver and opens a new browser window
288[info]
289[info] test - runs all the tests for all of the connectors.
290[info] Make sure to run `docker-compose up` first.
291[info]
292[info] mqtt/testOnly *.MqttSourceSpec - runs a single test
293[info]
294[info] mimaReportBinaryIssues - checks whether this current API
295[info] is binary compatible with the released version
296[info]
297[success] Total time: 0 s, completed Jan 3, 2026, 12:43:49 AM
298Build config: {"projects":{"exclude":[],"overrides":{}},"java":{"version":"17"},"sbt":{"commands":[],"options":[]},"mill":{"options":[]},"tests":"compile-only","migrationVersions":[],"sourcePatches":[{"path":"project/Dependencies.scala","pattern":"libraryDependencies := ","replaceWith":"libraryDependencies ++= "},{"path":"project/Dependencies.scala","pattern":"val Scala3 = \"3.2.2\"","replaceWith":"val Scala3 = \"<SCALA_VERSION>\""}]}
299Parsed config: Success(ProjectBuildConfig(ProjectsConfig(List(),Map()),CompileOnly,List()))
300Starting build...
301Projects: Set(s3, amqp, csv, cassandra, avroparquet, testkit)
302Starting build for ProjectRef(file:/build/repo/,amqp) (akka-stream-alpakka-amqp)... [0/6]
303OpenCB::Exclude Scala3 specific scalacOption `REQUIRE:-source:3.8` in Scala 2.12.20 module Global
304OpenCB::Filter out '-feature', matches setting pattern '^-?-feature'
305OpenCB::Filter out '-deprecation', matches setting pattern '^-?-deprecation'
306Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
307[info] compiling 24 Scala sources to /build/repo/amqp/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
308[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
309[warn] bad option '-Ywarn-dead-code' was ignored
310[warn] two warnings found
311[info] done compiling
312[info] compiling 5 Scala sources to /build/repo/testkit/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
313[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
314[warn] bad option '-Ywarn-dead-code' was ignored
315[warn] two warnings found
316[info] done compiling
317[info] compiling 8 Scala sources and 4 Java sources to /build/repo/amqp/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/test-classes ...
318[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
319[warn] bad option '-Ywarn-dead-code' was ignored
320[warn] two warnings found
321[info] done compiling
322Starting build for ProjectRef(file:/build/repo/,cassandra) (akka-stream-alpakka-cassandra)... [1/6]
323Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
324[info] compiling 15 Scala sources to /build/repo/cassandra/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
325[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
326[warn] bad option '-Ywarn-dead-code' was ignored
327[warn] two warnings found
328[info] done compiling
329[info] compiling 7 Scala sources and 3 Java sources to /build/repo/cassandra/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/test-classes ...
330[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
331[warn] bad option '-Ywarn-dead-code' was ignored
332[warn] two warnings found
333[info] done compiling
334Starting build for ProjectRef(file:/build/repo/,csv) (akka-stream-alpakka-csv)... [2/6]
335Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
336[info] compiling 11 Scala sources and 5 Java sources to /build/repo/csv/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
337[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
338[warn] bad option '-Ywarn-dead-code' was ignored
339[warn] two warnings found
340[info] done compiling
341[info] compiling 6 Scala sources and 3 Java sources to /build/repo/csv/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/test-classes ...
342[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
343[warn] bad option '-Ywarn-dead-code' was ignored
344[warn] two warnings found
345[info] done compiling
346Starting build for ProjectRef(file:/build/repo/,testkit) (akka-stream-alpakka-testkit)... [3/6]
347Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
348Starting build for ProjectRef(file:/build/repo/,s3) (akka-stream-alpakka-s3)... [4/6]
349Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
350[info] compiling 26 Scala sources to /build/repo/s3/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
351[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
352[warn] bad option '-Ywarn-dead-code' was ignored
353[warn] -- Warning: /build/repo/s3/src/main/scala/akka/stream/alpakka/s3/javadsl/S3.scala:44:6
354[warn] 44 | def request(bucket: String, key: String, method: HttpMethod, s3Headers: S3Headers): Source[HttpResponse, NotUsed] =
355[warn] | ^
356[warn] | Infinite recursive call
357[warn] |
358[warn] 45 | request(bucket, key, method, s3Headers)
359[warn] three warnings found
360[info] done compiling
361[info] compiling 24 Scala sources and 1 Java source to /build/repo/s3/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/test-classes ...
362[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
363[warn] bad option '-Ywarn-dead-code' was ignored
364[warn] two warnings found
365[warn] /build/repo/s3/src/test/java/docs/javadsl/S3Test.java:44:8: akka$testkit$TestKitBase$$queue() in akka.testkit.TestKit implements akka$testkit$TestKitBase$$queue() in akka.testkit.TestKitBase
366[warn] return type requires unchecked conversion from java.util.concurrent.LinkedBlockingDeque to java.util.concurrent.LinkedBlockingDeque<akka.testkit.TestActor.Message>
367[warn] public class S3Test extends S3WireMockBase {
368[warn] @Rule public final LogCapturingJunit4 logCapturing = new LogCapturingJunit4();
369[warn]
370[warn] private static ActorSystem system;
371[warn] private static WireMockServer wireMockServerForShutdown;
372[warn]
373[warn] private final S3Settings sampleSettings = S3Ext.get(system()).settings();
374[warn] private final String prefix = listPrefix();
375[warn] private final String delimiter = listDelimiter();
376[warn]
377[warn] @Before
378[warn] public void before() {
379[warn] wireMockServerForShutdown = _wireMockServer();
380[warn] system = system();
381[warn] }
382[warn]
383[warn] @AfterClass
384[warn] public static void afterAll() throws Exception {
385[warn] wireMockServerForShutdown.stop();
386[warn] Http.get(system)
387[warn] .shutdownAllConnectionPools()
388[warn] .thenRun(() -> TestKit.shutdownActorSystem(system));
389[warn] }
390[warn]
391[warn] @Test
392[warn] public void multipartUpload() throws Exception {
393[warn]
394[warn] mockUpload();
395[warn]
396[warn] // #upload
397[warn] final Source<ByteString, NotUsed> file = Source.single(ByteString.fromString(body()));
398[warn]
399[warn] final Sink<ByteString, CompletionStage<MultipartUploadResult>> sink =
400[warn] S3.multipartUpload(bucket(), bucketKey());
401[warn]
402[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage = file.runWith(sink, system);
403[warn] // #upload
404[warn]
405[warn] MultipartUploadResult result =
406[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
407[warn]
408[warn] assertEquals(
409[warn] MultipartUploadResult.create(
410[warn] Uri.create(url()), bucket(), bucketKey(), etag(), Optional.empty()),
411[warn] result);
412[warn] }
413[warn]
414[warn] @Test
415[warn] public void multipartUploadSSE() throws Exception {
416[warn]
417[warn] mockUploadSSE();
418[warn]
419[warn] final Sink<ByteString, CompletionStage<MultipartUploadResult>> sink =
420[warn] S3.multipartUpload(
421[warn] bucket(),
422[warn] bucketKey(),
423[warn] ContentTypes.APPLICATION_OCTET_STREAM,
424[warn] S3Headers.create().withServerSideEncryption(sseCustomerKeys()));
425[warn]
426[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
427[warn] Source.single(ByteString.fromString(body())).runWith(sink, system);
428[warn]
429[warn] MultipartUploadResult result =
430[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
431[warn]
432[warn] assertEquals(
433[warn] MultipartUploadResult.create(
434[warn] Uri.create(url()), bucket(), bucketKey(), etag(), Optional.empty()),
435[warn] result);
436[warn] }
437[warn]
438[warn] @Test
439[warn] public void download() throws Exception {
440[warn]
441[warn] mockDownload();
442[warn]
443[warn] // #download
444[warn] final Source<ByteString, CompletionStage<ObjectMetadata>> s3Source =
445[warn] S3.getObject(bucket(), bucketKey());
446[warn] final Pair<CompletionStage<ObjectMetadata>, CompletionStage<String>> dataAndMetadata =
447[warn] s3Source.map(ByteString::utf8String).toMat(Sink.head(), Keep.both()).run(system);
448[warn]
449[warn] final CompletionStage<ObjectMetadata> metadataCompletionStage = dataAndMetadata.first();
450[warn] final CompletionStage<String> dataCompletionStage = dataAndMetadata.second();
451[warn]
452[warn] // #download
453[warn]
454[warn] // #downloadToAkkaHttp
455[warn] metadataCompletionStage.thenApply(
456[warn] metadata ->
457[warn] HttpResponse.create()
458[warn] .withEntity(
459[warn] HttpEntities.create(
460[warn] metadata
461[warn] .getContentType()
462[warn] .map(ContentTypes::parse)
463[warn] .orElse(ContentTypes.APPLICATION_OCTET_STREAM),
464[warn] metadata.getContentLength(),
465[warn] s3Source)));
466[warn] // #downloadToAkkaHttp
467[warn]
468[warn] String result = dataCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
469[warn] ObjectMetadata metadata =
470[warn] metadataCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
471[warn]
472[warn] System.out.println("#####");
473[warn] System.out.println(metadata.getContentLength());
474[warn]
475[warn] assertEquals(body(), result);
476[warn] }
477[warn]
478[warn] @Test
479[warn] public void head() throws Exception {
480[warn]
481[warn] long contentLength = 8L;
482[warn] mockHead(contentLength);
483[warn]
484[warn] // #objectMetadata
485[warn] final Source<Optional<ObjectMetadata>, NotUsed> source =
486[warn] S3.getObjectMetadata(bucket(), bucketKey());
487[warn] // #objectMetadata
488[warn]
489[warn] Optional<ObjectMetadata> result =
490[warn] source.runWith(Sink.head(), system).toCompletableFuture().get(5, TimeUnit.SECONDS);
491[warn]
492[warn] final ObjectMetadata objectMetadata = result.get();
493[warn] Optional<String> s3eTag = objectMetadata.getETag();
494[warn] long actualContentLength = objectMetadata.getContentLength();
495[warn] Optional<String> versionId = objectMetadata.getVersionId();
496[warn]
497[warn] assertEquals(s3eTag, Optional.of(etag()));
498[warn] assertEquals(actualContentLength, contentLength);
499[warn] assertEquals(versionId, Optional.empty());
500[warn] }
501[warn]
502[warn] @Test
503[warn] public void headWithVersion() throws Exception {
504[warn] String versionId = "3/L4kqtJlcpXroDTDmJ+rmSpXd3dIbrHY+MTRCxf3vjVBH40Nr8X8gdRQBpUMLUo";
505[warn] mockHeadWithVersion(versionId);
506[warn]
507[warn] final Source<Optional<ObjectMetadata>, NotUsed> source =
508[warn] S3.getObjectMetadata(bucket(), bucketKey(), Optional.of(versionId), null);
509[warn]
510[warn] Optional<ObjectMetadata> result =
511[warn] source.runWith(Sink.head(), system).toCompletableFuture().get(5, TimeUnit.SECONDS);
512[warn]
513[warn] final ObjectMetadata objectMetadata = result.get();
514[warn] Optional<String> s3eTag = objectMetadata.getETag();
515[warn] Optional<String> metadataVersionId = objectMetadata.getVersionId();
516[warn]
517[warn] assertEquals(s3eTag, Optional.of(etag()));
518[warn] assertEquals(metadataVersionId, Optional.of(versionId));
519[warn] }
520[warn]
521[warn] @Test
522[warn] public void headServerSideEncryption() throws Exception {
523[warn] mockHeadSSEC();
524[warn]
525[warn] final Source<Optional<ObjectMetadata>, NotUsed> source =
526[warn] S3.getObjectMetadata(bucket(), bucketKey(), sseCustomerKeys());
527[warn]
528[warn] Optional<ObjectMetadata> result =
529[warn] source.runWith(Sink.head(), system).toCompletableFuture().get(5, TimeUnit.SECONDS);
530[warn]
531[warn] Optional<String> etag = result.get().getETag();
532[warn]
533[warn] assertEquals(etag, Optional.of(etagSSE()));
534[warn] }
535[warn]
536[warn] @Test
537[warn] public void downloadServerSideEncryption() throws Exception {
538[warn] mockDownloadSSEC();
539[warn]
540[warn] final Source<ByteString, CompletionStage<ObjectMetadata>> s3Source =
541[warn] S3.getObject(bucket(), bucketKey(), sseCustomerKeys());
542[warn]
543[warn] final CompletionStage<String> resultCompletionStage =
544[warn] s3Source.map(ByteString::utf8String).runWith(Sink.head(), system);
545[warn]
546[warn] String result = resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
547[warn]
548[warn] assertEquals(bodySSE(), result);
549[warn] }
550[warn]
551[warn] @Test
552[warn] public void downloadServerSideEncryptionWithVersion() throws Exception {
553[warn] String versionId = "3/L4kqtJlcpXroDTDmJ+rmSpXd3dIbrHY+MTRCxf3vjVBH40Nr8X8gdRQBpUMLUo";
554[warn] mockDownloadSSECWithVersion(versionId);
555[warn]
556[warn] final Source<ByteString, CompletionStage<ObjectMetadata>> s3Source =
557[warn] S3.getObject(bucket(), bucketKey(), null, Optional.of(versionId), sseCustomerKeys());
558[warn]
559[warn] final Pair<CompletionStage<ObjectMetadata>, CompletionStage<String>> p =
560[warn] s3Source.map(ByteString::utf8String).toMat(Sink.head(), Keep.both()).run(system);
561[warn]
562[warn] final CompletionStage<String> resultCompletionStage = p.second();
563[warn] final String result = resultCompletionStage.toCompletableFuture().get(2, TimeUnit.SECONDS);
564[warn] assertEquals(bodySSE(), result);
565[warn]
566[warn] final ObjectMetadata metadata = p.first().toCompletableFuture().get(2, TimeUnit.SECONDS);
567[warn] assertEquals(Optional.of(versionId), metadata.getVersionId());
568[warn] }
569[warn]
570[warn] @Test
571[warn] public void rangedDownload() throws Exception {
572[warn]
573[warn] mockRangedDownload();
574[warn]
575[warn] // #rangedDownload
576[warn] final Source<ByteString, CompletionStage<ObjectMetadata>> sourceAndMeta =
577[warn] S3.getObject(
578[warn] bucket(), bucketKey(), ByteRange.createSlice(bytesRangeStart(), bytesRangeEnd()));
579[warn] // #rangedDownload
580[warn]
581[warn] final CompletionStage<byte[]> resultCompletionStage =
582[warn] sourceAndMeta.map(ByteString::toArray).runWith(Sink.head(), system);
583[warn]
584[warn] byte[] result = resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
585[warn]
586[warn] assertTrue(Arrays.equals(rangeOfBody(), result));
587[warn] }
588[warn]
589[warn] @Test
590[warn] public void rangedDownloadServerSideEncryption() throws Exception {
591[warn]
592[warn] mockRangedDownloadSSE();
593[warn]
594[warn] final Source<ByteString, CompletionStage<ObjectMetadata>> sourceAndMeta =
595[warn] S3.getObject(
596[warn] bucket(),
597[warn] bucketKey(),
598[warn] ByteRange.createSlice(bytesRangeStart(), bytesRangeEnd()),
599[warn] sseCustomerKeys());
600[warn]
601[warn] final CompletionStage<byte[]> resultCompletionStage =
602[warn] sourceAndMeta.map(ByteString::toArray).runWith(Sink.head(), system);
603[warn]
604[warn] byte[] result = resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
605[warn]
606[warn] assertTrue(Arrays.equals(rangeOfBodySSE(), result));
607[warn] }
608[warn]
609[warn] @Test
610[warn] public void listBucket() throws Exception {
611[warn]
612[warn] mockListBucket();
613[warn]
614[warn] // #list-bucket
615[warn] final Source<ListBucketResultContents, NotUsed> keySource =
616[warn] S3.listBucket(bucket(), Optional.of(prefix));
617[warn] // #list-bucket
618[warn]
619[warn] final CompletionStage<ListBucketResultContents> resultCompletionStage =
620[warn] keySource.runWith(Sink.head(), system);
621[warn]
622[warn] ListBucketResultContents result =
623[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
624[warn]
625[warn] assertEquals(result.key(), listKey());
626[warn] }
627[warn]
628[warn] @Test
629[warn] public void listBucketVersion1() throws Exception {
630[warn] mockListBucketVersion1();
631[warn]
632[warn] // #list-bucket-attributes
633[warn] final S3Settings useVersion1Api =
634[warn] S3Ext.get(system()).settings().withListBucketApiVersion(ApiVersion.getListBucketVersion1());
635[warn]
636[warn] final Source<ListBucketResultContents, NotUsed> keySource =
637[warn] S3.listBucket(bucket(), Optional.of(prefix))
638[warn] .withAttributes(S3Attributes.settings(useVersion1Api));
639[warn] // #list-bucket-attributes
640[warn]
641[warn] final CompletionStage<ListBucketResultContents> resultCompletionStage =
642[warn] keySource.runWith(Sink.head(), system);
643[warn]
644[warn] ListBucketResultContents result =
645[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
646[warn]
647[warn] assertEquals(result.key(), listKey());
648[warn] }
649[warn]
650[warn] @Test
651[warn] public void listBucketWithDelimiter() throws Exception {
652[warn]
653[warn] mockListBucketAndCommonPrefixes();
654[warn]
655[warn] // #list-bucket-delimiter
656[warn] final Source<ListBucketResultContents, NotUsed> keySource =
657[warn] S3.listBucket(bucket(), delimiter, Optional.of(prefix));
658[warn] // #list-bucket-delimiter
659[warn]
660[warn] final CompletionStage<ListBucketResultContents> resultCompletionStage =
661[warn] keySource.runWith(Sink.head(), system);
662[warn]
663[warn] ListBucketResultContents result =
664[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
665[warn]
666[warn] assertEquals(result.key(), listKey());
667[warn] }
668[warn]
669[warn] @Test
670[warn] public void listBucketAndCommonPrefixes() throws Exception {
671[warn]
672[warn] mockListBucketAndCommonPrefixes();
673[warn]
674[warn] // #list-bucket-and-common-prefixes
675[warn] final Source<
676[warn] Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>, NotUsed>
677[warn] keySource =
678[warn] S3.listBucketAndCommonPrefixes(
679[warn] bucket(), delimiter, Optional.of(prefix), S3Headers.empty());
680[warn] // #list-bucket-and-common-prefixes
681[warn]
682[warn] final CompletionStage<
683[warn] List<Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>>>
684[warn] resultsCompletionStage = keySource.runWith(Sink.seq(), system);
685[warn]
686[warn] final List<Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>> results =
687[warn] resultsCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
688[warn]
689[warn] final List<ListBucketResultContents> contents = results.get(0).first();
690[warn] final List<ListBucketResultCommonPrefixes> commonPrefixes = results.get(0).second();
691[warn]
692[warn] assertEquals(contents.get(0).key(), listKey());
693[warn] assertEquals(commonPrefixes.get(0).prefix(), listCommonPrefix());
694[warn] }
695[warn]
696[warn] @Test
697[warn] public void listBucketAndCommonPrefixesVersion1() throws Exception {
698[warn] mockListBucketAndCommonPrefixesVersion1();
699[warn]
700[warn] // #list-bucket-and-common-prefixes-attributes
701[warn] final S3Settings useVersion1Api =
702[warn] S3Ext.get(system()).settings().withListBucketApiVersion(ApiVersion.getListBucketVersion1());
703[warn]
704[warn] final Source<
705[warn] Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>, NotUsed>
706[warn] keySource =
707[warn] S3.listBucketAndCommonPrefixes(
708[warn] bucket(), delimiter, Optional.of(prefix), S3Headers.empty())
709[warn] .withAttributes(S3Attributes.settings(useVersion1Api));
710[warn] // #list-bucket-and-common-prefixes-attributes
711[warn]
712[warn] final CompletionStage<
713[warn] List<Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>>>
714[warn] resultsCompletionStage = keySource.runWith(Sink.seq(), system);
715[warn]
716[warn] final List<Pair<List<ListBucketResultContents>, List<ListBucketResultCommonPrefixes>>> results =
717[warn] resultsCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
718[warn]
719[warn] final List<ListBucketResultContents> contents = results.get(0).first();
720[warn] final List<ListBucketResultCommonPrefixes> commonPrefixes = results.get(0).second();
721[warn]
722[warn] assertEquals(contents.get(0).key(), listKey());
723[warn] assertEquals(commonPrefixes.get(0).prefix(), listCommonPrefix());
724[warn] }
725[warn]
726[warn] @Test
727[warn] public void copyUploadWithContentLengthLessThenChunkSize() throws Exception {
728[warn] mockCopy();
729[warn]
730[warn] String bucket = bucket();
731[warn] String sourceKey = bucketKey();
732[warn] String targetBucket = targetBucket();
733[warn] String targetKey = targetBucketKey();
734[warn] // #multipart-copy
735[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
736[warn] S3.multipartCopy(bucket, sourceKey, targetBucket, targetKey).run(system);
737[warn] // #multipart-copy
738[warn]
739[warn] final MultipartUploadResult result =
740[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
741[warn]
742[warn] assertEquals(
743[warn] result,
744[warn] MultipartUploadResult.create(
745[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
746[warn] }
747[warn]
748[warn] @Test
749[warn] public void copyUploadWithSourceVersion() throws Exception {
750[warn] mockCopyVersioned();
751[warn]
752[warn] String bucket = bucket();
753[warn] String sourceKey = bucketKey();
754[warn] String targetBucket = targetBucket();
755[warn] String targetKey = targetBucketKey();
756[warn]
757[warn] // #multipart-copy-with-source-version
758[warn] String sourceVersionId = "3/L4kqtJlcpXroDTDmJ+rmSpXd3dIbrHY+MTRCxf3vjVBH40Nr8X8gdRQBpUMLUo";
759[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
760[warn] S3.multipartCopy(
761[warn] bucket,
762[warn] sourceKey,
763[warn] targetBucket,
764[warn] targetKey,
765[warn] Optional.of(sourceVersionId),
766[warn] S3Headers.create())
767[warn] .run(system);
768[warn] // #multipart-copy-with-source-version
769[warn]
770[warn] final MultipartUploadResult result =
771[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
772[warn]
773[warn] assertEquals(
774[warn] result,
775[warn] MultipartUploadResult.create(
776[warn] Uri.create(targetUrl()),
777[warn] targetBucket(),
778[warn] targetBucketKey(),
779[warn] etag(),
780[warn] Optional.of("43jfkodU8493jnFJD9fjj3HHNVfdsQUIFDNsidf038jfdsjGFDSIRp")));
781[warn] }
782[warn]
783[warn] @Test
784[warn] public void copyUploadWithContentLengthEqualToChunkSize() throws Exception {
785[warn] mockCopy(5242880);
786[warn]
787[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
788[warn] S3.multipartCopy(bucket(), bucketKey(), targetBucket(), targetBucketKey()).run(system);
789[warn] final MultipartUploadResult result =
790[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
791[warn]
792[warn] assertEquals(
793[warn] result,
794[warn] MultipartUploadResult.create(
795[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
796[warn] }
797[warn]
798[warn] @Test
799[warn] public void copyUploadWithContentLengthGreaterThenChunkSize() throws Exception {
800[warn] mockCopyMulti();
801[warn]
802[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
803[warn] S3.multipartCopy(bucket(), bucketKey(), targetBucket(), targetBucketKey()).run(system);
804[warn] final MultipartUploadResult result =
805[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
806[warn]
807[warn] assertEquals(
808[warn] result,
809[warn] MultipartUploadResult.create(
810[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
811[warn] }
812[warn]
813[warn] @Test
814[warn] public void copyUploadEmptyFile() throws Exception {
815[warn] mockCopy(0);
816[warn]
817[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
818[warn] S3.multipartCopy(bucket(), bucketKey(), targetBucket(), targetBucketKey()).run(system);
819[warn] final MultipartUploadResult result =
820[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
821[warn]
822[warn] assertEquals(
823[warn] result,
824[warn] MultipartUploadResult.create(
825[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
826[warn] }
827[warn]
828[warn] @Test
829[warn] public void copyUploadWithSSE() throws Exception {
830[warn] mockCopySSE();
831[warn]
832[warn] // #multipart-copy-sse
833[warn] final CustomerKeys keys =
834[warn] ServerSideEncryption.customerKeys(sseCustomerKey()).withMd5(sseCustomerMd5Key());
835[warn]
836[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
837[warn] S3.multipartCopy(
838[warn] bucket(),
839[warn] bucketKey(),
840[warn] targetBucket(),
841[warn] targetBucketKey(),
842[warn] S3Headers.create().withServerSideEncryption(keys))
843[warn] .run(system);
844[warn] // #multipart-copy-sse
845[warn]
846[warn] final MultipartUploadResult result =
847[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
848[warn]
849[warn] assertEquals(
850[warn] result,
851[warn] MultipartUploadResult.create(
852[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
853[warn] }
854[warn]
855[warn] @Test
856[warn] public void copyUploadWithCustomHeader() throws Exception {
857[warn] mockCopy();
858[warn]
859[warn] final CompletionStage<MultipartUploadResult> resultCompletionStage =
860[warn] S3.multipartCopy(
861[warn] bucket(),
862[warn] bucketKey(),
863[warn] targetBucket(),
864[warn] targetBucketKey(),
865[warn] S3Headers.create().withServerSideEncryption(ServerSideEncryption.aes256()))
866[warn] .run(system);
867[warn]
868[warn] final MultipartUploadResult result =
869[warn] resultCompletionStage.toCompletableFuture().get(5, TimeUnit.SECONDS);
870[warn]
871[warn] assertEquals(
872[warn] result,
873[warn] MultipartUploadResult.create(
874[warn] Uri.create(targetUrl()), targetBucket(), targetBucketKey(), etag(), Optional.empty()));
875[warn] }
876[warn]
877[warn] @Test
878[warn] public void makeBucket() throws Exception {
879[warn] mockMakingBucket();
880[warn]
881[warn] // #make-bucket
882[warn] final Attributes sampleAttributes = S3Attributes.settings(sampleSettings);
883[warn]
884[warn] final String bucketName = "samplebucket1";
885[warn]
886[warn] CompletionStage<Done> makeBucketRequest = S3.makeBucket(bucketName, system);
887[warn] CompletionStage<Done> makeBucketRequestWithAttributes =
888[warn] S3.makeBucket(bucketName, system, sampleAttributes);
889[warn] Source<Done, NotUsed> makeBucketSourceRequest = S3.makeBucketSource(bucketName);
890[warn] // #make-bucket
891[warn]
892[warn] assertEquals(makeBucketRequest.toCompletableFuture().get(5, TimeUnit.SECONDS), Done.done());
893[warn] assertEquals(
894[warn] makeBucketRequestWithAttributes.toCompletableFuture().get(5, TimeUnit.SECONDS),
895[warn] Done.done());
896[warn] assertEquals(
897[warn] makeBucketSourceRequest
898[warn] .runWith(Sink.ignore(), system)
899[warn] .toCompletableFuture()
900[warn] .get(5, TimeUnit.SECONDS),
901[warn] Done.done());
902[warn] }
903[warn]
904[warn] @Test
905[warn] public void deleteBucket() throws Exception {
906[warn] final String bucketName = "samplebucket1";
907[warn]
908[warn] mockDeletingBucket();
909[warn]
910[warn] // #delete-bucket
911[warn] final Attributes sampleAttributes = S3Attributes.settings(sampleSettings);
912[warn]
913[warn] CompletionStage<Done> deleteBucketRequest = S3.deleteBucket(bucketName, system);
914[warn] CompletionStage<Done> deleteBucketRequestWithAttribues =
915[warn] S3.deleteBucket(bucketName, system, sampleAttributes);
916[warn]
917[warn] Source<Done, NotUsed> deleteBucketSourceRequest = S3.deleteBucketSource(bucketName);
918[warn] // #delete-bucket
919[warn]
920[warn] assertEquals(deleteBucketRequest.toCompletableFuture().get(5, TimeUnit.SECONDS), Done.done());
921[warn]
922[warn] assertEquals(
923[warn] deleteBucketRequestWithAttribues.toCompletableFuture().get(5, TimeUnit.SECONDS),
924[warn] Done.done());
925[warn]
926[warn] assertEquals(
927[warn] deleteBucketSourceRequest
928[warn] .runWith(Sink.ignore(), system)
929[warn] .toCompletableFuture()
930[warn] .get(5, TimeUnit.SECONDS),
931[warn] Done.done());
932[warn] }
933[warn]
934[warn] @Test
935[warn] public void checkIfBucketExistsForNonExisting() throws Exception {
936[warn] mockCheckingBucketStateForNonExistingBucket();
937[warn]
938[warn] // #check-if-bucket-exists
939[warn] final Attributes sampleAttributes = S3Attributes.settings(sampleSettings);
940[warn]
941[warn] final CompletionStage<BucketAccess> doesntExistRequest =
942[warn] S3.checkIfBucketExists(bucket(), system);
943[warn] final CompletionStage<BucketAccess> doesntExistRequestWithAttributes =
944[warn] S3.checkIfBucketExists(bucket(), system, sampleAttributes);
945[warn]
946[warn] final Source<BucketAccess, NotUsed> doesntExistSourceRequest =
947[warn] S3.checkIfBucketExistsSource(bucket());
948[warn] // #check-if-bucket-exists
949[warn]
950[warn] assertEquals(
951[warn] doesntExistRequest.toCompletableFuture().get(5, TimeUnit.SECONDS),
952[warn] BucketAccess.notExists());
953[warn]
954[warn] assertEquals(
955[warn] doesntExistRequestWithAttributes.toCompletableFuture().get(5, TimeUnit.SECONDS),
956[warn] BucketAccess.notExists());
957[warn]
958[warn] assertEquals(
959[warn] doesntExistSourceRequest
960[warn] .runWith(Sink.head(), system)
961[warn] .toCompletableFuture()
962[warn] .get(5, TimeUnit.SECONDS),
963[warn] BucketAccess.notExists());
964[warn] }
965[warn]
966[warn] @Test
967[warn] public void checkIfBucketExistsForExisting() throws Exception {
968[warn] mockCheckingBucketStateForExistingBucket();
969[warn]
970[warn] final CompletionStage<BucketAccess> existRequest = S3.checkIfBucketExists(bucket(), system);
971[warn]
972[warn] final Source<BucketAccess, NotUsed> existSourceRequest = S3.checkIfBucketExistsSource(bucket());
973[warn]
974[warn] assertEquals(
975[warn] existRequest.toCompletableFuture().get(5, TimeUnit.SECONDS), BucketAccess.accessGranted());
976[warn]
977[warn] assertEquals(
978[warn] existSourceRequest
979[warn] .runWith(Sink.head(), system)
980[warn] .toCompletableFuture()
981[warn] .get(5, TimeUnit.SECONDS),
982[warn] BucketAccess.accessGranted());
983[warn] }
984[warn]
985[warn] @Test
986[warn] public void checkIfBucketExistsForBucketWithoutRights() throws Exception {
987[warn] mockCheckingBucketStateForBucketWithoutRights();
988[warn]
989[warn] final CompletionStage<BucketAccess> noRightsRequest = S3.checkIfBucketExists(bucket(), system);
990[warn]
991[warn] final Source<BucketAccess, NotUsed> noRightsSourceRequest =
992[warn] S3.checkIfBucketExistsSource(bucket());
993[warn]
994[warn] assertEquals(
995[warn] noRightsRequest.toCompletableFuture().get(5, TimeUnit.SECONDS),
996[warn] BucketAccess.accessDenied());
997[warn]
998[warn] assertEquals(
999[warn] noRightsSourceRequest
1000[warn] .runWith(Sink.head(), system)
1001[warn] .toCompletableFuture()
1002[warn] .get(5, TimeUnit.SECONDS),
1003[warn] BucketAccess.accessDenied());
1004[warn] }
1005[warn] }
1006[warn] ^
1007[info] done compiling
1008Starting build for ProjectRef(file:/build/repo/,avroparquet) (akka-stream-alpakka-avroparquet)... [5/6]
1009Compile scalacOptions: -encoding, UTF-8, -unchecked, -Xlint, -Ywarn-dead-code, --java-output-version:17, 8, -Wconf:cat=deprecation&msg=.*JavaConverters.*:s, -Wconf:msg=can be rewritten automatically under:s, -source:3.8
1010[info] compiling 8 Scala sources to /build/repo/avroparquet/target/scala-3.8.1-RC1-bin-20260102-32e416e-NIGHTLY/classes ...
1011[warn] Option -Xlint is deprecated: Use -Wshadow to enable shadowing lints. Scheduled for removal.
1012[warn] bad option '-Ywarn-dead-code' was ignored
1013[warn] two warnings found
1014[info] done compiling
1015
1016************************
1017Build summary:
1018[{
1019 "module": "akka-stream-alpakka-amqp",
1020 "compile": {"status": "ok", "tookMs": 9707, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1021 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1022 "test-compile": {"status": "ok", "tookMs": 8946, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1023 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1024 "publish": {"status": "skipped", "tookMs": 0},
1025 "metadata": {
1026 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1027}
1028},{
1029 "module": "akka-stream-alpakka-cassandra",
1030 "compile": {"status": "ok", "tookMs": 1774, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1031 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1032 "test-compile": {"status": "ok", "tookMs": 3938, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1033 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1034 "publish": {"status": "skipped", "tookMs": 0},
1035 "metadata": {
1036 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1037}
1038},{
1039 "module": "akka-stream-alpakka-csv",
1040 "compile": {"status": "ok", "tookMs": 1426, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1041 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1042 "test-compile": {"status": "ok", "tookMs": 4067, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1043 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1044 "publish": {"status": "skipped", "tookMs": 0},
1045 "metadata": {
1046 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1047}
1048},{
1049 "module": "akka-stream-alpakka-testkit",
1050 "compile": {"status": "ok", "tookMs": 83, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1051 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1052 "test-compile": {"status": "ok", "tookMs": 150, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1053 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1054 "publish": {"status": "ok", "tookMs": 5},
1055 "metadata": {
1056 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1057}
1058},{
1059 "module": "akka-stream-alpakka-s3",
1060 "compile": {"status": "ok", "tookMs": 4825, "warnings": 1, "errors": 0, "sourceVersion": "3.8"},
1061 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1062 "test-compile": {"status": "ok", "tookMs": 9559, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1063 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1064 "publish": {"status": "skipped", "tookMs": 0},
1065 "metadata": {
1066 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1067}
1068},{
1069 "module": "akka-stream-alpakka-avroparquet",
1070 "compile": {"status": "ok", "tookMs": 491, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1071 "doc": {"status": "skipped", "tookMs": 0, "files": 0, "totalSizeKb": 0},
1072 "test-compile": {"status": "ok", "tookMs": 204, "warnings": 0, "errors": 0, "sourceVersion": "3.8"},
1073 "test": {"status": "skipped", "tookMs": 0, "passed": 0, "failed": 0, "ignored": 0, "skipped": 0, "total": 0, "byFramework": []},
1074 "publish": {"status": "skipped", "tookMs": 0},
1075 "metadata": {
1076 "crossScalaVersions": ["2.13.10", "2.12.17", "3.2.2"]
1077}
1078}]
1079************************
1080[success] Total time: 62 s (0:01:02.0), completed Jan 3, 2026, 12:44:52 AM
1081[0JChecking patch project/plugins.sbt...
1082Checking patch project/build.properties...
1083Checking patch project/Dependencies.scala...
1084Checking patch build.sbt...
1085Applied patch project/plugins.sbt cleanly.
1086Applied patch project/build.properties cleanly.
1087Applied patch project/Dependencies.scala cleanly.
1088Applied patch build.sbt cleanly.