Skip to content

Commit

Permalink
No commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
jacking75 committed Apr 29, 2019
1 parent 6127e76 commit 46dc006
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 15 deletions.
2 changes: 1 addition & 1 deletion SocketBase/Logging/NLogLog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ public void Error(object message)
/// <param name="exception">The exception.</param>
public void Error(object message, Exception exception)
{
throw new Exception("You have called a method that has not implemented this.");
Log.Error($"msg:{message}, exception:{exception.ToString()}");
}

/// <summary>
Expand Down
2 changes: 1 addition & 1 deletion SocketEngine/TcpSocketServerBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ protected IAppSession CreateSession(Socket client, ISocketSession session)
client.IOControl(IOControlCode.KeepAliveValues, m_KeepAliveOptionValues, m_KeepAliveOptionOutValues);

client.NoDelay = m_NoDelay;
client.LingerState = new LingerOption(enable:true, seconds:0);
client.LingerState = new LingerOption(enable:false, seconds:0); // socket 종료하면 즉시 제거한다.
//client.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.DontLinger, true); //닷넷코어에서 사용 불가

return this.AppServer.CreateAppSession(session);
Expand Down
Binary file not shown.
Binary file not shown.
14 changes: 4 additions & 10 deletions Tutorials/EchoServerEx/EchoServerEx.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
Expand All @@ -24,15 +24,9 @@
</ItemGroup>

<ItemGroup>
<Reference Include="SuperSocket.Common">
<HintPath>..\00_superSocketLite_libs\netstandard2.0\SuperSocket.Common.dll</HintPath>
</Reference>
<Reference Include="SuperSocket.SocketBase">
<HintPath>..\00_superSocketLite_libs\netstandard2.0\SuperSocket.SocketBase.dll</HintPath>
</Reference>
<Reference Include="SuperSocket.SocketEngine">
<HintPath>..\00_superSocketLite_libs\netstandard2.0\SuperSocket.SocketEngine.dll</HintPath>
</Reference>
<ProjectReference Include="..\..\Common\SuperSocket.Common.csproj" />
<ProjectReference Include="..\..\SocketBase\SuperSocket.SocketBase.csproj" />
<ProjectReference Include="..\..\SocketEngine\SuperSocket.SocketEngine.csproj" />
</ItemGroup>

<ItemGroup>
Expand Down
29 changes: 27 additions & 2 deletions Tutorials/EchoServerEx/EchoServerEx.sln
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.28307.168
# Visual Studio Version 16
VisualStudioVersion = 16.0.28803.202
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "EchoServerEx", "EchoServerEx.csproj", "{191FCBF6-F42D-401C-9173-F8E096775177}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SuperSocket", "SuperSocket", "{6277710D-1BD5-4A02-9BF1-7B4B246AED5F}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SuperSocket.Common", "..\..\Common\SuperSocket.Common.csproj", "{82F5EC58-2D97-434B-A78F-49666A79C4A2}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SuperSocket.SocketBase", "..\..\SocketBase\SuperSocket.SocketBase.csproj", "{7E048E3B-2BCE-481B-A37F-13EED4985BF1}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SuperSocket.SocketEngine", "..\..\SocketEngine\SuperSocket.SocketEngine.csproj", "{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -15,10 +23,27 @@ Global
{191FCBF6-F42D-401C-9173-F8E096775177}.Debug|Any CPU.Build.0 = Debug|Any CPU
{191FCBF6-F42D-401C-9173-F8E096775177}.Release|Any CPU.ActiveCfg = Release|Any CPU
{191FCBF6-F42D-401C-9173-F8E096775177}.Release|Any CPU.Build.0 = Release|Any CPU
{82F5EC58-2D97-434B-A78F-49666A79C4A2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{82F5EC58-2D97-434B-A78F-49666A79C4A2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{82F5EC58-2D97-434B-A78F-49666A79C4A2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{82F5EC58-2D97-434B-A78F-49666A79C4A2}.Release|Any CPU.Build.0 = Release|Any CPU
{7E048E3B-2BCE-481B-A37F-13EED4985BF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7E048E3B-2BCE-481B-A37F-13EED4985BF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7E048E3B-2BCE-481B-A37F-13EED4985BF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7E048E3B-2BCE-481B-A37F-13EED4985BF1}.Release|Any CPU.Build.0 = Release|Any CPU
{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{82F5EC58-2D97-434B-A78F-49666A79C4A2} = {6277710D-1BD5-4A02-9BF1-7B4B246AED5F}
{7E048E3B-2BCE-481B-A37F-13EED4985BF1} = {6277710D-1BD5-4A02-9BF1-7B4B246AED5F}
{3CA4886E-FFD8-4342-BAE2-3F97B8E003B0} = {6277710D-1BD5-4A02-9BF1-7B4B246AED5F}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {A2804119-9424-4C9F-9A29-D72B9FA068E9}
EndGlobalSection
Expand Down
2 changes: 1 addition & 1 deletion Tutorials/EchoServerEx/MainServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ void OnClosed(NetworkSession session, CloseReason reason)

void RequestReceived(NetworkSession session, EFBinaryRequestInfo reqInfo)
{
MainLogger.Info($"세션 번호 {session.SessionID}, 받은 데이터 크기: {reqInfo.Body.Length}");
//MainLogger.Info($"세션 번호 {session.SessionID}, 받은 데이터 크기: {reqInfo.Body.Length}");

var PacketID = reqInfo.PacketID;

Expand Down

0 comments on commit 46dc006

Please sign in to comment.