|
@@ -109,10 +109,10 @@ namespace parkMonitor.server.CoreThread
|
|
|
/// </summary>
|
|
|
public void BeginWorking()
|
|
|
{
|
|
|
- Timer checkRemoteTimer = new System.Threading.Timer(CheckRemotePool, null, 100000, 300000);
|
|
|
- Timer checkLocalTimer = new System.Threading.Timer(CheckLocalPool, null, 100000, 300000);
|
|
|
+ Timer checkRemoteTimer = new System.Threading.Timer(CheckRemotePool, null, 10000, 300000);
|
|
|
+ Timer checkLocalTimer = new System.Threading.Timer(CheckLocalPool, null, 10000, 300000);
|
|
|
//Timer updateTimer = new System.Threading.Timer(updateGarageAndParkingSpace, null, 1000, 3000);
|
|
|
- Timer logTimer = new System.Threading.Timer(displayLog, null, 1000, 1800000);
|
|
|
+ Timer logTimer = new System.Threading.Timer(displayLog, null, 1000, 30000);
|
|
|
Object lockObj = new object();
|
|
|
Command queueCmdRecord = null;
|
|
|
while (!isClosing)
|
|
@@ -253,6 +253,10 @@ namespace parkMonitor.server.CoreThread
|
|
|
{
|
|
|
//Operation.MyTransaction(EntityForCore.remoteBQ,sqlMsg, out parkingRecordsID);
|
|
|
parkingRecordsID = DBOperation.InsertParkingRecords(EntityForCore.remoteBQ, strs);
|
|
|
+ if (parkingRecordsID == 0)
|
|
|
+ {
|
|
|
+ Log.WriteLog(LogType.DATABASE, sqlStatus + ":" + sqlMsg);
|
|
|
+ }
|
|
|
}
|
|
|
catch
|
|
|
{
|
|
@@ -262,11 +266,15 @@ namespace parkMonitor.server.CoreThread
|
|
|
}
|
|
|
if (sqlStatus == "0")
|
|
|
{
|
|
|
- int temp;
|
|
|
+ object result;
|
|
|
try
|
|
|
{
|
|
|
//Operation.MyTransaction(EntityForCore.remoteBQ,sqlMsg, out temp);
|
|
|
- DBOperation.InsertParkingRecords(EntityForCore.remoteBQ, strs);
|
|
|
+ result = DBOperation.UpdateTransaction(EntityForCore.remoteBQ, strs);
|
|
|
+ if (!(bool)result)
|
|
|
+ {
|
|
|
+ Log.WriteLog(LogType.DATABASE, sqlStatus + ":" + sqlMsg);
|
|
|
+ }
|
|
|
}
|
|
|
catch
|
|
|
{
|