...Dim Sending As ResumableSub = api.Send_Vag(name, "")
Do Until Sending.Completed
Sleep(50)
Loop
Synchronous sending a record from this project DB (under VPN) to a public user-interface db server via PHP-API. All sent OK.also what is doing that ?
i am sure that sent ok... but the problem is wait it to over and then go on... so it is better be (api.Send_Vag) resumablesub that return true or false or what you want with that logic:Sending a record from this project DB (under VPN) to a public user-interface db server via PHP-API. All sent OK.
wait for (api.Send_Vag(name, "")) complete (result as boolean)
'sleep(0) not needed but for psychological reason or if graphics playing on screen using it...
if result=true then
else
end if
No influence.LIMIT 1
Seems, found:
at peacemaker.sc4grabber.resultcursor._executesql(resultcursor.java:101)
Private Sub ExecuteSQL
Dim cur As ResultSet
If mStringArgs = Null Then
Dim mStringArgs(0) As String
End If
cur = mSQL.ExecQuery2(mQuery, mStringArgs)
Dim mRows As List
mRows.Initialize
mRowCount = 0
Dim jrs As JavaObject = cur
Dim rsmd As JavaObject = jrs.RunMethod("getMetaData", Null)
mColumnCount = cur.ColumnCount
mColumns.Initialize
For i = 0 To mColumnCount - 1
mColumns.Put(cur.GetColumnName(i), i)
Next
mRows.Initialize
Do While cur.NextRow
Dim row(mColumnCount) As Object
For i = 0 To mColumnCount - 1
Dim ct As Int = rsmd.RunMethod("getColumnType", Array(i + 1))
'check whether it is a blob field
If ct = -2 Or ct = 2004 Or ct = -3 Or ct = -4 Then
row(i) = cur.GetBlob2(i)
Else if ct = 2 Or ct = 3 Then
row(i) = cur.GetDouble2(i)
Else
row(i) = jrs.RunMethod("getObject", Array(i + 1))
End If
Next
mRows.Add(row)
mRowCount = mRowCount + 1
If mLimit > 0 And mRows.Size >= mLimit Then Exit
Loop
cur.Close
End Sub
Dim rs As ResultSet = db.ExecQuery2("..... LIMIT 1",Array As String(tid))
Do While rs.NextRow
..
Loop
rs.close
please re-post the fixed sub - to re-check it...Only this one resultset was not closed, thanks. Now closed, but no change, error is here.
Sub timSystem_Tick
timSystem.Enabled = False
If machine_id = 0 Then
Dim filter As Map: filter.Initialize
filter.Put("scanner_name", others.Get_DeviceID)
webapi1.API_LOAD("scanners", filter)
Wait For API_LOADED (L As List)
If L.Size > 0 Then
Dim machine_id As Int = L.Get(0).As(Map).Get("machine_id")
Log("machine_id = " & machine_id)
timFTPupload_Tick
Else
Log("machine_id trouble !")
End If
Else
Dim names As ResultCursor
names.Initialize(db.SQL, "SELECT * FROM " & db.DBT_NAMES & " WHERE sent = '0'", Null, 1)
For i = 0 To names.RowCount - 1
names.Position = i
Dim name As String = names.GetString("name")
Log("Sending ... " & name)
db.SQL.ExecNonQuery("UPDATE " & db.DBT_NAMES & " SET sent = '2' WHERE name = '" & name & "' LIMIT 1") 'sending status
Dim Sending As ResumableSub = api.Send_Vag(name, "")
Do Until Sending.Completed
Sleep(50)
Loop
Dim filter As Map: filter.Initialize
filter.Put("machine_id", machine_id)
filter.Put("name", name)
webapi1.API_LOAD("objs", filter)
Wait For API_LOADED (L As List)
If L.Size > 0 Then
Dim obj_id As Int = L.Get(0).As(Map).Get("id")
Log("obj_id = " & obj_id)
Dim obj_img As String = L.Get(0).As(Map).Get("img")
Log("obj_img = " & obj_img)
'img name for server: sample_4_85.jpg = sample_ machine_id _ obj_id .jpg
Dim img_name As String = "sample_" & machine_id & "_" & obj_id & ".jpg"
Log("img_name = " & img_name)
Log("Sending2 ... " & name)
db.SQL.ExecNonQuery("UPDATE " & db.DBT_NAMES & " SET sent = '2' WHERE name = '" & name & "' LIMIT 1") 'sending status
Dim Sending As ResumableSub = api.Send_Vag(name, img_name)
Do Until Sending.Completed
Sleep(50)
Loop
Dim local_file As String = db.SQL.ExecQuerySingleResult("SELECT x.img FROM (SELECT img, id FROM " & db.DBT_OBJS & " WHERE name = '" & name & "' ORDER BY id DESC, rate DESC LIMIT 10) AS x LIMIT 1")
Log("local_file = " & local_file)
local_file = fs.getPath(local_file)
Log("local_file2 = " & local_file)
If local_file <> "" Then
If File.Exists(File.DirApp, "by_ftp") = False Then
File.MakeDir(File.DirApp, "by_ftp")
End If
Dim local_folder As String = File.Combine(File.Combine(File.DirApp, "by_ftp"), machine_id)
If File.Exists(local_folder, "") = False Then
File.MakeDir(local_folder, "")
End If
File.Copy("", local_file, local_folder, img_name) 'save file for next uploading by FTP
End If
Else
Log("no obj_id yet")
End If
Log("Sent: " & name)
db.SQL.ExecNonQuery("UPDATE " & db.DBT_NAMES & " SET sent = '1' WHERE name = '" & name & "' LIMIT 1") 'sent status finally
Next
names.Close
names = Null
End If
timSystem.Enabled = True
End Sub
init mysql
2023-10-12 19:37:04.296:INFO :cmvl.MLog:MLog-Init-Reporter: MLog clients using slf4j logging.
2023-10-12 19:37:04.389:INFO :cmvc.C3P0Registry:main: Initializing c3p0-0.9.5.2 [built 08-December-2015 22:06:04 -0800; debug? true; trace: 10]
2023-10-12 19:37:04.426:INFO :cmvci.AbstractPoolBackedDataSource:main: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|4218d6a3, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|4218d6a3, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&autoReconnect
=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
DB inited
LoadRAMvectors = 2
RootFolder = /home/scat-learning/tempjars/blackbox
RootFolder = /home/scat-learning/tempjars/imgs
loading /home/scat-learning/tempjars: copymewithjar.needs...
Using cache system: 2.0
Current App version: 1696745374065
Needs material/awesome icons
GZipping HTML, JavaScript and CSS files...
Optimizing new and updated PNG files...
Building core.min.1696745374065.css...
2023-10-12 19:37:05.432:INFO :oejs.Server:main: jetty-11.0.9; built: 2022-03-30T17:44:47.085Z; git: 243a48a658a183130a8c8de353178d154ca04f04; jvm 11.0.1+13
2023-10-12 19:37:05.471:INFO :oejss.DefaultSessionIdManager:main: Session workerName=node0
2023-10-12 19:37:05.479:INFO :oejsh.ContextHandler:main: Started o.e.j.s.ServletContextHandler@278bb07e{/,file:///home/scat-learning/tempjars/www/,AVAILABLE}
2023-10-12 19:37:05.482:INFO :oejs.RequestLogWriter:main: Opened /home/scat-learning/tempjars/logs/b4j-2023_10_12.request.log
2023-10-12 19:37:05.487:INFO :oejs.AbstractConnector:main: Started ServerConnector@be68757{HTTP/1.1, (http/1.1)}{0.0.0.0:8080}
2023-10-12 19:37:05.489:INFO :oejs.Server:main: Started Server@34a875b3{STARTING}[11.0.9,sto=0] @1488ms
2023-10-12 19:37:05.490:INFO :oejs.Server:main: Stopped Server@34a875b3{STOPPING}[11.0.9,sto=0]
2023-10-12 19:37:05.491:INFO :oejs.AbstractConnector:main: Stopped ServerConnector@be68757{HTTP/1.1, (http/1.1)}{0.0.0.0:8080}
2023-10-12 19:37:05.493:INFO :oejsh.ContextHandler:main: Stopped o.e.j.s.ServletContextHandler@278bb07e{/,file:///home/scat-learning/tempjars/www/,STOPPED}
2023-10-12 19:37:05.497:INFO :oejs.Server:main: jetty-11.0.9; built: 2022-03-30T17:44:47.085Z; git: 243a48a658a183130a8c8de353178d154ca04f04; jvm 11.0.1+13
2023-10-12 19:37:05.500:INFO :oejsh.ContextHandler:main: Started o.e.j.s.ServletContextHandler@278bb07e{/,file:///home/scat-learning/tempjars/www/,AVAILABLE}
2023-10-12 19:37:05.500:INFO :oejs.RequestLogWriter:main: Opened /home/scat-learning/tempjars/logs/b4j-2023_10_12.request.log
2023-10-12 19:37:05.501:INFO :oejss.DefaultSessionIdManager:main: Session workerName=node0
2023-10-12 19:37:05.502:INFO :oejs.AbstractConnector:main: Started ServerConnector@be68757{HTTP/1.1, (http/1.1)}{0.0.0.0:8080}
~e:
2023-10-12 19:37:05.502:INFO :oejs.Server:main: Started Server@34a875b3{STARTING}[11.0.9,sto=0] @1501ms
~e:
Server is started at:
http://127.0.0.1:8080
java.lang.RuntimeException: java.lang.RuntimeException: Object should first be initialized (HttpSession).
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:140)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:98)
at anywheresoftware.b4j.object.WebSocketModule$Adapter$ThreadHandler.run(WebSocketModule.java:204)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
~e:
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
~e:
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
~e:
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
~e:
at java.base/java.lang.Thread.run(Thread.java:834)
~e:
Caused by: java.lang.RuntimeException: Object should first be initialized (HttpSession).
~e:
at anywheresoftware.b4a.AbsObjectWrapper.getObject(AbsObjectWrapper.java:49)
~e:
at anywheresoftware.b4j.object.HttpSessionWrapper.getIsNew(HttpSessionWrapper.java:111)
~e:
at peacemaker.sc4grabber.abmserver._connected(abmserver.java:108)
~e:
at peacemaker.sc4grabber.dbgen._websocket_connected(dbgen.java:1496)
~e:
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
~e:
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~e:
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~e:
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
~e:
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:111)
~e:
... 7 more
~e:
java.lang.RuntimeException: Object should first be initialized (HttpSession).
API_LOAD: scanners
machine_id = 1
FTP_connected
FTP_connected
FTP_connected
null
null
UpdateFromCache: dbgenef77fe9e-bd62-4ce7-a80d-8aeb2d4483c6
Saving the first instance
Websocket first connection
LoadRAMvectors = 2
wcl.Initialize(wcl)
ListFilesAndFolders(/home/scat-learning/tempjars/source_frames,*.jpg)
/home/scat-learning/tempjars/source_frames/08
/home/scat-learning/tempjars/source_frames/04
/home/scat-learning/tempjars/source_frames/02
/home/scat-learning/tempjars/source_frames/01
/home/scat-learning/tempjars/source_frames/03
/home/scat-learning/tempjars/source_frames/09
/home/scat-learning/tempjars/source_frames/video
/home/scat-learning/tempjars/source_frames/07
/home/scat-learning/tempjars/source_frames/05
/home/scat-learning/tempjars/source_frames/00
/home/scat-learning/tempjars/source_frames/10
/home/scat-learning/tempjars/source_frames/06
/home/scat-learning/tempjars/source_frames/11
Filelisting.Size = 3524
Dirlisting.Size = 13
initdb: abmok
init mysql
2023-10-12 19:37:24.382:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-2: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|5ef40b4e, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|5ef40b4e, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
FTP_connected
/home/scat-learning/tempjars/imgs_vectors: deleted all OK
DB inited
preparing for url refresh
null
null
UpdateFromCache: dbgenef77fe9e-bd62-4ce7-a80d-8aeb2d4483c6
Saving the first instance
Websocket first connection
LoadRAMvectors = 0
wcl.Initialize(wcl)
ListFilesAndFolders(/home/scat-learning/tempjars/source_frames,*.jpg)
/home/scat-learning/tempjars/source_frames/08
/home/scat-learning/tempjars/source_frames/04
/home/scat-learning/tempjars/source_frames/02
/home/scat-learning/tempjars/source_frames/01
/home/scat-learning/tempjars/source_frames/03
/home/scat-learning/tempjars/source_frames/09
/home/scat-learning/tempjars/source_frames/video
/home/scat-learning/tempjars/source_frames/07
/home/scat-learning/tempjars/source_frames/05
/home/scat-learning/tempjars/source_frames/00
/home/scat-learning/tempjars/source_frames/10
/home/scat-learning/tempjars/source_frames/06
/home/scat-learning/tempjars/source_frames/11
Filelisting.Size = 3524
Dirlisting.Size = 13
/01
Processing: /01
/01/img_2023-02-08_13-56-09.167_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:28.502:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|21e91fa4, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|21e91fa4, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-11.148_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:28.869:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|73a07eb2, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|73a07eb2, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-13.135_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:29.095:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|2f8ce751, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|2f8ce751, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0.7744427919387817
Zip file extracted!
/home/scat-learning/tempjars/imgs created
Extracting /home/scat-learning/tempjars/imgs/image_frame_2.jpg
Clear_Table_ByMins.Finished
inference_frame result: 0.7744427919387817
/01/img_2023-02-08_13-56-15.108_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:29.348:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|52b5a6cd, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|52b5a6cd, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0.8263271450996399
Zip file extracted!
/home/scat-learning/tempjars/imgs created
Extracting /home/scat-learning/tempjars/imgs/image_frame_3.jpg
Clear_Table_ByMins.Finished
inference_frame result: 0.8263271450996399
/01/img_2023-02-08_13-56-17.094_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:29.676:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|504e14f9, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|504e14f9, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
image_20231012_193729.383.jpg
RAMvectors.Add = 1
image_20231012_193729.144.jpg
RAMvectors.Add = 2
q1=UPDATE objs SET name = 'obj001' WHERE id >= '13' AND id <= '14'
New object was named = obj001
/01/img_2023-02-08_13-56-19.080_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:30.006:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|7db38d4, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|7db38d4, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&auto
Reconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-21.051_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:30.228:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|3b57f8f0, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|3b57f8f0, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-23.031_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:30.449:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|dcf00b3, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|dcf00b3, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&auto
Reconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-25.009_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:30.674:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|4d7429f, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|4d7429f, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&auto
Reconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
/01/img_2023-02-08_13-56-26.996_000.jpg
http://10.8.0.2:8111/api/inference_config
inference_config = {"ret":"ok","msg":""}
init mysql
2023-10-12 19:37:30.898:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|5ada3080, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|5ada3080, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&au
toReconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Rate = 0
Clear_Table_ByMins.Finished
Sending ... obj001
/01/img_2023-02-08_13-56-28.977_000.jpg
http://10.8.0.2:8111/api/inference_config
(MyMap) {name=obj001, rounds=1, time=1697125049733, stamp=12.10.2023 19:37:29.733(+0400), machine_id=1}
API_UPDATE: objs
obj001 vag was sent updated: Updated OK (objs)
API_LOAD: objs
obj_id = 29
obj_img = sample_1_29.jpg
img_name = sample_1_29.jpg
Sending2 ... obj001
(MyMap) {name=obj001, rounds=1, time=1697125049733, stamp=12.10.2023 19:37:29.733(+0400), machine_id=1, img=sample_1_29.jpg}
API_UPDATE: objs
obj001 vag was sent updated: Updated OK (objs)
inference_config = {"ret":"ok","msg":""}
init mysql
main.main (java line: 28)
java.lang.RuntimeException: java.lang.RuntimeException: java.sql.SQLException: You can't operate on a closed Connection!!!
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:140)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:98)
at peacemaker.sc4grabber.main.main(main.java:28)
Caused by: java.lang.RuntimeException: java.sql.SQLException: You can't operate on a closed Connection!!!
at anywheresoftware.b4a.keywords.Common$2$1.run(Common.java:1052)
at anywheresoftware.b4a.keywords.SimpleMessageLoop.runMessageLoop(SimpleMessageLoop.java:47)
at anywheresoftware.b4a.StandardBA.startMessageLoop(StandardBA.java:43)
at anywheresoftware.b4a.keywords.Common.StartMessageLoop(Common.java:180)
at peacemaker.sc4grabber.main._appstart(main.java:157)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:111)
... 2 more
Caused by: java.sql.SQLException: You can't operate on a closed Connection!!!
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:118)
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:77)
at com.mchange.v2.c3p0.impl.NewProxyConnection.prepareStatement(NewProxyConnection.java:576)
at anywheresoftware.b4j.objects.SQL.ExecQuery2(SQL.java:365)
at anywheresoftware.b4j.objects.SQL.ExecQuerySingleResult2(SQL.java:420)
at anywheresoftware.b4j.objects.SQL.ExecQuerySingleResult(SQL.java:409)
at peacemaker.sc4grabber.main$ResumableSub_timSystem_Tick.resume(main.java:987)
at anywheresoftware.b4a.keywords.Common$2$1.run(Common.java:1050)
... 11 more
Caused by: java.lang.NullPointerException
at com.mchange.v2.c3p0.impl.NewProxyConnection.prepareStatement(NewProxyConnection.java:540)
... 16 more
2023-10-12 19:37:31.242:INFO :cmvci.AbstractPoolBackedDataSource:pool-1-thread-3: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 20000, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge15jaza4xhe3gvgnrf|80d8628, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge15jaza4xhe3gvgnrf|80d8628, idleConnectionTestPeriod -> 600, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost/stancontrol?characterEncoding=utf8&allowPublicKeyRetrieval=false&auto
Reconnect=false&requireSSL=false&useSSL=false&pooling=true, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 150, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> true, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
Dim rs As ResultSet = db.ExecQuery2("..... LIMIT 1",Array As String(tid))
Do While rs.NextRow
....
Loop
rs.close
Updated, no difference.Resultset
But how new connections are created, if i do not call the pool ?com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Data source rejected establishment of connection, message from server: "Too many connections"
hmmmm....Updated, no difference.
But when i commented code of this timer - it's again error after some loops, but now about connections:
But how new connections are created, if i do not call the pool ?
Empty yet, at first start.java.lang.RuntimeException: java.lang.RuntimeException: Object should first be initialized (ResultSet).
java.lang.RuntimeException: java.sql.SQLException: Operation not allowed after ResultSet closed
....
Dim Sending As ResumableSub = api.Send_Vag(name, "")
Do Until Sending.Completed
Sleep(50)
Loop
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?