@@ -109,8 +109,10 @@ def testRollbackOnRelease(self):
109
109
110
110
def testThreading (self ):
111
111
"""test session pool to database with multiple threads"""
112
- self .pool = cx_Oracle .SessionPool (USERNAME , PASSWORD , TNSENTRY , 5 , 20 ,
113
- 2 , threaded = True , encoding = ENCODING , nencoding = NENCODING )
112
+ self .pool = cx_Oracle .SessionPool (USERNAME , PASSWORD , TNSENTRY ,
113
+ min = 5 , max = 20 , increment = 2 , threaded = True ,
114
+ getmode = cx_Oracle .SPOOL_ATTRVAL_WAIT , encoding = ENCODING ,
115
+ nencoding = NENCODING )
114
116
threads = []
115
117
for i in range (20 ):
116
118
thread = threading .Thread (None , self .__ConnectAndDrop )
@@ -121,8 +123,10 @@ def testThreading(self):
121
123
122
124
def testThreadingWithErrors (self ):
123
125
"""test session pool to database with multiple threads (with errors)"""
124
- self .pool = cx_Oracle .SessionPool (USERNAME , PASSWORD , TNSENTRY , 5 , 20 ,
125
- 2 , threaded = True , encoding = ENCODING , nencoding = NENCODING )
126
+ self .pool = cx_Oracle .SessionPool (USERNAME , PASSWORD , TNSENTRY ,
127
+ min = 5 , max = 20 , increment = 2 , threaded = True ,
128
+ getmode = cx_Oracle .SPOOL_ATTRVAL_WAIT , encoding = ENCODING ,
129
+ nencoding = NENCODING )
126
130
threads = []
127
131
for i in range (20 ):
128
132
thread = threading .Thread (None , self .__ConnectAndGenerateError )
0 commit comments