Skip to content

Commit 927f69f

Browse files
authored
Merge pull request #2 from codetojoy/jdk-25
support for Java 25
2 parents 09cb1d9 + faacf07 commit 927f69f

File tree

57 files changed

+269
-176
lines changed

Some content is hidden

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

57 files changed

+269
-176
lines changed

.github/workflows/build.yml renamed to .github/workflows.break.until.jdk25.available/build.yml

File renamed without changes.

.github/workflows/gradle_build.yml renamed to .github/workflows.break.until.jdk25.available/gradle_build.yml

File renamed without changes.

.github/workflows/gradle_test.yml renamed to .github/workflows.break.until.jdk25.available/gradle_test.yml

File renamed without changes.

.github/workflows/mvn_build.yml renamed to .github/workflows.break.until.jdk25.available/mvn_build.yml

File renamed without changes.

.github/workflows/mvn_test.yml renamed to .github/workflows.break.until.jdk25.available/mvn_test.yml

File renamed without changes.

2025-09-JDK-25-list.txt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
2+
3+
4+
- egg1
5+
- ok for bash, Gradle, Maven
6+
- egg2
7+
- ok for bash, Gradle, Maven
8+
- egg3
9+
- ok for bash, Gradle, Maven
10+
- egg4
11+
- ok for bash, Gradle, Maven
12+
- egg5
13+
- ok for bash, Gradle, Maven
14+
- egg6
15+
- ok for bash, Gradle, Maven
16+
- egg7
17+
- ok for bash, Gradle, Maven
18+
- egg8
19+
- ok for bash, Gradle, Maven
20+
- egg9
21+
- ok for bash, Gradle, Maven

Gradle.version.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Gradle 7.6-rc-1
1+
Gradle 9.1.0-rc-4

JDK.version.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
19-open via [SDKMan!](https://sdkman.io/)
1+
Java.net 25.ea.36-open via [SDKMan!](https://sdkman.io/)

Maven.version.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Apache Maven 3.8.6
1+
Apache Maven 3.9.11

README.md

Lines changed: 42 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,50 @@
11

22
### easter_eggs_for_java_loom
33

4-
- examples re: [Project Loom](https://openjdk.org/projects/loom/) in JDK 21
4+
- examples re: [Project Loom](https://openjdk.org/projects/loom/)
55
- usage of *egg* here is intended as an [SSCCE](http://sscce.org/); **not** a [hidden feature](https://en.wikipedia.org/wiki/Easter_egg_(media))
66

7-
### Notes
7+
### Notes, SEP 2025
8+
9+
* SEP 2025: see `jdk-25` branch for Java 25 (work in progress)
10+
* eggs work with Bash, Gradle, or Maven
11+
12+
### Index
13+
14+
* egg_1_max_p_threads
15+
* demo max # of platform threads
16+
* egg_2_max_v_threads
17+
* demo max # of virtual threads
18+
* egg_3_legacy_exec
19+
* illustrates legacy executor/thread pool
20+
* egg_4_virtual_exec
21+
* illustrates virtual threads via ExecutorService
22+
* egg_5_sc_invoke_all
23+
* structured concurrency
24+
* two tasks: `foo` and `bar`
25+
- can be configured to succeed or fail
26+
- when one task is configured to fail, the other is interrupted
27+
* egg_6_sc_invoke_any
28+
* structured concurrency
29+
* task `foo` and task `bar` are in a race: first one to complete is used; the other is interrupted
30+
* egg_7_sc_deadline
31+
* illustrates structured concurrency
32+
* task `foo` and task `bar` take too long and exceed a deadline
33+
- both are interrupted
34+
* egg_8_sc_custom_invoke_some
35+
* this egg illustrates structured concurrency
36+
* create `T` tasks
37+
- use a custom `StructuredTaskScope.Joiner` to define success when `n` tasks complete
38+
- if familiar with `invokeAny()` and `invokeAll()`, this could be considered `invokeSome(n)`
39+
* NOTE: highly contrived and NOT production-ready
40+
* egg_9_sc_fan_in
41+
* simple `client` to send messages over a socket to a `server`
42+
* NOTE: highly contrived and NOT production-ready
43+
* others
44+
* see `jdk-19` branch
45+
* these may not have been moved to `jdk-21` and definitely not `jdk-25`
46+
47+
### Notes, SEP 2023
848

949
* as of September 2023, these work using Bash but not Gradle or Maven
1050
* GitHub actions are broken, pending availability of JDK 21
@@ -15,34 +55,3 @@
1555
* see README for each example
1656
* test message
1757

18-
### Workflows
19-
20-
* create token on GitHub for workflow scope
21-
* use `git remote set-url origin https://codetojoy:[email protected]/codetojoy/easter_eggs_for_java_loom.git`
22-
23-
24-
### Resources
25-
26-
* JEP 425 [Virtual Threads](https://openjdk.java.net/jeps/425)
27-
* JEP 428 [Structured Concurrency](https://openjdk.java.net/jeps/428)
28-
* Brian Goetz on [Virtual Threads](https://www.infoq.com/articles/java-virtual-threads/)
29-
* [Java 19 Virtual Threads - JEP Café](https://www.youtube.com/watch?v=lKSSBvRDmTg)
30-
* [Project Loom: Modern Scalable Concurrency for the Java Platform](https://www.youtube.com/watch?v=EO9oMiL1fFo) by Ron Pressler
31-
- 12m00s : "codes like sync, scales like async"
32-
- 12m34s : excellent discussion on Thread vs async/await in various languages
33-
- 30m44s : great slides illustrating 1:1 versus M:N
34-
- 37m34s : Little's Law
35-
* [Project Loom: Revolution in concurrency or obscure implementation detail?](https://www.youtube.com/watch?v=n_XRUljffu0) by Tomasz Nurkiewicz
36-
- contrarian view
37-
* [Project Loom - A Friend or Foe of Reactive?](https://www.youtube.com/watch?v=YwG04UZP2a0) by Oleh Dokuka and Andrii Rodionov
38-
- contrarian view
39-
- esp. near 19m20s
40-
* [AMA About the Java Language](https://www.youtube.com/watch?v=9si7gK94gLo) by Brian Goetz and Nicolai Parlog
41-
- near 19m10s, "Loom will kill Reactive programming"
42-
- reddit thread [here](https://www.reddit.com/r/programming/comments/oxsnqg/brian_goetz_i_think_project_loom_is_going_to_kill/)
43-
* [Project Loom Q&A with Ron Pressler](https://www.youtube.com/watch?v=cAHW96omBAc)
44-
- esp. near 55m25s
45-
* [Project Loom C5M](https://github.com/ebarlas/project-loom-c5m)
46-
- 5 million concurrent connections
47-
* [Conway's Game of Life with virtual threads](https://github.com/ebarlas/game-of-life-csp)
48-
* blog post: [Notes on structured concurrency, or: Go statement considered harmful](https://vorpus.org/blog/notes-on-structured-concurrency-or-go-statement-considered-harmful) by Nathaniel J. Smith

0 commit comments

Comments
 (0)