mirror of
https://github.com/Linloir/Simple-TCP-Server.git
synced 2025-12-16 23:48:11 +08:00
Bug Fix & Improvements
- Improve logs - Fix fetch message not working
This commit is contained in:
parent
0aa72b5dc3
commit
5909308475
@ -1,7 +1,7 @@
|
||||
/*
|
||||
* @Author : Linloir
|
||||
* @Date : 2022-10-06 15:44:16
|
||||
* @LastEditTime : 2022-10-19 14:41:56
|
||||
* @LastEditTime : 2022-10-20 01:00:24
|
||||
* @Description :
|
||||
*/
|
||||
|
||||
@ -121,9 +121,15 @@ void main(List<String> arguments) async {
|
||||
);
|
||||
for(var controller in targetControllers) {
|
||||
try {
|
||||
print('[L] [MSGFOWARD]-----------------------');
|
||||
print('[L] Forwarding message to ${controller.socket.remoteAddress}:${controller.socket.remotePort}');
|
||||
controller.outStream.add(forwardResponse);
|
||||
} catch(e) {
|
||||
print(e);
|
||||
print('[E] [EXCEPTION]-----------------------');
|
||||
var token = controllerMap[controller];
|
||||
controllerMap.remove(controller);
|
||||
tokenMap[token]?.remove(controller);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
//Update Fetch Histories
|
||||
@ -153,6 +159,7 @@ void main(List<String> arguments) async {
|
||||
var token = controllerMap[controller];
|
||||
controllerMap.remove(controller);
|
||||
tokenMap[token]?.remove(controller);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
//Update Fetch Histories
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
/*
|
||||
* @Author : Linloir
|
||||
* @Date : 2022-10-06 16:15:01
|
||||
* @LastEditTime : 2022-10-18 14:12:22
|
||||
* @LastEditTime : 2022-10-20 10:40:50
|
||||
* @Description :
|
||||
*/
|
||||
|
||||
@ -358,7 +358,7 @@ class DataBaseHelper {
|
||||
|
||||
//Fetch unfetched messages
|
||||
var unfetchMsgQueryResult = await _database.query(
|
||||
'msgs join msgfiles on msgs.md5encoded = msgfiles.msgmd5',
|
||||
'msgs left outer join msgfiles on msgs.md5encoded = msgfiles.msgmd5',
|
||||
columns: [
|
||||
'msgs.userid as userid',
|
||||
'msgs.targetid as targetid',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user