Skip to content

Commit 4c15c46

Browse files
authored
Register database health check (#301)
* Register database health check * Update dependency decisions Signed-off-by: Victor Chang <[email protected]>
1 parent 7d5ab79 commit 4c15c46

File tree

10 files changed

+295
-70
lines changed

10 files changed

+295
-70
lines changed

doc/dependency_decisions.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -523,23 +523,23 @@
523523
- :who: mocsharp
524524
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
525525
:versions:
526-
- 6.0.10
527526
- 6.0.11
527+
- 6.0.12
528528
:when: 2022-08-29 18:11:22.090772006 Z
529529
- - :approve
530530
- Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions
531531
- :who: mocsharp
532532
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
533533
:versions:
534-
- 6.0.10
535534
- 6.0.11
535+
- 6.0.12
536536
:when: 2022-08-29 18:11:22.090772006 Z
537537
- - :approve
538538
- Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore
539539
- :who: mocsharp
540540
:why: MIT (https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
541541
:versions:
542-
- 6.0.11
542+
- 6.0.12
543543
:when: 2022-08-29 18:11:22.090772006 Z
544544
- - :approve
545545
- Microsoft.Extensions.FileProviders.Abstractions

docs/changelog.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@
1717

1818
# Changelog
1919

20+
## 0.3.7
21+
22+
[GitHub Milestone 0.3.7](https://github.com/Project-MONAI/monai-deploy-informatics-gateway/milestone/13)
23+
24+
- Fixes database health checks not using the configured database.
25+
2026
## 0.3.6
2127

2228
[GitHub Milestone 0.3.6](https://github.com/Project-MONAI/monai-deploy-informatics-gateway/milestone/12)
@@ -27,7 +33,7 @@
2733

2834
## 0.3.5
2935

30-
[GitHub Milestone 0.3.6](https://github.com/Project-MONAI/monai-deploy-informatics-gateway/milestone/11)
36+
[GitHub Milestone 0.3.5](https://github.com/Project-MONAI/monai-deploy-informatics-gateway/milestone/11)
3137

3238
- Integrates Monai.Deploy.Security to enable OpenID Connect for API authentication.
3339
- Records DICOM association information in the database.

docs/compliance/third-party-licenses.md

Lines changed: 228 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,225 @@ SOFTWARE.
317317
</details>
318318

319319

320+
<details>
321+
<summary>AspNetCore.HealthChecks.MongoDb 6.0.2</summary>
322+
323+
## AspNetCore.HealthChecks.MongoDb
324+
325+
- Version: 6.0.2
326+
- Authors: Xabaril Contributors
327+
- Project URL: https://github.com/Xabaril/AspNetCore.Diagnostics.HealthChecks
328+
- Source: [NuGet](https://www.nuget.org/packages/AspNetCore.HealthChecks.MongoDb/6.0.2)
329+
- License: [Apache-2.0](https://github.com/Xabaril/AspNetCore.Diagnostics.HealthChecks/raw/master/LICENSE)
330+
331+
332+
```
333+
Apache License
334+
Version 2.0, January 2004
335+
http://www.apache.org/licenses/
336+
337+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
338+
339+
1. Definitions.
340+
341+
"License" shall mean the terms and conditions for use, reproduction,
342+
and distribution as defined by Sections 1 through 9 of this document.
343+
344+
"Licensor" shall mean the copyright owner or entity authorized by
345+
the copyright owner that is granting the License.
346+
347+
"Legal Entity" shall mean the union of the acting entity and all
348+
other entities that control, are controlled by, or are under common
349+
control with that entity. For the purposes of this definition,
350+
"control" means (i) the power, direct or indirect, to cause the
351+
direction or management of such entity, whether by contract or
352+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
353+
outstanding shares, or (iii) beneficial ownership of such entity.
354+
355+
"You" (or "Your") shall mean an individual or Legal Entity
356+
exercising permissions granted by this License.
357+
358+
"Source" form shall mean the preferred form for making modifications,
359+
including but not limited to software source code, documentation
360+
source, and configuration files.
361+
362+
"Object" form shall mean any form resulting from mechanical
363+
transformation or translation of a Source form, including but
364+
not limited to compiled object code, generated documentation,
365+
and conversions to other media types.
366+
367+
"Work" shall mean the work of authorship, whether in Source or
368+
Object form, made available under the License, as indicated by a
369+
copyright notice that is included in or attached to the work
370+
(an example is provided in the Appendix below).
371+
372+
"Derivative Works" shall mean any work, whether in Source or Object
373+
form, that is based on (or derived from) the Work and for which the
374+
editorial revisions, annotations, elaborations, or other modifications
375+
represent, as a whole, an original work of authorship. For the purposes
376+
of this License, Derivative Works shall not include works that remain
377+
separable from, or merely link (or bind by name) to the interfaces of,
378+
the Work and Derivative Works thereof.
379+
380+
"Contribution" shall mean any work of authorship, including
381+
the original version of the Work and any modifications or additions
382+
to that Work or Derivative Works thereof, that is intentionally
383+
submitted to Licensor for inclusion in the Work by the copyright owner
384+
or by an individual or Legal Entity authorized to submit on behalf of
385+
the copyright owner. For the purposes of this definition, "submitted"
386+
means any form of electronic, verbal, or written communication sent
387+
to the Licensor or its representatives, including but not limited to
388+
communication on electronic mailing lists, source code control systems,
389+
and issue tracking systems that are managed by, or on behalf of, the
390+
Licensor for the purpose of discussing and improving the Work, but
391+
excluding communication that is conspicuously marked or otherwise
392+
designated in writing by the copyright owner as "Not a Contribution."
393+
394+
"Contributor" shall mean Licensor and any individual or Legal Entity
395+
on behalf of whom a Contribution has been received by Licensor and
396+
subsequently incorporated within the Work.
397+
398+
2. Grant of Copyright License. Subject to the terms and conditions of
399+
this License, each Contributor hereby grants to You a perpetual,
400+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
401+
copyright license to reproduce, prepare Derivative Works of,
402+
publicly display, publicly perform, sublicense, and distribute the
403+
Work and such Derivative Works in Source or Object form.
404+
405+
3. Grant of Patent License. Subject to the terms and conditions of
406+
this License, each Contributor hereby grants to You a perpetual,
407+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
408+
(except as stated in this section) patent license to make, have made,
409+
use, offer to sell, sell, import, and otherwise transfer the Work,
410+
where such license applies only to those patent claims licensable
411+
by such Contributor that are necessarily infringed by their
412+
Contribution(s) alone or by combination of their Contribution(s)
413+
with the Work to which such Contribution(s) was submitted. If You
414+
institute patent litigation against any entity (including a
415+
cross-claim or counterclaim in a lawsuit) alleging that the Work
416+
or a Contribution incorporated within the Work constitutes direct
417+
or contributory patent infringement, then any patent licenses
418+
granted to You under this License for that Work shall terminate
419+
as of the date such litigation is filed.
420+
421+
4. Redistribution. You may reproduce and distribute copies of the
422+
Work or Derivative Works thereof in any medium, with or without
423+
modifications, and in Source or Object form, provided that You
424+
meet the following conditions:
425+
426+
(a) You must give any other recipients of the Work or
427+
Derivative Works a copy of this License; and
428+
429+
(b) You must cause any modified files to carry prominent notices
430+
stating that You changed the files; and
431+
432+
(c) You must retain, in the Source form of any Derivative Works
433+
that You distribute, all copyright, patent, trademark, and
434+
attribution notices from the Source form of the Work,
435+
excluding those notices that do not pertain to any part of
436+
the Derivative Works; and
437+
438+
(d) If the Work includes a "NOTICE" text file as part of its
439+
distribution, then any Derivative Works that You distribute must
440+
include a readable copy of the attribution notices contained
441+
within such NOTICE file, excluding those notices that do not
442+
pertain to any part of the Derivative Works, in at least one
443+
of the following places: within a NOTICE text file distributed
444+
as part of the Derivative Works; within the Source form or
445+
documentation, if provided along with the Derivative Works; or,
446+
within a display generated by the Derivative Works, if and
447+
wherever such third-party notices normally appear. The contents
448+
of the NOTICE file are for informational purposes only and
449+
do not modify the License. You may add Your own attribution
450+
notices within Derivative Works that You distribute, alongside
451+
or as an addendum to the NOTICE text from the Work, provided
452+
that such additional attribution notices cannot be construed
453+
as modifying the License.
454+
455+
You may add Your own copyright statement to Your modifications and
456+
may provide additional or different license terms and conditions
457+
for use, reproduction, or distribution of Your modifications, or
458+
for any such Derivative Works as a whole, provided Your use,
459+
reproduction, and distribution of the Work otherwise complies with
460+
the conditions stated in this License.
461+
462+
5. Submission of Contributions. Unless You explicitly state otherwise,
463+
any Contribution intentionally submitted for inclusion in the Work
464+
by You to the Licensor shall be under the terms and conditions of
465+
this License, without any additional terms or conditions.
466+
Notwithstanding the above, nothing herein shall supersede or modify
467+
the terms of any separate license agreement you may have executed
468+
with Licensor regarding such Contributions.
469+
470+
6. Trademarks. This License does not grant permission to use the trade
471+
names, trademarks, service marks, or product names of the Licensor,
472+
except as required for reasonable and customary use in describing the
473+
origin of the Work and reproducing the content of the NOTICE file.
474+
475+
7. Disclaimer of Warranty. Unless required by applicable law or
476+
agreed to in writing, Licensor provides the Work (and each
477+
Contributor provides its Contributions) on an "AS IS" BASIS,
478+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
479+
implied, including, without limitation, any warranties or conditions
480+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
481+
PARTICULAR PURPOSE. You are solely responsible for determining the
482+
appropriateness of using or redistributing the Work and assume any
483+
risks associated with Your exercise of permissions under this License.
484+
485+
8. Limitation of Liability. In no event and under no legal theory,
486+
whether in tort (including negligence), contract, or otherwise,
487+
unless required by applicable law (such as deliberate and grossly
488+
negligent acts) or agreed to in writing, shall any Contributor be
489+
liable to You for damages, including any direct, indirect, special,
490+
incidental, or consequential damages of any character arising as a
491+
result of this License or out of the use or inability to use the
492+
Work (including but not limited to damages for loss of goodwill,
493+
work stoppage, computer failure or malfunction, or any and all
494+
other commercial damages or losses), even if such Contributor
495+
has been advised of the possibility of such damages.
496+
497+
9. Accepting Warranty or Additional Liability. While redistributing
498+
the Work or Derivative Works thereof, You may choose to offer,
499+
and charge a fee for, acceptance of support, warranty, indemnity,
500+
or other liability obligations and/or rights consistent with this
501+
License. However, in accepting such obligations, You may act only
502+
on Your own behalf and on Your sole responsibility, not on behalf
503+
of any other Contributor, and only if You agree to indemnify,
504+
defend, and hold each Contributor harmless for any liability
505+
incurred by, or claims asserted against, such Contributor by reason
506+
of your accepting any such warranty or additional liability.
507+
508+
END OF TERMS AND CONDITIONS
509+
510+
APPENDIX: How to apply the Apache License to your work.
511+
512+
To apply the Apache License to your work, attach the following
513+
boilerplate notice, with the fields enclosed by brackets "[]"
514+
replaced with your own identifying information. (Don't include
515+
the brackets!) The text should be enclosed in the appropriate
516+
comment syntax for the file format. We also recommend that a
517+
file or class name and description of purpose be included on the
518+
same "printed page" as the copyright notice for easier
519+
identification within third-party archives.
520+
521+
Copyright [yyyy] [name of copyright owner]
522+
523+
Licensed under the Apache License, Version 2.0 (the "License");
524+
you may not use this file except in compliance with the License.
525+
You may obtain a copy of the License at
526+
527+
http://www.apache.org/licenses/LICENSE-2.0
528+
529+
Unless required by applicable law or agreed to in writing, software
530+
distributed under the License is distributed on an "AS IS" BASIS,
531+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
532+
See the License for the specific language governing permissions and
533+
limitations under the License.
534+
```
535+
536+
</details>
537+
538+
320539
<details>
321540
<summary>BoDi 1.5.0</summary>
322541

@@ -4372,14 +4591,14 @@ SOFTWARE.
43724591

43734592

43744593
<details>
4375-
<summary>Microsoft.Extensions.Diagnostics.HealthChecks 6.0.11</summary>
4594+
<summary>Microsoft.Extensions.Diagnostics.HealthChecks 6.0.12</summary>
43764595

43774596
## Microsoft.Extensions.Diagnostics.HealthChecks
43784597

4379-
- Version: 6.0.11
4598+
- Version: 6.0.12
43804599
- Authors: Microsoft
43814600
- Project URL: https://asp.net/
4382-
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks/6.0.11)
4601+
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks/6.0.12)
43834602
- License: [MIT](https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
43844603

43854604

@@ -4454,14 +4673,14 @@ SOFTWARE.
44544673

44554674

44564675
<details>
4457-
<summary>Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions 6.0.11</summary>
4676+
<summary>Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions 6.0.12</summary>
44584677

44594678
## Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions
44604679

4461-
- Version: 6.0.11
4680+
- Version: 6.0.12
44624681
- Authors: Microsoft
44634682
- Project URL: https://asp.net/
4464-
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions/6.0.11)
4683+
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions/6.0.12)
44654684
- License: [MIT](https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
44664685

44674686

@@ -4495,14 +4714,14 @@ SOFTWARE.
44954714

44964715

44974716
<details>
4498-
<summary>Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore 6.0.11</summary>
4717+
<summary>Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore 6.0.12</summary>
44994718

45004719
## Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore
45014720

4502-
- Version: 6.0.11
4721+
- Version: 6.0.12
45034722
- Authors: Microsoft
45044723
- Project URL: https://asp.net/
4505-
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore/6.0.11)
4724+
- Source: [NuGet](https://www.nuget.org/packages/Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore/6.0.12)
45064725
- License: [MIT](https://github.com/dotnet/aspnetcore/raw/main/LICENSE.txt)
45074726

45084727

src/Client/Test/packages.lock.json

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -389,28 +389,28 @@
389389
},
390390
"Microsoft.Extensions.Diagnostics.HealthChecks": {
391391
"type": "Transitive",
392-
"resolved": "6.0.11",
393-
"contentHash": "E6HxKQvrm0AeDagW6w+CsyVfXAO/pscrbX6mQ+XnThdwkeTxi0cnuXDTiTmd+WSmofSfpBKOS0VlvHUOxskdLQ==",
392+
"resolved": "6.0.12",
393+
"contentHash": "TdsjGYOHDg8656T2tWHUXNkYFUFstL/L9GEjboasuAetubH52yHkNpQV6WuqA6BpbfZHZj8xwKqN7aL7ZWO1Rg==",
394394
"dependencies": {
395-
"Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions": "6.0.11",
395+
"Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions": "6.0.12",
396396
"Microsoft.Extensions.Hosting.Abstractions": "6.0.0",
397397
"Microsoft.Extensions.Logging.Abstractions": "6.0.3",
398398
"Microsoft.Extensions.Options": "6.0.0"
399399
}
400400
},
401401
"Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions": {
402402
"type": "Transitive",
403-
"resolved": "6.0.11",
404-
"contentHash": "MQS7GE1ux7Lo1yOr59M7ZTEoFY3GJ9hHkxXQnQc8EPxkt5S7cX4qe6djSWH+mk9qQan+AjFZzdC1x5Af5IaseA=="
403+
"resolved": "6.0.12",
404+
"contentHash": "7GN8C+pcaIBMDQA6OOgBEWT+1Y/OhZTxzovNXIxxBsfU4xI7bmjez5321ya5rN2NbJXUmStNnJics78RkPQO4w=="
405405
},
406406
"Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore": {
407407
"type": "Transitive",
408-
"resolved": "6.0.11",
409-
"contentHash": "tMjF1erFhHE+SnsiIyRIatVeKBgB9OfGsOvQe/+foE0xl4+JUQGbCA7gF1wqOksi9AxmGWzqtqjsMKJpCo5wYQ==",
408+
"resolved": "6.0.12",
409+
"contentHash": "TWtq9Hnjq8mTHbbe2JBLa5FR7wlxecFK/PjYQFWru+BVCWCXvRtscO/+S9/Dlz5XkgNzEfLwO9KvUqoh3EybtA==",
410410
"dependencies": {
411-
"Microsoft.EntityFrameworkCore.Relational": "6.0.11",
412-
"Microsoft.Extensions.Diagnostics.HealthChecks": "6.0.11",
413-
"Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions": "6.0.11"
411+
"Microsoft.EntityFrameworkCore.Relational": "6.0.12",
412+
"Microsoft.Extensions.Diagnostics.HealthChecks": "6.0.12",
413+
"Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions": "6.0.12"
414414
}
415415
},
416416
"Microsoft.Extensions.FileProviders.Abstractions": {
@@ -1751,7 +1751,7 @@
17511751
"Microsoft.Extensions.Configuration": "6.0.1",
17521752
"Microsoft.Extensions.Configuration.FileExtensions": "6.0.0",
17531753
"Microsoft.Extensions.Configuration.Json": "6.0.0",
1754-
"Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore": "6.0.11",
1754+
"Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore": "6.0.12",
17551755
"Microsoft.Extensions.Options.ConfigurationExtensions": "6.0.0",
17561756
"Monai.Deploy.InformaticsGateway.Api": "1.0.0",
17571757
"Monai.Deploy.InformaticsGateway.Configuration": "1.0.0",

src/Database/DatabaseManager.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
using Monai.Deploy.InformaticsGateway.Database.Api;
2222
using Monai.Deploy.InformaticsGateway.Database.Api.Repositories;
2323
using Monai.Deploy.InformaticsGateway.Database.EntityFramework;
24-
using Monai.Deploy.InformaticsGateway.Database.EntityFramework.Configuration;
2524
using Monai.Deploy.InformaticsGateway.Database.MongoDB;
2625
using Monai.Deploy.InformaticsGateway.Database.MongoDB.Configurations;
2726
using MongoDB.Driver;

0 commit comments

Comments
 (0)