Skip to content

Commit 9af6a39

Browse files
committed
Castle.Services.Logging.EventlogIntegration for Windows EventLog
1 parent 28b8715 commit 9af6a39

File tree

9 files changed

+56
-13
lines changed

9 files changed

+56
-13
lines changed

Castle.Core.sln

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio Version 16
4-
VisualStudioVersion = 16.0.30011.22
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.11.35312.102
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Castle Build", "Castle Build", "{1B999D24-B7AB-4997-96E7-08FA05325694}"
77
ProjectSection(SolutionItems) = preProject
@@ -37,6 +37,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "GitHub Actions", "GitHub Ac
3737
.github\workflows\build.yml = .github\workflows\build.yml
3838
EndProjectSection
3939
EndProject
40+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Castle.Services.Logging.EventlogIntegration", "src\Castle.Services.Logging.EventlogIntegration\Castle.Services.Logging.EventlogIntegration.csproj", "{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A}"
41+
EndProject
4042
Global
4143
GlobalSection(SolutionConfigurationPlatforms) = preSolution
4244
Debug|Any CPU = Debug|Any CPU
@@ -67,6 +69,10 @@ Global
6769
{14D86762-CF9B-4560-80C9-10C16DBE246C}.Debug|Any CPU.Build.0 = Debug|Any CPU
6870
{14D86762-CF9B-4560-80C9-10C16DBE246C}.Release|Any CPU.ActiveCfg = Release|Any CPU
6971
{14D86762-CF9B-4560-80C9-10C16DBE246C}.Release|Any CPU.Build.0 = Release|Any CPU
72+
{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
73+
{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A}.Debug|Any CPU.Build.0 = Debug|Any CPU
74+
{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A}.Release|Any CPU.ActiveCfg = Release|Any CPU
75+
{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A}.Release|Any CPU.Build.0 = Release|Any CPU
7076
EndGlobalSection
7177
GlobalSection(SolutionProperties) = preSolution
7278
HideSolutionNode = FALSE
@@ -76,6 +82,7 @@ Global
7682
{344D907D-6641-4A61-94C2-4980B5804FE2} = {A598EE9B-41CE-4BE8-BF93-2C91F919F97E}
7783
{91B2A82F-63F6-46B1-8EDC-5D029BCF6A2B} = {A598EE9B-41CE-4BE8-BF93-2C91F919F97E}
7884
{149DB291-CBD6-4F82-A6A6-758E328DB946} = {1B999D24-B7AB-4997-96E7-08FA05325694}
85+
{250FEEB4-2BA9-4C84-B5AF-70FED05DC07A} = {A598EE9B-41CE-4BE8-BF93-2C91F919F97E}
7986
EndGlobalSection
8087
GlobalSection(ExtensibilityGlobals) = postSolution
8188
SolutionGuid = {682D4399-4863-4813-B495-5FEDD22496ED}

src/Castle.Core.Tests.WeakNamed/Castle.Core.Tests.WeakNamed.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<Import Project="..\..\buildscripts\common.props"></Import>
44

@@ -29,6 +29,7 @@
2929
<PackageReference Include="NUnitLite" Version="3.13.3" />
3030
<ProjectReference Include="..\Castle.Core\Castle.Core.csproj" />
3131
<ProjectReference Include="..\Castle.Core.Tests\Castle.Core.Tests.csproj" />
32+
<ProjectReference Include="..\Castle.Services.Logging.EventlogIntegration\Castle.Services.Logging.EventlogIntegration.csproj" />
3233
<ProjectReference Include="..\Castle.Services.Logging.log4netIntegration\Castle.Services.Logging.log4netIntegration.csproj" />
3334
<ProjectReference Include="..\Castle.Services.Logging.NLogIntegration\Castle.Services.Logging.NLogIntegration.csproj" />
3435
<ProjectReference Include="..\Castle.Services.Logging.SerilogIntegration\Castle.Services.Logging.SerilogIntegration.csproj" />

src/Castle.Core.Tests/Castle.Core.Tests.csproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,15 +51,18 @@
5151
<PackageReference Include="Serilog" Version="2.0.0" />
5252
<PackageReference Include="Serilog.Sinks.TextWriter" Version="2.0.0" />
5353
<ProjectReference Include="..\Castle.Core\Castle.Core.csproj" />
54+
<ProjectReference Include="..\Castle.Services.Logging.EventlogIntegration\Castle.Services.Logging.EventlogIntegration.csproj" />
5455
<ProjectReference Include="..\Castle.Services.Logging.log4netIntegration\Castle.Services.Logging.log4netIntegration.csproj" />
5556
<ProjectReference Include="..\Castle.Services.Logging.NLogIntegration\Castle.Services.Logging.NLogIntegration.csproj" />
5657
<ProjectReference Include="..\Castle.Services.Logging.SerilogIntegration\Castle.Services.Logging.SerilogIntegration.csproj" />
5758
</ItemGroup>
5859
<ItemGroup Condition="'$(TargetFramework)'=='netcoreapp2.1'OR'$(TargetFramework)'=='netcoreapp3.1'">
5960
<PackageReference Include="System.Security.Permissions" Version="4.7.0" />
61+
<PackageReference Include="System.Diagnostics.EventLog" Version="4.7.0" />
6062
</ItemGroup>
6163
<ItemGroup Condition="'$(TargetFramework)'=='net6.0'">
6264
<PackageReference Include="System.Security.Permissions" Version="6.0.0" />
65+
<PackageReference Include="System.Diagnostics.EventLog" Version="6.0.0" />
6366
</ItemGroup>
6467
<ItemGroup Condition="'$(TargetFramework)'=='netcoreapp3.1'">
6568
<PackageReference Include="System.Net.NameResolution" Version="4.3.0" />

src/Castle.Core.Tests/PublicApiTestCase.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ public class PublicApiTestCase
4040
"Castle.Services.Logging.log4netIntegration",
4141
"Castle.Services.Logging.NLogIntegration",
4242
"Castle.Services.Logging.SerilogIntegration",
43+
"Castle.Services.Logging.EventlogIntegration",
4344
};
4445

