数据库连接池完善

This commit is contained in:
sin365 2025-01-07 00:27:15 +08:00
parent 12f8f0eea5
commit 8ec0927037
7 changed files with 183 additions and 92 deletions

View File

@ -2,7 +2,7 @@
<PropertyGroup> <PropertyGroup>
<OutputType>Exe</OutputType> <OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework> <TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings> <ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable> <Nullable>enable</Nullable>
</PropertyGroup> </PropertyGroup>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup> <PropertyGroup>
<_LastSelectedProfileId>G:\Sin365\AxibugEmuOnline\AxibugEmuOnline.Server\Properties\PublishProfiles\FolderProfile.pubxml</_LastSelectedProfileId> <_LastSelectedProfileId>G:\Sin365\AxibugEmuOnline\AxibugEmuOnline.Server\Properties\PublishProfiles\FolderProfile1.pubxml</_LastSelectedProfileId>
</PropertyGroup> </PropertyGroup>
</Project> </Project>

View File

@ -54,7 +54,7 @@ namespace AxibugEmuOnline.Server.Common
{ {
_DicSqlRunFunNum[FuncStr] = 1L; _DicSqlRunFunNum[FuncStr] = 1L;
} }
MySqlConnection _conn; MySqlConnection _conn = null;
if (SQLPool.Count < 1) if (SQLPool.Count < 1)
{ {
Console.WriteLine("[DequeueSQLConn]创建新的SQLPool.Count>" + SQLPool.Count); Console.WriteLine("[DequeueSQLConn]创建新的SQLPool.Count>" + SQLPool.Count);
@ -63,14 +63,38 @@ namespace AxibugEmuOnline.Server.Common
} }
else else
{ {
Console.WriteLine("[DequeueSQLConn]取出一个SQLCount.Count>" + SQLPool.Count); MySqlConnection temp = null;
_conn = SQLPool.Dequeue(); while (SQLPool.Count > 0)
{
Console.WriteLine("[DequeueSQLConn]取出一个SQLCount.Count>" + SQLPool.Count);
temp = SQLPool.Dequeue();
if (temp.State == System.Data.ConnectionState.Closed)
{
Console.WriteLine("[DequeueSQLConn]已经断开SQLCount.Count>" + SQLPool.Count);
temp.Dispose();
temp = null;
continue;
}
}
if (temp != null)
{
_conn = temp;
}
else
{
Console.WriteLine("[DequeueSQLConn]连接池全部已断开,重新创建连接");
_conn = conn();
_conn.Open();
}
} }
_OutOfSQLPool.Add(_conn, new Haoyue_PoolTime _OutOfSQLPool.Add(_conn, new Haoyue_PoolTime
{ {
time = time(), time = time(),
FuncStr = FuncStr FuncStr = FuncStr
}); });
return _conn; return _conn;
} }
} }
@ -90,6 +114,7 @@ namespace AxibugEmuOnline.Server.Common
{ {
Console.WriteLine("已经不需要回收了,多余了,SQLPool.Count>" + SQLPool.Count); Console.WriteLine("已经不需要回收了,多余了,SQLPool.Count>" + SQLPool.Count);
BackConn.Close(); BackConn.Close();
BackConn.Dispose();
BackConn = null; BackConn = null;
} }
else else

View File

@ -188,6 +188,7 @@ namespace AxibugEmuOnline.Server.Manager
} }
catch (Exception e) catch (Exception e)
{ {
AppSrv.g_Log.Error($"ex=>{e.ToString()}");
bDone = false; bDone = false;
} }
Haoyue_SQLPoolManager.EnqueueSQLConn(conn); Haoyue_SQLPoolManager.EnqueueSQLConn(conn);

View File

@ -13,4 +13,5 @@ echo "==>>build finish"
echo "==>>copy cs" echo "==>>copy cs"
copy %cd%\out\CS\ ..\AxibugEmuOnline.Server\Protobuf copy %cd%\out\CS\ ..\AxibugEmuOnline.Server\Protobuf
copy %cd%\out\CS\ ..\AxibugEmuOnline.Client\Assets\Script\AppMain\Protobuf
pause pause

