From 93686b9f57278118a4dbe7537313df5e6e5dadcd Mon Sep 17 00:00:00 2001 From: Jerry Lee Date: Sun, 2 Oct 2022 21:11:06 +0800 Subject: [PATCH] chore(ci): update ci jdks --- .github/workflows/ci.yaml | 4 ++-- README.md | 2 +- scripts/integration-test.sh | 1 - 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 220bdae51..00b28f177 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -10,13 +10,13 @@ jobs: strategy: matrix: os: [ ubuntu-latest, windows-latest ] - java: [ 8, 11, 16, 17, 18, 19-ea ] + java: [ 8, 11, 17, 18, 19, 20-ea ] fail-fast: false max-parallel: 64 name: Test JDK ${{ matrix.java }}, ${{ matrix.os }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: actions/setup-java@v3 with: java-version: ${{ matrix.java }} diff --git a/README.md b/README.md index ddf758b47..a99924ed3 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ # 🔧 功能 -👉 `TransmittableThreadLocal`(`TTL`):在使用线程池等会池化复用线程的执行组件情况下,提供`ThreadLocal`值的传递功能,解决异步执行时上下文传递的问题。一个`Java`标准库本应为框架/中间件设施开发提供的标配能力,本库功能聚焦 & 0依赖,支持`Java 6~19`。 +👉 `TransmittableThreadLocal`(`TTL`):在使用线程池等会池化复用线程的执行组件情况下,提供`ThreadLocal`值的传递功能,解决异步执行时上下文传递的问题。一个`Java`标准库本应为框架/中间件设施开发提供的标配能力,本库功能聚焦 & 0依赖,支持`Java 6~20`。 `JDK`的[`InheritableThreadLocal`](https://docs.oracle.com/javase/10/docs/api/java/lang/InheritableThreadLocal.html)类可以完成父线程到子线程的值传递。但对于使用线程池等会池化复用线程的执行组件的情况,线程由线程池创建好,并且线程是池化起来反复使用的;这时父子线程关系的`ThreadLocal`值传递已经没有意义,应用需要的实际上是把 **任务提交给线程池时**的`ThreadLocal`值传递到 **任务执行时**。 diff --git a/scripts/integration-test.sh b/scripts/integration-test.sh index 145533183..31b18bdec 100755 --- a/scripts/integration-test.sh +++ b/scripts/integration-test.sh @@ -18,7 +18,6 @@ readonly PREPARE_JDKS_INSTALL_BY_SDKMAN=( 8 "$default_build_jdk_version" 17 - 18 ) source "$BASH_BUDDY_ROOT/lib/prepare_jdks.sh"