Comments (5)
@oldratlee 大概知道是什么问题了,我用的jdk是openj9,换成openjdk就没问题了,不知道什么原因,ThreadPoolExecutor这个类没有加载,所以没有被增强。
但是里面的内部类加载了。
使用arthars jad命令后,才会重新触发增强。
from transmittable-thread-local.
@jakejakeho 使用是agent的方式,是不需要使用TtlRunnable包装的,Completablefuture里面的ForkJoinPool就没有问题。不使用agent直接用ttl包装Executor也没有问题。
from transmittable-thread-local.
orangewest/ttl-demo#1
應該是因為沒有用TtlRunnable.get()
from transmittable-thread-local.
上面说明的是 日志/MDC
的问题(原因可能是 日志/MDC
的使用或实现):
- 请分离出
TTL
的问题/Bug
的说明 - 非
TTL
的内容(如日志/MDC
的问题或使用方式),请尽量不在本库讨论
另外,请提供一个 极简、可运行、复现问题的 代码Demo工程。
推荐提供成一个单独的工程(GitHub repo)。这样可以:
- 方便大家能排查分析;只提供片段代码、运行问题概述,排查信息不足
- 方便分离不相关的业务实现内容,以及排除可能的业务使用问题
如使用配置问题、其它业务代码的意外影响
from transmittable-thread-local.
@oldratlee
demo地址 https://github.com/orangewest/ttl-demo
启动参数
代码
运行结果
from transmittable-thread-local.
Related Issues (20)
- -javaagent:D:\jar\transmittable-thread-local-2.14.0.jar 必须使用带版本号的名称,去除版本号会报错 HOT 1
- k8s环境下CPU调整>2数量后线程上下文传递失效 HOT 1
- 官方maven仓库的版本没有同步? HOT 2
- ListenableFuture添加了监听回调,回调线程获取不到正确的值? HOT 3
- 配合线程池使用时,remove了之后,下一个任务还是能拿到上一个任务设置的值 HOT 1
- 线上运行开始父子线程可以传递threadlocal变量,运行一段时间失效 HOT 1
- 使用jrebel -javaagent方式启动,在stream().parallel()无法正确获取内容
- jdk并发流parallelStream支持这种改造吗 HOT 1
- 在Java21的虚拟线程中不使用`TTL`会有问题吗? HOT 1
- TtlRunnable是否可以支持PriorityQueue和DelayQueue HOT 2
- 从哪里可以看到每个版本迭代哪些内容,或者修复了哪些bug HOT 1
- `Stream#parallel()#forEach()`或者`List#parallelStream()#forEach()`时,如何使用不丢失`TTL`值 HOT 1
- TTL是否支持调用中包含多种协议场景情况下的上下文传递 HOT 1
- TTL Agent instrument the class exception HOT 2
- graalvm TraversingBlockingQueue ArrayStoreException HOT 1
- 父线程调用remove清除缓存后,是否需要子线程显式romove HOT 1
- 请问下,在spring boot 场景下,filter 中进入时set ,但是业务中异步线程还未执行完,filter 请求已经finally remove了,这时获取到的值为null, 这种情况如何保证正确性 HOT 3
- TTL 的 java agent 模式与dragonwell 的 eagerappcds有冲突 HOT 5
- 在transmittable-thread-local-2.12.4.jar agent 模式下与 nacos spring cloud loadbalance 偶发并发问题 HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from transmittable-thread-local.