-
Notifications
You must be signed in to change notification settings - Fork 21
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
feat(admin): validating bpn before adding to companyUser #902
Conversation
src/administration/Administration.Service/BusinessLogic/UserBusinessLogic.cs
Fixed
Show fixed
Hide fixed
tests/administration/Administration.Service.Tests/BusinessLogic/UserBusinessLogicTests.cs
Fixed
Show fixed
Hide fixed
tests/administration/Administration.Service.Tests/BusinessLogic/UserBusinessLogicTests.cs
Fixed
Show fixed
Hide fixed
tests/administration/Administration.Service.Tests/BusinessLogic/UserBusinessLogicTests.cs
Fixed
Show fixed
Hide fixed
tests/administration/Administration.Service.Tests/BusinessLogic/UserBusinessLogicTests.cs
Fixed
Show fixed
Hide fixed
d0ea516
to
7b79f70
Compare
4105609
to
32399ec
Compare
{ | ||
private readonly HttpClient _httpClient; | ||
private readonly HttpClient _httpClient = httpFactory.CreateClient(nameof(BpnAccess)); |
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.
I'm not sure whether storing a reference to a factory-generated http-client in a member is advisable. According to https://learn.microsoft.com/en-us/dotnet/fundamentals/networking/http/httpclient-guidelines (section recommendet use httpclient-instances that were created by IHttpClientFactory should be short-lived objects. As http-client also implements IDisposable creating a new instance within FetchLegalEntityByBpn using the 'using'-keyword to dispose when it goes out of scope should be the correct way.
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.
adjusted.
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.
Ref : CPLP-3639
Refs: CPLP-3639
d2f22af
to
b0dfe53
Compare
b0dfe53
to
9a3561a
Compare
Quality Gate passedIssues Measures |
Description
validating bpn before adding to companyUser
Why
Added validation for BPN before adding to it companyUser
Issue
Refs : #901
Corresponding Portal PR
eclipse-tractusx/portal#426
Checklist