Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SpringBoot sun.security.ssl.SSLSessionContextImpl Memory leak

The project uses SpringBoot 2.x, openjdk 1.8.0_232

Recently found that it can be consumed slowly. Through mat analysis, it is found that sun.security.ssl.SSLSessionContextImpl takes up a lot of memory over time

enter image description here

enter image description here

like image 342
liang peng Avatar asked Jun 11 '20 03:06

liang peng


2 Answers

Some people say by setting SSLContext.getDefault().getServerSessionContext().setSessionCacheSize(10);

I set it but it is invalid, maybe my way is wrong; I put it directly in the startup class to initialize

like image 64
liang peng Avatar answered Jan 03 '23 23:01

liang peng


Have the exact same problem, but in a Grails app (also based on Spring Boot 1.5.x). The problem persists also after settings those parameters - sessionCacheSize and sessionTimeout - to small values: 10 and 60 respectively.

like image 27
Vali Avatar answered Jan 04 '23 00:01

Vali



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!