-
-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drive health #156
Drive health #156
Conversation
* upgrade to net8.0 * Add health check endpoint to GRPC engine proto (from serval) * Combine health reports into rich data
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 18 of 18 files at r1, all commit messages.
Reviewable status: all files reviewed, 4 unresolved discussions (waiting on @johnml1135)
src/SIL.Machine.AspNetCore/Configuration/IMachineBuilderExtensions.cs
line 224 at r1 (raw file):
public static IMachineBuilder AddMongoDataAccess(this IMachineBuilder builder, string? connectionString = null) { connectionString ??= builder.Configuration!.GetConnectionString("Mongo");
Please avoid using the null-forgiving operator when possible. Throw an exception if necessary.
src/SIL.Machine.AspNetCore/Configuration/IMachineBuilderExtensions.cs
line 375 at r1 (raw file):
string EnginesDir = builder.Configuration .GetSection(SmtTransferEngineOptions.Key)!
I don't think that the null-forgiving operators are needed here.
src/SIL.Machine.AspNetCore/Configuration/IMachineBuilderExtensions.cs
line 378 at r1 (raw file):
.GetValue<string>("EnginesDir")!; string driveLetter = Path.GetPathRoot(EnginesDir)![..1];
Please avoid using the null-forgiving operator when possible.
src/SIL.Machine.AspNetCore/Services/ClearMLAuthenticationService.cs
line 13 at r1 (raw file):
// to know well ahead of time if something is wrong. private static readonly TimeSpan RefreshPeriod = TimeSpan.FromSeconds(3600); private string? _authToken = "";
I don't think it is ever possible for _authToken
to be null
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 2 files at r2, 1 of 1 files at r3, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @johnml1135)
Previously, ddaspit (Damien Daspit) wrote…
Does that meet your expectations? |
Previously, ddaspit (Damien Daspit) wrote…
Fixed. |
Previously, ddaspit (Damien Daspit) wrote…
I revised the logic a bit to handle edge cases better. Specifically, if we can't get the auth token when first starting up, we should crash out. If refreshing fails, we should keep laboring on as long as possible. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 2 of 2 files at r4, all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @johnml1135)
Resolves #141 and sillsdev/serval#243.
This change is![Reviewable](https://camo.githubusercontent.com/1541c4039185914e83657d3683ec25920c672c6c5c7ab4240ee7bff601adec0b/68747470733a2f2f72657669657761626c652e696f2f7265766965775f627574746f6e2e737667)