4546
[Test]

src/Castle.Core/Castle.Core.csproj

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,6 @@
3636
<PackageReference Include="System.Reflection.Emit" Version="4.7.0" />
3737
</ItemGroup>
3838

39-
<ItemGroup Condition="'$(TargetFramework)'=='netstandard2.0' OR '$(TargetFramework)'=='netstandard2.1'">
40-
<PackageReference Include="System.Diagnostics.EventLog" Version="4.7.0" />
41-
</ItemGroup>
42-
43-
<ItemGroup Condition="'$(TargetFramework)'=='net6.0'">
44-
<PackageReference Include="System.Diagnostics.EventLog" Version="6.0.0" />
45-
</ItemGroup>
46-
4739
<ItemGroup>
4840
<Folder Include="Properties\" />
4941
</ItemGroup>
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<Import Project="..\..\buildscripts\common.props"></Import>
4+
5+
<PropertyGroup>
6+
<TargetFrameworks>net462;netstandard2.0;netstandard2.1;net6.0</TargetFrameworks>
7+
</PropertyGroup>
8+
9+
<PropertyGroup>
10+
<PackageId>Castle.Core-DiagnosticsLogger</PackageId>
11+
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
12+
<PackageOutputPath>../../build/</PackageOutputPath>
13+
<AssemblyName>Castle.Services.Logging.EventlogIntegration</AssemblyName>
14+
<RootNamespace>Castle.Services.Logging.EventlogIntegration</RootNamespace>
15+
<AssemblyTitle>Castle.Services.Logging.EventlogIntegration</AssemblyTitle>
16+
<Description>Castle Services DiagnosticsLogger for Windows EventLog</Description>
17+
<AssemblyOriginatorKeyFile>..\..\buildscripts\CastleKey.snk</AssemblyOriginatorKeyFile>
18+
<SignAssembly>True</SignAssembly>
19+
<PublicSign Condition="'$(OS)'=='Unix'">true</PublicSign>
20+
<PackageTags>castle logging eventlog</PackageTags>
21+
</PropertyGroup>
22+
23+
<ItemGroup>
24+
<Folder Include="Properties\" />
25+
</ItemGroup>
26+
27+
<ItemGroup Condition="'$(TargetFramework)'=='netstandard2.0' OR '$(TargetFramework)'=='netstandard2.1'">
28+
<PackageReference Include="System.Diagnostics.EventLog" Version="4.7.0" />
29+
</ItemGroup>
30+
31+
<ItemGroup Condition="'$(TargetFramework)'=='net6.0'">
32+
<PackageReference Include="System.Diagnostics.EventLog" Version="6.0.0" />
33+
</ItemGroup>
34+
35+
<ItemGroup>
36+
<ProjectReference Include="..\Castle.Core\Castle.Core.csproj" />
37+
</ItemGroup>
38+
39+
</Project>

src/Castle.Core/Core/Logging/DiagnosticsLogger.cs renamed to src/Castle.Services.Logging.EventlogIntegration/DiagnosticsLogger.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2004-2022 Castle Project - http://www.castleproject.org/
1+
// Copyright 2004-2022 Castle Project - http://www.castleproject.org/
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

src/Castle.Core/Core/Logging/DiagnosticsLoggerFactory.cs renamed to src/Castle.Services.Logging.EventlogIntegration/DiagnosticsLoggerFactory.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2004-2022 Castle Project - http://www.castleproject.org/
1+
// Copyright 2004-2022 Castle Project - http://www.castleproject.org/
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)