Skip to content
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

Error map for updateResults #914

Merged
merged 3 commits into from
Aug 23, 2023
Merged

Error map for updateResults #914

merged 3 commits into from
Aug 23, 2023

Conversation

msvinaykumar
Copy link
Contributor

will get code with error message in updateResultsAPI

   "errors": {
            "409": "An entry for this record already exists!"
        },

@msvinaykumar msvinaykumar self-assigned this Aug 23, 2023
@msvinaykumar msvinaykumar added the API Requires API Changes label Aug 23, 2023
@msvinaykumar msvinaykumar added this to the Kruize 0.0.18_rm Release milestone Aug 23, 2023
@dinogun
Copy link
Contributor

dinogun commented Aug 23, 2023

The format that we have been using for all the APIs has been as below

{
  "message": "Mandatory parameters missing.",
  "httpcode": 400,
  "documentationLink": "",
  "status": "ERROR"
}

@msvinaykumar I think we need to follow the same format for each individual record inside the bulk JSON as well. This means that we don't need two different ways to handle error conditions, one type for the entire bulk record and one for individual. Instead we need to have the same format for both.

@msvinaykumar
Copy link
Contributor Author

The format that we have been using for all the APIs has been as below

{
  "message": "Mandatory parameters missing.",
  "httpcode": 400,
  "documentationLink": "",
  "status": "ERROR"
}

@msvinaykumar I think we need to follow the same format for each individual record inside the bulk JSON as well. This means that we don't need two different ways to handle error conditions, one type for the entire bulk record and one for individual. Instead we need to have the same format for both.

ok let me check

@msvinaykumar
Copy link
Contributor Author

The format that we have been using for all the APIs has been as below

{
  "message": "Mandatory parameters missing.",
  "httpcode": 400,
  "documentationLink": "",
  "status": "ERROR"
}

@msvinaykumar I think we need to follow the same format for each individual record inside the bulk JSON as well. This means that we don't need two different ways to handle error conditions, one type for the entire bulk record and one for individual. Instead we need to have the same format for both.

Done

Signed-off-by: msvinaykumar <vinakuma@redhat.com>
Signed-off-by: msvinaykumar <vinakuma@redhat.com>
Signed-off-by: msvinaykumar <vinakuma@redhat.com>
Copy link
Contributor

@dinogun dinogun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dinogun dinogun merged commit db95c01 into kruize:mvp_demo Aug 23, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Requires API Changes
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

New API 'UpdateRecommendations' to support non-chronological order of data
2 participants