Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use TracedExecutorService occur OOM #18

Open
Steven-Z-Yang opened this issue Dec 18, 2019 · 2 comments
Open

use TracedExecutorService occur OOM #18

Steven-Z-Yang opened this issue Dec 18, 2019 · 2 comments

Comments

@Steven-Z-Yang
Copy link

Steven-Z-Yang commented Dec 18, 2019

we used TracedExecutorService occur oom when service run long time with high throughput
code :
15765618875297

jvm dump analyze :

jvmDump

@sjoerdtalsma
Copy link
Collaborator

Both in TracedCallable and TracedRunnable any scope that gets activated is closed again after the operation.

Could it be that there are places where scopes are not closed properly?
Which scope manager do you use?

@Steven-Z-Yang
Copy link
Author

Steven-Z-Yang commented Dec 19, 2019

we used this scopManager:
https://github.com/PacktPublishing/Mastering-Distributed-Tracing/blob/master/Chapter11/exercise1/lib/src/main/java/lib/MDCScopeManager.java

we use TracedExecutorService code is :
@async("asyncThreadExecutor")
public void sendSms(List list) {
if (list.isEmpty()) {
log.warn("empty list...");
} else {
for(String str : list) {
try {
String response;
response = restTemplate.getForObject("http://localhost:8080/test", String.class);
log.info("execute call success....{}, {}", str, response);
} catch (Exception ex) {
ex.printStackTrace();
}
}
}
}

it can reappear oom when execute sendSms many times 。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants