Skip to content

Commit e008c90

Browse files
committed
v2.0 release updates
1 parent a16b441 commit e008c90

File tree

20 files changed

+169
-104350
lines changed

20 files changed

+169
-104350
lines changed

src/Server/Coderr.Server.ReportAnalyzer/Boot/Starters/ReportQueueModule.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,13 @@
44
using System.Security.Claims;
55
using System.Threading;
66
using System.Threading.Tasks;
7-
using codeRR.Client;
7+
using Coderr.Client;
88
using Coderr.Server.Abstractions.Security;
99
using Coderr.Server.Infrastructure.Messaging;
1010
using Coderr.Server.ReportAnalyzer.Abstractions;
1111
using Coderr.Server.ReportAnalyzer.Abstractions.Boot;
1212
using Coderr.Server.ReportAnalyzer.Abstractions.Incidents;
1313
using Coderr.Server.ReportAnalyzer.Boot.Adapters;
14-
using Coderr.Server.ReportAnalyzer.Inbound.Commands;
15-
using Coderr.Server.ReportAnalyzer.Inbound.Handlers;
1614
using DotNetCqs;
1715
using DotNetCqs.Bus;
1816
using DotNetCqs.DependencyInjection;
@@ -109,7 +107,7 @@ private QueueListener ConfigureQueueListener(ConfigurationContext context, strin
109107
};
110108
listener.PoisonMessageDetected += (sender, args) =>
111109
{
112-
//Err.Report(args.Exception, new { args.Message });
110+
Err.Report(args.Exception, new { args.Message.Body });
113111
_logger.Error(inboundQueueName + " Poison message: " + args.Message.Body, args.Exception);
114112
};
115113
listener.ScopeCreated += (sender, args) =>

src/Server/Coderr.Server.ReportAnalyzer/Coderr.Server.ReportAnalyzer.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<DefaultItemExcludes>$(DefaultItemExcludes);**\*.DotSettings;</DefaultItemExcludes>
77
</PropertyGroup>
88
<ItemGroup>
9-
<PackageReference Include="Coderr.Client.NetStd" Version="1.0.2" />
9+
<PackageReference Include="Coderr.Client.NetStd" Version="1.1.3" />
1010
<PackageReference Include="DotNetCqs" Version="2.0.9" />
1111
<PackageReference Include="DotNetCqs.DependencyInjection.Microsoft" Version="1.0.0" />
1212
<PackageReference Include="DotNetCqs.Queues.AdoNet" Version="1.0.6" />

src/Server/Coderr.Server.ReportAnalyzer/ErrorReports/HashCodeGenerator.cs

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,21 @@ protected virtual string DefaultCreateHashCode(ErrorReportEntity report)
6464
{
6565
if (report == null) throw new ArgumentNullException("report");
6666

67-
//TODO: Ta bort radnummers stripparen
68-
var hashSource = report.Exception.FullName + "\r\n";
69-
hashSource += StripLineNumbers(report.Exception.StackTrace ?? "");
67+
68+
var hashSource = $"{report.Exception.FullName ?? report.Exception.Name}\r\n";
69+
70+
// the client libraries can by themselves specify how we should identify
71+
// unqiue incidents. We then use that identifier in combination with the exception name.
72+
var collection = report.ContextCollections.FirstOrDefault(x => x.Name == "CoderrData");
73+
if (collection != null && collection.Properties.TryGetValue("HashSource", out var reportHashSource))
74+
hashSource += reportHashSource;
75+
else
76+
hashSource += StripLineNumbers(report.Exception.StackTrace ?? "");
7077

7178
var hash = 23;
7279
foreach (var c in hashSource)
7380
{
74-
hash = hash*31 + c;
81+
hash = hash * 31 + c;
7582
}
7683
return hash.ToString("X");
7784
}

src/Server/Coderr.Server.SqlServer/Core/Reports/ErrorReportRepository.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public async Task<ErrorReportEntity> GetAsync(int id)
6565
report.Add(collection);
6666
}
6767

68-
properties.Add(reader.GetString(1), reader.GetString(2));
68+
properties[reader.GetString(1)] = reader.GetString(2);
6969
}
7070

7171
// When the last property is in a new collection

src/Server/Coderr.Server.Web/Areas/Installation/Views/Setup/Completed.cshtml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,6 @@
2121
</div>
2222
}
2323
@Html.Raw(ViewBag.PrevStep)
24+
<a href="~/" class="btn btn-primary">I've restarted the pool, let's begin!</a>
2425
</div>
2526
</div>

src/Server/Coderr.Server.Web/Areas/Installation/Views/Setup/Support.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<div>&nbsp;</div>
1818
<br />
1919
@Html.Raw(ViewBag.PrevLink)
20-
<input type="submit" class="btn btn-primary" value="Get FREE help" />
20+
<input type="submit" class="btn btn-primary" value="Get FREE assistance" />
2121
@Html.Raw(ViewBag.NextLink)
2222
</form>
2323
</div>

src/Server/Coderr.Server.Web/Boot/Cqs/RegisterCqsServices.cs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,10 @@
22
using System.Collections.Generic;
33
using System.Data;
44
using System.Linq;
5-
using System.Reflection;
65
using System.Security.Claims;
76
using System.Threading;
87
using System.Threading.Tasks;
9-
using codeRR.Client;
8+
using Coderr.Client;
109
using Coderr.Server.Abstractions.Boot;
1110
using Coderr.Server.Abstractions.Security;
1211
using Coderr.Server.App.Core.Accounts;
@@ -140,7 +139,7 @@ private IMessageInvoker CreateMessageInvoker(IServiceProvider x)
140139
}
141140
catch (Exception ex)
142141
{
143-
Err.Report(ex, new {args.Message});
142+
Err.Report(ex, new {args.Message.Body});
144143
}
145144
};
146145

@@ -160,7 +159,7 @@ private IMessageInvoker CreateMessageInvoker(IServiceProvider x)
160159

161160
Err.Report(args.Exception, new
162161
{
163-
args.Message,
162+
args.Message.Body,
164163
HandlerType = args.Handler.GetType(),
165164
args.ExecutionTime
166165
});
@@ -199,7 +198,7 @@ private IMessageInvoker MessageInvokerFactory(IHandlerScope arg)
199198

200199
Err.Report(args.Exception, new
201200
{
202-
args.Message,
201+
args.Message.Body,
203202
HandlerType = args.Handler.GetType(),
204203
args.ExecutionTime
205204
});

src/Server/Coderr.Server.Web/Boot/Modules/BackgroundJobs.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using System;
22
using System.Diagnostics;
3-
using codeRR.Client;
3+
using Coderr.Client;
44
using Coderr.Server.Abstractions.Boot;
55
using Coderr.Server.Web.Boot.Adapters;
66
using Griffin.ApplicationServices;

src/Server/Coderr.Server.Web/Coderr.Server.Web.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<IsPackable>false</IsPackable>
88
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
99
</PropertyGroup>
10-
10+
1111
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
1212
<TypeScriptExperimentalDecorators>true</TypeScriptExperimentalDecorators>
1313
</PropertyGroup>
@@ -18,6 +18,7 @@
1818
</ItemGroup>-->
1919

2020
<ItemGroup>
21+
<PackageReference Include="Coderr.Client.AspNetCore.Mvc" Version="1.0.3" />
2122
<PackageReference Include="Microsoft.AspNetCore.All" Version="2.0.6" />
2223
<PackageReference Include="Griffin.Framework" Version="2.0.0-alpha01" />
2324
<PackageReference Include="Microsoft.AspNetCore.Authentication.Cookies" Version="2.0.3" />
@@ -77,5 +78,4 @@
7778
</ResolvedFileToPublish>
7879
</ItemGroup>
7980
</Target>
80-
8181
</Project>

src/Server/Coderr.Server.Web/Controllers/FeedbackReceiverController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
using System.IO.Compression;
44
using System.Text;
55
using System.Threading.Tasks;
6-
using codeRR.Client.Contracts;
6+
using Coderr.Client.Contracts;
77
using Coderr.Server.Domain.Core.Applications;
88
using Coderr.Server.Infrastructure.Messaging;
99
using Coderr.Server.ReportAnalyzer.Inbound.Commands;

0 commit comments

Comments
 (0)