singleton
singleton copied to clipboard
[BUG][Java Service][V1][S3]Return 200 when requesting non-existing version or component in multiple components APIs.
Describe the bug commit: 93ffa26a7c0616ff7fee3eb25318342d1dc8975b [V1][S3]Return 200 when requesting non-existing version or component in multiple components APIs. Effected apis: GET[/i18n/api/v1/translation/components] GET[/i18n/api/v1/translation/product/{productName}/components/{components}]
To Reproduce Steps to reproduce the behavior:
- Go to 'GET[/i18n/api/v1/translation/components]' and input non-existing version or component as parameter:
http://
:8091/i18n/api/v1/translation/components?productName=VMwareVIP&version=1234&components=default&locales=zh-hans or http:// :8091/i18n/api/v1/translation/components?productName=VMwareVIP&version=1.1.0&components=abd&locales=zh-hans - See response:
{
"response": {
"code": 200,
"message": "OK",
"serverTime": ""
},
"signature": "",
"data": {
"productName": "VMwareVIP",
"version": "1.1.0",
"dataOrigin": "",
"pseudo": false,
"machineTranslation": false,
"locales": [
"zh-hans"
],
"components": [
"abd"
],
"bundles": [],
"url": "",
"id": 0
}
}
Expected behavior
Should return 404 and no translation is found.
{/response/code=404, /response/message=Faild to get translation from data for VMwareVIP/1.1.0}