Introduced SimpleTransactionScope (analogous to SimpleThreadScope)
Issue: SPR-13085
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2015 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -29,9 +29,14 @@ import org.springframework.core.NamedThreadLocal;
|
||||
/**
|
||||
* A simple thread-backed {@link Scope} implementation.
|
||||
*
|
||||
* <p><strong>Note:</strong> {@code SimpleThreadScope} <em>does not clean up
|
||||
* any objects</em> associated with it. As such, it is typically preferable to
|
||||
* use {@link org.springframework.web.context.request.RequestScope RequestScope}
|
||||
* <p><b>NOTE:</b> This thread scope is not registered by default in common contexts.
|
||||
* Instead, you need to explicitly assign it to a scope key in your setup, either through
|
||||
* {@link org.springframework.beans.factory.config.ConfigurableBeanFactory#registerScope}
|
||||
* or through a {@link org.springframework.beans.factory.config.CustomScopeConfigurer} bean.
|
||||
*
|
||||
* <p>{@code SimpleThreadScope} <em>does not clean up any objects</em> associated with it.
|
||||
* As such, it is typically preferable to use
|
||||
* {@link org.springframework.web.context.request.RequestScope RequestScope}
|
||||
* in web environments.
|
||||
*
|
||||
* <p>For an implementation of a thread-based {@code Scope} with support for
|
||||
|
||||
Reference in New Issue
Block a user