mirror of
https://github.com/openkmip/pykmip
synced 2025-12-15 07:43:26 +00:00
Do not leak database connections
This commit is contained in:
@@ -355,7 +355,8 @@ class KmipEngine(object):
|
||||
def _process_batch(self, request_batch, batch_handling, batch_order):
|
||||
response_batch = list()
|
||||
|
||||
self._data_session = self._data_store_session_factory()
|
||||
with self._data_store_session_factory() as session:
|
||||
self._data_session = session
|
||||
|
||||
for batch_item in request_batch:
|
||||
error_occurred = False
|
||||
|
||||
@@ -13,4 +13,4 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
__version__ = "0.11.0dev1"
|
||||
__version__ = "0.11.0.dev1"
|
||||
|
||||
Reference in New Issue
Block a user