Closed jonathanvila closed 3 years ago
Adding some notes after an internal chat with @jonathanvila :
GET /assessments/landscape
will NEVER return a risk whose value is UNKNOWN even if the enum used in the model includes it.the number of unasseed application is equal to the total number of applications sent to the endpoint minus the length of the response of the current endpoint
=> totalAppsRequestedInUI - response.length
@jonathanvila I just want to clarify/summarize all my previous comments:
this PR doesn't need extra action on this topic
.UNKNOWN
: The endpoint GET /assessments/landscape will NEVER return a risk whose value is UNKNOWN even if the enum used in the model includes it => this PR doesn't need extra action on this topic
.Option 1: Currently the backend is returning an array. Can the response return an object containing the total values?. E.g.
{
"low": 1,
"medium": 0,
"high": 1
}
Option 2: Let's keep the endpoint as it is but change the name of the endpoint from /assessments/landscape
to something like /assessments/assessment-risks
(the name is up to you) since the endpoint itself is not creating the Landscape but providing data that will be processed/converted to the landscape report. If you ask me, I would go for this option but I'd like to know your opinion.
GET
to POST
is something we can do in order to reduce the risk of having a big URL calling the endpoint.@carlosthe19916 :
Thanks @jonathanvila, this PR looks good to me.
Issue : https://github.com/konveyor/tackle-pathfinder/issues/66
Features covered
Unit , Integration and End2End Tests cases covered
Unit Test ( AssessmentSvcTest.java )
Integration Test ( AssessmentsResourceTest.java )
End2End Test on minikube with native image ( check_api.sh )
Pre steps Minikube:
Add this below
paths:
Test case with Minikube : Do the full API test
Pre steps non containerised local test:
Test case with local non containerised : Do the full API test