SecurityContextHolderis a core utility class provided by Spring Security that holds the security context of the currently authenticated user for the current thread.
SecurityContextHolder uses ThreadLocal by default.
This means each thread handling a request has its own security context, so multiple users accessing your server don't interfere with each other.