View File

@ -42,92 +42,96 @@ namespace AxibugProtobuf {
"X1VzZXJKb2luX1JFU1ASLgoIVXNlckluZm8YASABKAsyHC5BeGlidWdQcm90", "X1VzZXJKb2luX1JFU1ASLgoIVXNlckluZm8YASABKAsyHC5BeGlidWdQcm90",
"b2J1Zi5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k9YT05FEAgSCAoEV2lpVRAJEg8KC05pbnRlbmRvM0RTEAoq",
"CgVQYXVzZRAEEhAKDEluT25saW5lR2FtZRAFKk4KEUxvZ2luUmVzdWx0U3Rh", "ZAoMUGxhdGZvcm1UeXBlEgcKA0FsbBAAEgcKA05lcxABEhEKDU1hc3Rlcl9T",
"dHVzEiEKHUxvZ2luUmVzdWx0U3RhdHVzX0Jhc2VEZWZhdWx0EAASBgoCT0sQ", "eXN0ZW0QAhINCglHYW1lX0dlYXIQAxIMCghHYW1lX0JveRAEEhIKDkdhbWVf",
"ARIOCgpBY2NvdW50RXJyEAJCAkgBYgZwcm90bzM=")); "Qm95X0NvbG9yEAUqcAoNUm9vbUdhbWVTdGF0ZRISCg5Ob25lX0dhbWVTdGF0",
"ZRAAEgwKCE9ubHlIb3N0EAESEQoNV2FpdFJhd1VwZGF0ZRACEg0KCVdhaXRS",
"ZWFkeRADEgkKBVBhdXNlEAQSEAoMSW5PbmxpbmVHYW1lEAUqTgoRTG9naW5S",
"ZXN1bHRTdGF0dXMSIQodTG9naW5SZXN1bHRTdGF0dXNfQmFzZURlZmF1bHQQ",
"ABIGCgJPSxABEg4KCkFjY291bnRFcnIQAkICSAFiBnByb3RvMw=="));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { }, new pbr::FileDescriptor[] { },
new pbr::GeneratedClrTypeInfo(new[] {typeof(global::AxibugProtobuf.CommandID), typeof(global::AxibugProtobuf.ErrorCode), typeof(global::AxibugProtobuf.LoginType), typeof(global::AxibugProtobuf.DeviceType), typeof(global::AxibugProtobuf.PlatformType), typeof(global::AxibugProtobuf.RoomGameState), typeof(global::AxibugProtobuf.LoginResultStatus), }, null, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(new[] {typeof(global::AxibugProtobuf.CommandID), typeof(global::AxibugProtobuf.ErrorCode), typeof(global::AxibugProtobuf.LoginType), typeof(global::AxibugProtobuf.DeviceType), typeof(global::AxibugProtobuf.PlatformType), typeof(global::AxibugProtobuf.RoomGameState), typeof(global::AxibugProtobuf.LoginResultStatus), }, null, new pbr::GeneratedClrTypeInfo[] {
@ -142,7 +146,7 @@ namespace AxibugProtobuf {
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserJoin_RESP), global::AxibugProtobuf.Protobuf_UserJoin_RESP.Parser, new[]{ "UserInfo" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserJoin_RESP), global::AxibugProtobuf.Protobuf_UserJoin_RESP.Parser, new[]{ "UserInfo" }, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserLeave_RESP), global::AxibugProtobuf.Protobuf_UserLeave_RESP.Parser, new[]{ "UID" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserLeave_RESP), global::AxibugProtobuf.Protobuf_UserLeave_RESP.Parser, new[]{ "UID" }, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserState_RESP), global::AxibugProtobuf.Protobuf_UserState_RESP.Parser, new[]{ "UID", "State" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_UserState_RESP), global::AxibugProtobuf.Protobuf_UserState_RESP.Parser, new[]{ "UID", "State" }, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.UserMiniInfo), global::AxibugProtobuf.UserMiniInfo.Parser, new[]{ "UID", "NickName" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.UserMiniInfo), global::AxibugProtobuf.UserMiniInfo.Parser, new[]{ "UID", "NickName", "DeviceType" }, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Modify_NickName), global::AxibugProtobuf.Protobuf_Modify_NickName.Parser, new[]{ "NickName" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Modify_NickName), global::AxibugProtobuf.Protobuf_Modify_NickName.Parser, new[]{ "NickName" }, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Modify_NickName_RESP), global::AxibugProtobuf.Protobuf_Modify_NickName_RESP.Parser, null, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Modify_NickName_RESP), global::AxibugProtobuf.Protobuf_Modify_NickName_RESP.Parser, null, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Update_UserInfo_RESP), global::AxibugProtobuf.Protobuf_Update_UserInfo_RESP.Parser, new[]{ "UserInfo" }, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::AxibugProtobuf.Protobuf_Update_UserInfo_RESP), global::AxibugProtobuf.Protobuf_Update_UserInfo_RESP.Parser, new[]{ "UserInfo" }, null, null, null, null),
@ -363,11 +367,21 @@ namespace AxibugProtobuf {
[pbr::OriginalName("Android")] Android = 2, [pbr::OriginalName("Android")] Android = 2,
[pbr::OriginalName("IOS")] Ios = 3, [pbr::OriginalName("IOS")] Ios = 3,
[pbr::OriginalName("PSV")] Psv = 4, [pbr::OriginalName("PSV")] Psv = 4,
[pbr::OriginalName("PS3")] Ps3 = 5,
[pbr::OriginalName("PS4")] Ps4 = 6,
[pbr::OriginalName("XBOX360")] Xbox360 = 7,
[pbr::OriginalName("XBOXONE")] Xboxone = 8,
[pbr::OriginalName("WiiU")] WiiU = 9,
[pbr::OriginalName("Nintendo3DS")] Nintendo3Ds = 10,
} }
public enum PlatformType { public enum PlatformType {
[pbr::OriginalName("All")] All = 0, [pbr::OriginalName("All")] All = 0,
[pbr::OriginalName("Nes")] Nes = 1, [pbr::OriginalName("Nes")] Nes = 1,
[pbr::OriginalName("Master_System")] MasterSystem = 2,
[pbr::OriginalName("Game_Gear")] GameGear = 3,
[pbr::OriginalName("Game_Boy")] GameBoy = 4,
[pbr::OriginalName("Game_Boy_Color")] GameBoyColor = 5,
} }
public enum RoomGameState { public enum RoomGameState {
@ -2855,6 +2869,7 @@ namespace AxibugProtobuf {
public UserMiniInfo(UserMiniInfo other) : this() { public UserMiniInfo(UserMiniInfo other) : this() {
uID_ = other.uID_; uID_ = other.uID_;
nickName_ = other.nickName_; nickName_ = other.nickName_;
deviceType_ = other.deviceType_;
_unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
} }
@ -2891,6 +2906,20 @@ namespace AxibugProtobuf {
} }
} }
/// <summary>Field number for the "deviceType" field.</summary>
public const int DeviceTypeFieldNumber = 3;
private global::AxibugProtobuf.DeviceType deviceType_ = global::AxibugProtobuf.DeviceType.Default;
/// <summary>
///设备类型
/// </summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public global::AxibugProtobuf.DeviceType DeviceType {
get { return deviceType_; }
set {
deviceType_ = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override bool Equals(object other) { public override bool Equals(object other) {
return Equals(other as UserMiniInfo); return Equals(other as UserMiniInfo);
@ -2906,6 +2935,7 @@ namespace AxibugProtobuf {
} }
if (UID != other.UID) return false; if (UID != other.UID) return false;
if (NickName != other.NickName) return false; if (NickName != other.NickName) return false;
if (DeviceType != other.DeviceType) return false;
return Equals(_unknownFields, other._unknownFields); return Equals(_unknownFields, other._unknownFields);
} }
@ -2914,6 +2944,7 @@ namespace AxibugProtobuf {
int hash = 1; int hash = 1;
if (UID != 0L) hash ^= UID.GetHashCode(); if (UID != 0L) hash ^= UID.GetHashCode();
if (NickName.Length != 0) hash ^= NickName.GetHashCode(); if (NickName.Length != 0) hash ^= NickName.GetHashCode();
if (DeviceType != global::AxibugProtobuf.DeviceType.Default) hash ^= DeviceType.GetHashCode();
if (_unknownFields != null) { if (_unknownFields != null) {
hash ^= _unknownFields.GetHashCode(); hash ^= _unknownFields.GetHashCode();
} }
@ -2938,6 +2969,10 @@ namespace AxibugProtobuf {
output.WriteRawTag(18); output.WriteRawTag(18);
output.WriteString(NickName); output.WriteString(NickName);
} }
if (DeviceType != global::AxibugProtobuf.DeviceType.Default) {
output.WriteRawTag(24);
output.WriteEnum((int) DeviceType);
}
if (_unknownFields != null) { if (_unknownFields != null) {
_unknownFields.WriteTo(output); _unknownFields.WriteTo(output);
} }
@ -2955,6 +2990,10 @@ namespace AxibugProtobuf {
output.WriteRawTag(18); output.WriteRawTag(18);
output.WriteString(NickName); output.WriteString(NickName);
} }
if (DeviceType != global::AxibugProtobuf.DeviceType.Default) {
output.WriteRawTag(24);
output.WriteEnum((int) DeviceType);
}
if (_unknownFields != null) { if (_unknownFields != null) {
_unknownFields.WriteTo(ref output); _unknownFields.WriteTo(ref output);
} }
@ -2970,6 +3009,9 @@ namespace AxibugProtobuf {
if (NickName.Length != 0) { if (NickName.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeStringSize(NickName); size += 1 + pb::CodedOutputStream.ComputeStringSize(NickName);
} }
if (DeviceType != global::AxibugProtobuf.DeviceType.Default) {
size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) DeviceType);
}
if (_unknownFields != null) { if (_unknownFields != null) {
size += _unknownFields.CalculateSize(); size += _unknownFields.CalculateSize();
} }
@ -2987,6 +3029,9 @@ namespace AxibugProtobuf {
if (other.NickName.Length != 0) { if (other.NickName.Length != 0) {
NickName = other.NickName; NickName = other.NickName;
} }
if (other.DeviceType != global::AxibugProtobuf.DeviceType.Default) {
DeviceType = other.DeviceType;
}
_unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
} }
@ -3009,6 +3054,10 @@ namespace AxibugProtobuf {
NickName = input.ReadString(); NickName = input.ReadString();
break; break;
} }
case 24: {
DeviceType = (global::AxibugProtobuf.DeviceType) input.ReadEnum();
break;
}
} }
} }
#endif #endif
@ -3031,6 +3080,10 @@ namespace AxibugProtobuf {
NickName = input.ReadString(); NickName = input.ReadString();
break; break;
} }
case 24: {
DeviceType = (global::AxibugProtobuf.DeviceType) input.ReadEnum();
break;
}
} }
} }
} }

View File

@ -97,12 +97,22 @@ enum DeviceType
Android = 2; Android = 2;
IOS = 3; IOS = 3;
PSV = 4; PSV = 4;
PS3 = 5;
PS4 = 6;
XBOX360 = 7;
XBOXONE = 8;
WiiU = 9;
Nintendo3DS = 10;
} }
enum PlatformType enum PlatformType
{ {
All = 0; All = 0;
Nes = 1; Nes = 1;
Master_System = 2;
Game_Gear = 3;
Game_Boy = 4;
Game_Boy_Color = 5;
} }
//enum RoomPlayerState //enum RoomPlayerState
@ -213,6 +223,7 @@ message UserMiniInfo
{ {
int64 UID = 1;//ID int64 UID = 1;//ID
string NickName = 2;// string NickName = 2;//
DeviceType deviceType = 3;//
} }
// //